vault

package
v0.2.4 Latest Latest
Warning

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

Go to latest
Published: Mar 22, 2021 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client struct {
	URL      string
	DoUnseal bool
}

func NewVaultClient

func NewVaultClient(url string) (*Client, error)

func (*Client) Init

func (v *Client) Init(recoveryShares, recoveryThreshold uint8) (*InitResponse, error)

func (*Client) IsInitialized

func (v *Client) IsInitialized() bool

func (*Client) Unseal

func (v *Client) Unseal(keysBase64 []string) error

type InitRequest

type InitRequest struct {
	SecretShares    uint8 `json:"secret_shares"`
	SecretThreshold uint8 `json:"secret_threshold"`
}

type InitResponse

type InitResponse struct {
	Keys       []string `json:"keys"`
	KeysBase64 []string `json:"keys_base64"`
	RootToken  string   `json:"root_token"`
}

Jump to

Keyboard shortcuts

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