pub enum CredentialSource {
AuthorizationHeader,
QueryParam {
param: String,
},
Cookie {
name: String,
},
Header {
name: String,
},
}Expand description
Re-export of the CredentialSource contract type, which now lives in
camel-api so camel-core and camel-dsl can reference it without depending
on this crate. Keeps every existing camel_auth::CredentialSource path
(e.g. camel-ws, camel-component-api) compiling unchanged.
Source from which a token can be extracted.
exhaustive-by-contract: closed source set; out-of-crate camel-auth extraction matches all variants, so adding a source must update every match site by review.
Variants§
AuthorizationHeader
Extract from the Authorization header (Bearer scheme).
QueryParam
Extract from a query parameter with the given name.
Cookie
Extract from a cookie with the given name.
Header
Extract from a named request header (API-key style).
The extracted value flows into the same constant-time
NativeCredentialStore::lookup as every other source.
ApiKeyAuthenticator is superseded for YAML use; its programmatic API
stays.
Implementations§
Source§impl CredentialSource
impl CredentialSource
Sourcepub fn variant_name(&self) -> &'static str
pub fn variant_name(&self) -> &'static str
Returns the variant name without exposing sensitive values.
Trait Implementations§
Source§impl Clone for CredentialSource
impl Clone for CredentialSource
Source§fn clone(&self) -> CredentialSource
fn clone(&self) -> CredentialSource
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more