vaultclient

package module
v0.0.0-...-df47d94 Latest Latest
Warning

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

Go to latest
Published: Jan 5, 2018 License: Apache-2.0 Imports: 8 Imported by: 4

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

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

Client struct.

func NewClient

func NewClient(conf *Config, creds *Credentials) (Client, error)

func (*Client) Delete

func (c *Client) Delete(p string) error

Delete will delete the secret from Vault. The boolean indicates if the secret was found in the vault to be delete.

func (*Client) List

func (c *Client) List(p string) (map[string]interface{}, error)

func (*Client) Read

func (c *Client) Read(p string) (map[string]interface{}, error)

func (*Client) Write

func (c *Client) Write(p string, m map[string]interface{}) error

type Config

type Config struct {
	SecretsPath      string            `json:"SecretsPath"`
	ReSTClientConfig restclient.Config `json:"VaultConnection"`
	// contains filtered or unexported fields
}

type Credentials

type Credentials struct {
	AppID      string `json:"AppID"`
	UserID     string `json:"UserID"`
	UserIDFile string `json:"UserIDFile"`
}

func (*Credentials) ReadUserID

func (creds *Credentials) ReadUserID() error

type ErrSecretNotFound

type ErrSecretNotFound struct{}

func (ErrSecretNotFound) Error

func (e ErrSecretNotFound) Error() string

type Session

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

func (*Session) GetToken

func (s *Session) GetToken() (token string, err error)

func (*Session) NewRequest

func (s *Session) NewRequest(c *restclient.Config, a, u string) (err error)

type UserIdFile

type UserIdFile struct {
	UserID string `json:"UserID"`
}

Jump to

Keyboard shortcuts

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