pub trait TokenSource: Send + Sync {
// Required method
fn extract(&self, parts: &Parts) -> Option<String>;
}Expand description
Trait for extracting JWT token strings from HTTP requests.
Middleware tries sources in order and uses the first Some(token).
Implement this trait to support custom token locations.