Documentation ¶
Index ¶
Constants ¶
const MaxSize = 1 * mem.MiB
MaxSize is the maximum size of a secret.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Iter ¶ added in v0.22.3
type Iter interface { // Next fetches the next secret entry. It returns // false when there are no more entries or once it // encounters an error. // // Once Next returns false, it returns false on any // subsequent Next call. Next() bool // Name returns the name of the latest fetched entry. // It returns the same name until Next is called again. // // As long as Next hasn't been called once or once Next // returns false, Name returns the empty string. Name() string // Close closes the Iter. Once closed, any subsequent // Next call returns false. // // Close returns the first error encountered while iterating // over the entires, if any. Otherwise, it returns the error // encountered while cleaning up any resources, if any. // Subsequent calls to Close return the same error. Close() error }
Iter is an iterator over secrets.
type Secret ¶
type Secret struct {
// contains filtered or unexported fields
}
Secret is a generic secret, like a password, API key, or private key.
func NewSecret ¶ added in v0.22.3
NewSecret returns a new generic Secret from the given value.
Its CreatedAt timestamp is time.Now and its CreatedBy identity is the owner.
func (*Secret) CreatedAt ¶ added in v0.22.3
CreatedAt returns the point in time when the secret has been created.
func (*Secret) MarshalBinary ¶ added in v0.22.3
MarshalBinary returns the Secret's binary representation.
func (*Secret) ModTime ¶ added in v0.22.3
ModTime returns the most recent point in time at which the secret has been modified. If the secret has never been modified, its ModTime is equal to its CreatedAt time.
func (*Secret) Type ¶ added in v0.22.3
func (s *Secret) Type() kes.SecretType
Type returns the Secret's type.
func (*Secret) UnmarshalBinary ¶ added in v0.22.3
UnmarshalBinary unmarshals the Secret's binary representation.