Documentation ¶
Index ¶
- type Connector
- func (c *Connector) CanIGetRoles(serviceAccountName, namespace, vaultAuthPath, dbRole string) (bool, error)
- func (c *Connector) CreateOrphanToken(ctx context.Context, ttl string, policies []string) (string, error)
- func (c *Connector) DeleteData(ctx context.Context, podName, secretName, uuid, namespace, prefix string) (string, error)
- func (c *Connector) GetDbCredentials(ctx context.Context, ...) (*DbCreds, error)
- func (c *Connector) GetKeyInformations(ctx context.Context, podName, uuid, path, prefix string) (*KeyInformation, error)
- func (c *Connector) GetToken() string
- func (c *Connector) HandlePodDeletionToken(ctx context.Context, keysInformation *KeyInformation, ...) error
- func (c *Connector) HandleTokens(ctx context.Context, cfg *config.Config, keysInformations []*KeyInformation, ...) bool
- func (c *Connector) ListKeyInformations(ctx context.Context, path, prefix string) ([]*KeyInformation, error)
- func (c *Connector) Login(ctx context.Context) error
- func (c *Connector) RenewLease(ctx context.Context, leaseID string, leaseTTL int, uuid, namespace string) error
- func (c *Connector) RenewSelfToken(ctx context.Context) error
- func (c *Connector) RenewToken(ctx context.Context, tokenId, uuid, namespace string, SyncTTLSecond int) error
- func (c *Connector) RevokeOrphanToken(ctx context.Context, tokenId, uuid, namespace string) error
- func (c *Connector) RevokeSelfToken(ctx context.Context, tokenId, uuid, namespace string)
- func (c *Connector) SetToken(token string)
- func (c *Connector) StartTokenRenewal(ctx context.Context, cfg *config.Config)
- func (c *Connector) StoreData(ctx context.Context, vaultInformation *KeyInformation, ...) (string, error)
- type DbCreds
- type KeyInformation
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Connector ¶
type Connector struct { K8sSaVaultToken string RenewalInterval time.Duration Log logger.Logger VaultRateLimit int // contains filtered or unexported fields }
func ConnectToVault ¶
func NewConnector ¶
func (*Connector) CanIGetRoles ¶
func (*Connector) CreateOrphanToken ¶
func (*Connector) DeleteData ¶
func (*Connector) GetDbCredentials ¶
func (*Connector) GetKeyInformations ¶
func (*Connector) HandlePodDeletionToken ¶
func (*Connector) HandleTokens ¶
func (*Connector) ListKeyInformations ¶
func (*Connector) RenewLease ¶
func (*Connector) RenewToken ¶
func (*Connector) RevokeOrphanToken ¶
func (*Connector) RevokeSelfToken ¶
func (*Connector) StartTokenRenewal ¶
Permit to the renewer to renew is self token using to connect on Vault
type KeyInformation ¶
type KeyInformation struct { PodNameUID string LeaseId string TokenId string Namespace string PodName string NodeName string ServiceAccount string }
func NewKeyInformation ¶
func NewKeyInformation(podUuid, leaseId, tokenId, namespace, serviceAccount string, podName ...string) *KeyInformation
Click to show internal directories.
Click to hide internal directories.