Versions in this module Expand all Collapse all v1 v1.0.0 Feb 12, 2021 Changes in this version + var ErrNotSupportedSecret = errors.New("secret type is required") + var ErrSecretKeyMissing = errors.New("secret key is required") + var ErrVaultHostMissing = errors.New("vault host is required") + var ErrVaultTokenMissing = errors.New("vault token is required") + type Config struct + SecretKey string + SecretType SecretType + VaultConfig VaultConfig + type Decrypter interface + Decrypt func(opts Options) (string, error) + type Options struct + CipherText string + Key string + Plaintext string + type SecretType int + const DebugSecret + const LocalSecret + const VaultSecret + func (s SecretType) String() string + type Secreter interface + Decrypt func(opts Options) (string, error) + Encrypt func(opts Options) (string, error) + Type func() SecretType + func New(ctx context.Context, cfg Config) (Secreter, error) + type VaultConfig struct + Enabled bool + Host string + Token string