[][src]Trait aliri_jose::jwt::CoreClaims

pub trait CoreClaims {
    fn nbf(&self) -> Option<UnixTime> { ... }
fn exp(&self) -> Option<UnixTime> { ... }
fn aud(&self) -> &Audiences { ... }
fn iss(&self) -> Option<&IssuerRef> { ... }
fn sub(&self) -> Option<&SubjectRef> { ... } }

Core claims that most compliant and secure JWT tokens should have

Provided methods

fn nbf(&self) -> Option<UnixTime>

Not before

A verifier MUST reject this token before the given time.

fn exp(&self) -> Option<UnixTime>

Expires

A verifier MUST reject this token after the given time.

fn aud(&self) -> &Audiences

Audience

A verifier MUST reject this token none of the audiences specified is an approved.

fn iss(&self) -> Option<&IssuerRef>

Issuer

A verifier MUST reject this token if it the issuer is not approved.

fn sub(&self) -> Option<&SubjectRef>

Subject

A verifier SHOULD verify that the subject is acceptable.

Loading content...

Implementors

impl CoreClaims for Empty[src]

impl<P> CoreClaims for Claims<P>[src]

Loading content...