vault

package
v1.0.42 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 27, 2023 License: BSD-3-Clause Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewClient

func NewClient(thelmaConfig config.Config, creds credentials.Credentials, clientOptions ...ClientOption) (*vaultapi.Client, error)

NewClient returns a new authenticated vault client

func NewVaultTokenStore

func NewVaultTokenStore() stores.Store

NewVaultTokenStore returns a token store that reads and writes values to the current user's ~/.vault-token file. (Note that token keys are ignored.)

func TokenProvider

func TokenProvider(thelmaConfig config.Config, creds credentials.Credentials, clientOptions ...ClientOption) (credentials.TokenProvider, error)

TokenProvider returns a new credentials.TokenProvider that provides a Vault token

Types

type ClientOption added in v0.0.31

type ClientOption func(*ClientOptions)

type ClientOptions added in v0.0.31

type ClientOptions struct {
	CredentialStore    stores.Store
	VaultClientOptions []func(*vaultapi.Config)
}

func (*ClientOptions) ConfigureVaultClient added in v0.0.31

func (c *ClientOptions) ConfigureVaultClient(configureFn func(*vaultapi.Config))

type MaskingRoundTripper added in v0.0.53

type MaskingRoundTripper struct {
	// contains filtered or unexported fields
}

MaskingRoundTripper implements the http.RoundTripper interface, automatically masking any secrets returned from the Vault API

func (MaskingRoundTripper) RoundTrip added in v0.0.53

func (m MaskingRoundTripper) RoundTrip(req *http.Request) (*http.Response, error)

Directories

Path Synopsis
Package testing provides utilities for testing code that requires a Vault client
Package testing provides utilities for testing code that requires a Vault client

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL