Documentation ¶
Index ¶
- func ClientWithLoginMock(_ *vault.Config) (util.Client, error)
- type Auth
- type DeleteWithContextFn
- type ListWithContextFn
- type Logical
- func (f Logical) DeleteWithContext(ctx context.Context, path string) (*vault.Secret, error)
- func (f Logical) ListWithContext(ctx context.Context, path string) (*vault.Secret, error)
- func (f Logical) ReadWithDataWithContext(ctx context.Context, path string, data map[string][]string) (*vault.Secret, error)
- func (f Logical) WriteWithContext(ctx context.Context, path string, data map[string]interface{}) (*vault.Secret, error)
- type LoginFn
- type LookupSelfWithContextFn
- type MockAddHeaderFn
- type MockClearTokenFn
- type MockSetNamespaceFn
- type MockSetTokenFn
- type MockTokenFn
- type ReadWithDataWithContextFn
- type RevokeSelfWithContextFn
- type Token
- type VaultClient
- func (c *VaultClient) AddHeader(key, value string)
- func (c *VaultClient) Auth() Auth
- func (c *VaultClient) AuthToken() Token
- func (c *VaultClient) ClearToken()
- func (c *VaultClient) Logical() Logical
- func (c *VaultClient) SetNamespace(namespace string)
- func (c *VaultClient) SetToken(v string)
- func (c *VaultClient) Token() string
- type VaultListResponse
- type WriteWithContextFn
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Auth ¶ added in v0.5.2
type Auth struct {
LoginFn LoginFn
}
func NewVaultAuth ¶ added in v0.5.2
func NewVaultAuth() Auth
type DeleteWithContextFn ¶ added in v0.7.0
func NewDeleteWithContextFn ¶ added in v0.7.0
func NewDeleteWithContextFn(secret map[string]interface{}, err error) DeleteWithContextFn
type ListWithContextFn ¶ added in v0.5.2
type Logical ¶ added in v0.5.2
type Logical struct { ReadWithDataWithContextFn ReadWithDataWithContextFn ListWithContextFn ListWithContextFn WriteWithContextFn WriteWithContextFn DeleteWithContextFn DeleteWithContextFn }
func NewVaultLogical ¶ added in v0.5.2
func NewVaultLogical() Logical
func (Logical) DeleteWithContext ¶ added in v0.7.0
func (Logical) ListWithContext ¶ added in v0.5.2
func (Logical) ReadWithDataWithContext ¶ added in v0.5.2
type LookupSelfWithContextFn ¶ added in v0.5.2
type MockAddHeaderFn ¶ added in v0.4.0
type MockAddHeaderFn func(key, value string)
func NewAddHeaderFn ¶ added in v0.4.0
func NewAddHeaderFn() MockAddHeaderFn
type MockClearTokenFn ¶ added in v0.3.6
type MockClearTokenFn func()
func NewClearTokenFn ¶ added in v0.3.6
func NewClearTokenFn() MockClearTokenFn
type MockSetNamespaceFn ¶
type MockSetNamespaceFn func(namespace string)
func NewSetNamespaceFn ¶
func NewSetNamespaceFn() MockSetNamespaceFn
type MockSetTokenFn ¶
type MockSetTokenFn func(v string)
func NewSetTokenFn ¶
func NewSetTokenFn(ofn ...func(v string)) MockSetTokenFn
type MockTokenFn ¶ added in v0.3.6
type MockTokenFn func() string
func NewTokenFn ¶ added in v0.3.6
func NewTokenFn(v string) MockTokenFn
type ReadWithDataWithContextFn ¶ added in v0.5.2
type ReadWithDataWithContextFn func(ctx context.Context, path string, data map[string][]string) (*vault.Secret, error)
func NewReadMetadataWithContextFn ¶ added in v0.7.3
func NewReadMetadataWithContextFn(secret map[string]interface{}, err error) ReadWithDataWithContextFn
func NewReadWithContextFn ¶ added in v0.5.2
func NewReadWithContextFn(secret map[string]interface{}, err error) ReadWithDataWithContextFn
type RevokeSelfWithContextFn ¶ added in v0.5.2
type Token ¶ added in v0.5.2
type Token struct { RevokeSelfWithContextFn RevokeSelfWithContextFn LookupSelfWithContextFn LookupSelfWithContextFn }
func NewAuthTokenFn ¶ added in v0.6.0
func NewAuthTokenFn() Token
func (Token) LookupSelfWithContext ¶ added in v0.5.2
type VaultClient ¶
type VaultClient struct { MockLogical Logical MockAuth Auth MockAuthToken Token MockSetToken MockSetTokenFn MockToken MockTokenFn MockClearToken MockClearTokenFn MockSetNamespace MockSetNamespaceFn MockAddHeader MockAddHeaderFn }
func (*VaultClient) AddHeader ¶ added in v0.4.0
func (c *VaultClient) AddHeader(key, value string)
func (*VaultClient) Auth ¶ added in v0.5.2
func (c *VaultClient) Auth() Auth
func (*VaultClient) AuthToken ¶ added in v0.5.2
func (c *VaultClient) AuthToken() Token
func (*VaultClient) ClearToken ¶ added in v0.3.6
func (c *VaultClient) ClearToken()
func (*VaultClient) Logical ¶ added in v0.5.2
func (c *VaultClient) Logical() Logical
func (*VaultClient) SetNamespace ¶
func (c *VaultClient) SetNamespace(namespace string)
func (*VaultClient) SetToken ¶
func (c *VaultClient) SetToken(v string)
func (*VaultClient) Token ¶ added in v0.3.6
func (c *VaultClient) Token() string
type VaultListResponse ¶ added in v0.5.0
type WriteWithContextFn ¶ added in v0.5.2
type WriteWithContextFn func(ctx context.Context, path string, data map[string]interface{}) (*vault.Secret, error)
func NewWriteWithContextFn ¶ added in v0.7.0
func NewWriteWithContextFn(secret map[string]interface{}, err error) WriteWithContextFn
func WriteChangingReadContext ¶ added in v0.7.0
func WriteChangingReadContext(secret map[string]interface{}, l Logical) WriteWithContextFn
Click to show internal directories.
Click to hide internal directories.