Documentation ¶
Index ¶
Constants ¶
View Source
const ( Invalid = iota Outdated Valid )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CertificateLifecycle ¶
type CertificateLifecycle interface { RenewableSecret SecretLifecycle }
PKI certificate lifecycle interface
type CredentialLifecycle ¶
type CredentialLifecycle interface { ExtendableSecret RenewableSecret SecretLifecycle }
Most credential lifecycle interface
type ExtendableSecret ¶
type ExtendableSecret interface { Extend(path string) // this is unit function for measuring when to extend // checking whether secret is need to be extended or not // the logic mostly 2/3 total time IsOutdated(path string) bool }
ExtendableSecret : Interface behavior for vault extendable lease secrets (not every secret resource in vault does support lease extension).
type LeaseMetadata ¶
type LeaseMetadata struct { Id string `json:"id"` IssueTime time.Time `json:"issue_time"` ExpireTime time.Time `json:"expire_time"` LastRenewalTime time.Time `json:"last_renewal_time,omitempty"` Renewable bool `json:"renewable"` Ttl time.Duration `json:"ttl"` }
Note: format time from vault
2017-04-30T10:18:11.228946471-04:00
type RenewableSecret ¶
type RenewableSecret interface { Renew(path string) // this is unit function for measuring when to renew IsValid(path string) bool }
Interface behavior for vault renewable secret
type SecretLifecycle ¶
type SecretLifecycle interface { SecretTrait // // This combine whether secret are still valid/invalid or outdated // // see ExtendableSecret#IsOutdated and RenewableSecret#IsValid // Status(path string) Status // // this sums up and hide the underlying logic of SecretLifecycle implementation. // since the underlying implementation might not support ExtendableSecret. // Refresh(path string) }
type SecretTrait ¶
Click to show internal directories.
Click to hide internal directories.