Documentation ¶
Index ¶
Constants ¶
const (
DefaultApproleAuthBackendName = "approle"
)
const (
DefaultKubernetesAuthBackendName = "kubernetes"
)
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AppRoleSecretProvider ¶
type AppRoleSecretProvider struct {
// contains filtered or unexported fields
}
AppRoleSecretProvider provides a vault secret by issuing a auth/approle/login.
https://www.vaultproject.io/docs/auth/approle.html
func NewAppRoleSecretProvider ¶
func NewAppRoleSecretProvider(vaultRoleID, vaultSecretID, approleAuthBackendName string) *AppRoleSecretProvider
NewAppRoleSecretProvider creates AppRoleSecretProvider instance.
type Authenticator ¶
type Authenticator struct {
// contains filtered or unexported fields
}
Authenticator authenticates a vault client using a given SecretProvider strategy.
The Authenticator renews the currently issued vault auth token on demand at least 5 seconds before the last issued token expires.
func NewAuthenticator ¶
func NewAuthenticator(secretProvider SecretProvider) *Authenticator
func (*Authenticator) Authenticate ¶
func (a *Authenticator) Authenticate(client Client) error
Authenticate authenticates the vault client.
type KubernetesClientSet ¶
type KubernetesSecretProvider ¶
type KubernetesSecretProvider struct {
// contains filtered or unexported fields
}
KubernetesSecretProvider provides a vault secret by issuing a auth/kubernetes/login.
https://www.vaultproject.io/docs/auth/kubernetes.html
func NewKubernetesSecretProvider ¶
func NewKubernetesSecretProvider( vaultRoleID, vaultKubernetesAuthBackendName string, kubernetesClientSet KubernetesClientSet, ) *KubernetesSecretProvider
NewKubernetesSecretProvider creates KubernetesSecretProvider instance.
type SecretProvider ¶
SecretProvider can provide a vault secret by using one of the vault auth methods.
type TokenAuthenticator ¶
type TokenAuthenticator struct {
// contains filtered or unexported fields
}
TokenAuthenticator authenticates the vault client with fixed auth token.
NOTE: This authentication method is used mainly for development.
func NewTokenAuthenticator ¶
func NewTokenAuthenticator(token string) *TokenAuthenticator
func (*TokenAuthenticator) Authenticate ¶
func (a *TokenAuthenticator) Authenticate(client Client) error