Skip to main content

authenticate_http

Function authenticate_http 

Source
pub fn authenticate_http(
    auth: &AuthMode,
    authorization_header: Option<&str>,
    mtls_subject: Option<AuthSubject>,
) -> Result<AuthSubject, AuthError>
Expand description

HTTP-specific auth hook: extracts the bearer/JWT token from the request’s Authorization header and checks it against AuthMode.

§Errors

AuthError on missing/malformed/rejected.