[][src]Struct jwt_compact::Header

pub struct Header {
    pub key_set_url: Option<String>,
    pub key_id: Option<String>,
    pub certificate_url: Option<String>,
    pub certificate_thumbprint: Option<String>,
    pub signature_type: Option<String>,
}

JWT header.

See RFC 7515 for the description of the fields. The purpose of all fields except signature_type is to determine the verifying key. Since these values will be provided by the adversary in the case of an attack, they require additional verification (e.g., a provided certificate might be checked against the list of "acceptable" certificate authorities).

Fields

key_set_url: Option<String>

URL of the JSON Web Key Set containing the key that has signed the token. This field is renamed to jku for serialization.

key_id: Option<String>

Identifier of the key that has signed the token. This field is renamed to kid for serialization.

certificate_url: Option<String>

URL of the X.509 certificate for the signing key. This field is renamed to x5u for serialization.

certificate_thumbprint: Option<String>

Thumbprint of the X.509 certificate for the signing key. This field is renamed to x5t for serialization.

signature_type: Option<String>

Application-specific signature type. This field is renamed to typ for serialization.

Trait Implementations

impl Default for Header[src]

impl Clone for Header[src]

fn clone_from(&mut self, source: &Self)1.0.0[src]

Performs copy-assignment from source. Read more

impl Debug for Header[src]

impl Serialize for Header[src]

impl<'de> Deserialize<'de> for Header[src]

Auto Trait Implementations

impl Send for Header

impl Unpin for Header

impl Sync for Header

impl UnwindSafe for Header

impl RefUnwindSafe for Header

Blanket Implementations

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> DeserializeOwned for T where
    T: Deserialize<'de>, 
[src]

impl<T> Same<T> for T

type Output = T

Should always be Self

impl<T> Clear for T where
    T: InitializableFromZeroed + ?Sized
[src]

impl<T> InitializableFromZeroed for T where
    T: Default
[src]