vault

package
v1.10.0 Latest Latest
Warning

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

Go to latest
Published: Jan 28, 2023 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

View Source
const (
	HttpDefaultTimeout          = 10 * time.Second
	AwsIamPropagationImpediment = 20 * time.Second
)

Variables

This section is empty.

Functions

func ConvertCredentials

func ConvertCredentials(dynamicCredentials Credentials) credentials.Value

Types

type AuthReply

type AuthReply struct {
	Renewable     bool     `json:"renewable"`
	LeaseDuration int      `json:"lease_duration"`
	Metadata      []string `json:"metadata,omitempty"`
	TokenPolicies []string `json:"token_policies"`
	Accessor      string   `json:"accessor"`
	ClientToken   string   `json:"client_token"`
}

type Credentials

type Credentials struct {
	AccessKey     string `json:"access_key"`
	SecretKey     string `json:"secret_key"`
	SecurityToken string `json:"security_token"`
}

type TokenInfo

type TokenInfo struct {
	IssueTime   time.Time         `json:"issue_time"`
	ExpireTime  time.Time         `json:"expire_time"`
	DisplayName string            `json:"display_name"`
	Policies    []string          `json:"policies"`
	Metadata    map[string]string `json:"meta"`
	NumUses     int               `json:"num_uses"`
}

type VaultCredentialProvider

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

func NewVaultCredentialProvider

func NewVaultCredentialProvider(conf *conf.VaultConfig) (*VaultCredentialProvider, error)

func (*VaultCredentialProvider) IsExpired

func (m *VaultCredentialProvider) IsExpired() bool

func (*VaultCredentialProvider) LookupToken

func (m *VaultCredentialProvider) LookupToken() error

func (*VaultCredentialProvider) Retrieve

type VaultCredentialResponse

type VaultCredentialResponse struct {
	Data          Credentials `json:"data,omitempty"`
	Auth          AuthReply   `json:"auth,omitempty"`
	Renewable     bool        `json:"renewable"`
	LeaseDuration int         `json:"lease_duration"`
	Warnings      []string    `json:"warnings"`
	RequestId     string      `json:"request_id"`
	LeaseId       string      `json:"lease_id"`
}

Jump to

Keyboard shortcuts

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