Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
var Backends = []keyring.BackendType{ keyring.KWalletBackend, keyring.SecretServiceBackend, keyring.KeychainBackend, keyring.WinCredBackend, keyring.PassBackend, keyring.FileBackend, }
Functions ¶
func AvailableBackends ¶
func AvailableBackends() []string
AvailableBackends returns the available backends on this platform
Types ¶
type Keyring ¶ added in v0.3.0
type Keyring struct { Backend string `mapstructure:"backend"` Config keyring.Config `mapstructure:"config"` Ring keyring.Keyring `yaml:"-"` }
func (*Keyring) Erase ¶ added in v0.3.0
Error erases the token for the vaultAddr from the token store. A missing token is not an error. Errors are returned if there are errors communicating with the token store.
func (*Keyring) Get ¶ added in v0.3.0
Get retrieves a token for the vaultAddr if one is available in the token store. A missing token is not an error. Errors are returned if there are errors communicating with the token store.
func (*Keyring) InitKeyring ¶ added in v0.3.0
InitKeyring initializes the token storage into the main package var 'backendStorage'. It is not called during the early init phase to avoid errors with commands that do not need access to a backend. Instead, commands that interact with a backend should call InitKeyring and propagate errors back to the rootCmd.
type Token ¶
Token represents a Vault token stored in a backend credential store