Expand description
Authentication providers for neuron.
This crate defines the AuthProvider trait for obtaining authentication
credentials to access secret backends. It also provides AuthProviderChain
for composing multiple providers (try in order until one succeeds, like
AWS DefaultCredentialsChain).
§Separation of Concerns
Auth providers produce credentials (tokens). Secret resolvers consume them.
A VaultResolver takes an Arc<dyn AuthProvider> and uses it to authenticate
before fetching secrets. This separation follows the pattern established by
AWS SDK (ProvideCredentials vs SecretsManagerClient), vaultrs
(auth::* vs kv2::*), and Google Cloud SDK.
Structs§
- Auth
Provider Chain - Tries providers in order until one succeeds.
- Auth
Request - Context for an authentication request.
- Auth
Token - An opaque authentication token with expiry.
Uses
SecretValueinternally for in-memory protection.
Enums§
- Auth
Error - Errors from authentication providers (crate-local, not in layer0).
Traits§
- Auth
Provider - Provide authentication credentials for accessing a secret backend.