[−][src]Struct openidconnect::IdToken
OpenID Connect ID token.
Methods
impl<AC, GC, JE, JS, JT> IdToken<AC, GC, JE, JS, JT> where
AC: AdditionalClaims,
GC: GenderClaim,
JE: JweContentEncryptionAlgorithm<JT>,
JS: JwsSigningAlgorithm<JT>,
JT: JsonWebKeyType,
[src]
AC: AdditionalClaims,
GC: GenderClaim,
JE: JweContentEncryptionAlgorithm<JT>,
JS: JwsSigningAlgorithm<JT>,
JT: JsonWebKeyType,
pub fn new<JU, K, S>(
claims: IdTokenClaims<AC, GC>,
signing_key: &S,
alg: JS,
access_token: Option<&AccessToken>,
code: Option<&AuthorizationCode>
) -> Result<Self, JsonWebTokenError> where
JU: JsonWebKeyUse,
K: JsonWebKey<JS, JT, JU>,
S: PrivateSigningKey<JS, JT, JU, K>,
[src]
claims: IdTokenClaims<AC, GC>,
signing_key: &S,
alg: JS,
access_token: Option<&AccessToken>,
code: Option<&AuthorizationCode>
) -> Result<Self, JsonWebTokenError> where
JU: JsonWebKeyUse,
K: JsonWebKey<JS, JT, JU>,
S: PrivateSigningKey<JS, JT, JU, K>,
Initializes an ID token with the specified claims, signed using the given signing key and algorithm.
If an access_token
and/or code
are provided, this method sets the at_hash
and/or
c_hash
claims using the given signing algorithm, respectively. Otherwise, those claims are
unchanged from the values specified in claims
.
pub fn claims<'a, 'b, JU, K, N>(
&'a self,
verifier: &'b IdTokenVerifier<JS, JT, JU, K>,
nonce_verifier: N
) -> Result<&'a IdTokenClaims<AC, GC>, ClaimsVerificationError> where
JU: JsonWebKeyUse,
K: JsonWebKey<JS, JT, JU>,
N: NonceVerifier<'a>,
[src]
&'a self,
verifier: &'b IdTokenVerifier<JS, JT, JU, K>,
nonce_verifier: N
) -> Result<&'a IdTokenClaims<AC, GC>, ClaimsVerificationError> where
JU: JsonWebKeyUse,
K: JsonWebKey<JS, JT, JU>,
N: NonceVerifier<'a>,
Verifies and returns the ID token claims.
pub fn signing_alg(&self) -> Result<JS, SigningError>
[src]
Returns the JwsSigningAlgorithm
used to sign this ID token.
This function returns an error if the signing algorithm is unsupported.
Trait Implementations
impl<AC: Clone + AdditionalClaims, GC: Clone + GenderClaim, JE: Clone + JweContentEncryptionAlgorithm<JT>, JS: Clone + JwsSigningAlgorithm<JT>, JT: Clone + JsonWebKeyType> Clone for IdToken<AC, GC, JE, JS, JT>
[src]
fn clone(&self) -> IdToken<AC, GC, JE, JS, JT>
[src]
fn clone_from(&mut self, source: &Self)
1.0.0[src]
impl<AC: PartialEq + AdditionalClaims, GC: PartialEq + GenderClaim, JE: PartialEq + JweContentEncryptionAlgorithm<JT>, JS: PartialEq + JwsSigningAlgorithm<JT>, JT: PartialEq + JsonWebKeyType> PartialEq<IdToken<AC, GC, JE, JS, JT>> for IdToken<AC, GC, JE, JS, JT>
[src]
fn eq(&self, other: &IdToken<AC, GC, JE, JS, JT>) -> bool
[src]
fn ne(&self, other: &IdToken<AC, GC, JE, JS, JT>) -> bool
[src]
impl<AC, GC, JE, JS, JT> ToString for IdToken<AC, GC, JE, JS, JT> where
AC: AdditionalClaims,
GC: GenderClaim,
JE: JweContentEncryptionAlgorithm<JT>,
JS: JwsSigningAlgorithm<JT>,
JT: JsonWebKeyType,
[src]
AC: AdditionalClaims,
GC: GenderClaim,
JE: JweContentEncryptionAlgorithm<JT>,
JS: JwsSigningAlgorithm<JT>,
JT: JsonWebKeyType,
impl<AC: Debug + AdditionalClaims, GC: Debug + GenderClaim, JE: Debug + JweContentEncryptionAlgorithm<JT>, JS: Debug + JwsSigningAlgorithm<JT>, JT: Debug + JsonWebKeyType> Debug for IdToken<AC, GC, JE, JS, JT>
[src]
impl<AC: AdditionalClaims, GC: GenderClaim, JE: JweContentEncryptionAlgorithm<JT>, JS: JwsSigningAlgorithm<JT>, JT: JsonWebKeyType> Serialize for IdToken<AC, GC, JE, JS, JT> where
AC: AdditionalClaims,
[src]
AC: AdditionalClaims,
fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error> where
__S: Serializer,
[src]
__S: Serializer,
impl<'de, AC: AdditionalClaims, GC: GenderClaim, JE: JweContentEncryptionAlgorithm<JT>, JS: JwsSigningAlgorithm<JT>, JT: JsonWebKeyType> Deserialize<'de> for IdToken<AC, GC, JE, JS, JT> where
AC: AdditionalClaims,
[src]
AC: AdditionalClaims,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>,
[src]
__D: Deserializer<'de>,
Auto Trait Implementations
impl<AC, GC, JE, JS, JT> Send for IdToken<AC, GC, JE, JS, JT> where
AC: Send,
GC: Send,
JE: Send,
JS: Send,
JT: Send,
AC: Send,
GC: Send,
JE: Send,
JS: Send,
JT: Send,
impl<AC, GC, JE, JS, JT> Sync for IdToken<AC, GC, JE, JS, JT> where
AC: Sync,
GC: Sync,
JE: Sync,
JS: Sync,
JT: Sync,
AC: Sync,
GC: Sync,
JE: Sync,
JS: Sync,
JT: Sync,
impl<AC, GC, JE, JS, JT> Unpin for IdToken<AC, GC, JE, JS, JT> where
AC: Unpin,
GC: Unpin,
JE: Unpin,
JS: Unpin,
JT: Unpin,
AC: Unpin,
GC: Unpin,
JE: Unpin,
JS: Unpin,
JT: Unpin,
impl<AC, GC, JE, JS, JT> UnwindSafe for IdToken<AC, GC, JE, JS, JT> where
AC: UnwindSafe,
GC: UnwindSafe,
JE: UnwindSafe,
JS: UnwindSafe,
JT: UnwindSafe,
AC: UnwindSafe,
GC: UnwindSafe,
JE: UnwindSafe,
JS: UnwindSafe,
JT: UnwindSafe,
impl<AC, GC, JE, JS, JT> RefUnwindSafe for IdToken<AC, GC, JE, JS, JT> where
AC: RefUnwindSafe,
GC: RefUnwindSafe,
JE: RefUnwindSafe,
JS: RefUnwindSafe,
JT: RefUnwindSafe,
AC: RefUnwindSafe,
GC: RefUnwindSafe,
JE: RefUnwindSafe,
JS: RefUnwindSafe,
JT: RefUnwindSafe,
Blanket Implementations
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> From<T> for T
[src]
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T> ToString for T where
T: Display + ?Sized,
[src]
T: Display + ?Sized,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> DeserializeOwned for T where
T: Deserialize<'de>,
[src]
T: Deserialize<'de>,
impl<T> Erased for T
impl<T> Same<T> for T
type Output = T
Should always be Self
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
U: TryFrom<T>,