Skip to main content

validate_typ_header

Function validate_typ_header 

Source
pub fn validate_typ_header(
    typ: Option<&str>,
    policy: &ValidationPolicy,
) -> Result<(), AuthError>
Expand description

Check the JOSE typ header for the policy’s purpose. Call before signature verification — a wrong typ means the token is not even the right credential class.