Skip to main content

token_matches

Function token_matches 

Source
pub fn token_matches(header: Option<&str>, expected: &str) -> bool
Expand description

Compares the presented bearer token with the configured one without stopping at the first difference. The scheme name is case-insensitive (RFC 7235), so bearer … works as well.