store

package
v0.0.0-...-7799e87 Latest Latest
Warning

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

Go to latest
Published: Nov 2, 2020 License: GPL-3.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func EncodeId

func EncodeId(record VersionedSecretMetaData) (string, error)

func GetStore

func GetStore(bvConfig config.Configuration) secret.Store

Types

type RedirectStore

type RedirectStore struct {
	Rules        []Rule
	Vaults       []vault.Vault
	DefaultVault vault.Vault
}

func (*RedirectStore) DeleteByName

func (rs *RedirectStore) DeleteByName(name string) error

func (*RedirectStore) Exists

func (rs *RedirectStore) Exists(name string) bool

func (*RedirectStore) GetById

func (rs *RedirectStore) GetById(id string) (s secret.Secret, err error)

func (*RedirectStore) GetByName

func (rs *RedirectStore) GetByName(name string) (secrets []secret.Secret, err error)

func (*RedirectStore) GetLatestByName

func (rs *RedirectStore) GetLatestByName(name string) (secret.Secret, error)

func (*RedirectStore) Healthy

func (rs *RedirectStore) Healthy() bool

func (*RedirectStore) Set

func (rs *RedirectStore) Set(name string, value interface{}) (string, error)

type Rule

type Rule struct {
	Ref      string
	Redirect string
	Type     string
	Vault    *vault.Vault
}

type SimpleStore

type SimpleStore struct {
	Vault vault.Vault
}

func TestHealthySimpleStore

func TestHealthySimpleStore(t *testing.T) (SimpleStore, net.Listener, error)

func TestSealedSimpleStore

func TestSealedSimpleStore(t *testing.T) (SimpleStore, net.Listener, error)

func TestUninitializedVaultSimpleStore

func TestUninitializedVaultSimpleStore(t *testing.T) (SimpleStore, net.Listener, error)

func (*SimpleStore) DeleteByName

func (vs *SimpleStore) DeleteByName(name string) error

func (*SimpleStore) Exists

func (vs *SimpleStore) Exists(name string) bool

func (*SimpleStore) GetById

func (vs *SimpleStore) GetById(id string) (secret.Secret, error)

func (*SimpleStore) GetByName

func (vs *SimpleStore) GetByName(name string) ([]secret.Secret, error)

func (*SimpleStore) GetLatestByName

func (vs *SimpleStore) GetLatestByName(name string) (secret.Secret, error)

func (*SimpleStore) Healthy

func (vs *SimpleStore) Healthy() bool

func (*SimpleStore) Set

func (vs *SimpleStore) Set(name string, value interface{}) (string, error)

type VaultTestData

type VaultTestData struct {
	Path  string
	Value interface{}
	Seed  bool
	Id    string
}

type VersionedSecretMetaData

type VersionedSecretMetaData struct {
	Name    string      `json:"name"`
	Version json.Number `json:"version"`
}

func DecodeId

func DecodeId(id string) (VersionedSecretMetaData, error)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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