keychain

package
v0.0.0-...-cbad420 Latest Latest
Warning

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

Go to latest
Published: Apr 15, 2022 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

View Source
const (
	CredentialsTypePrivileged   = "privileged"
	CredentialsTypeUnprivileged = "unprivileged"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type KeychainStore

type KeychainStore struct{}

func (*KeychainStore) RetrieveCredentials

func (k *KeychainStore) RetrieveCredentials(cluster, credentialsType string) (*KubernetesCredentials, error)

func (*KeychainStore) RetrieveRegistration

func (k *KeychainStore) RetrieveRegistration(rawKeyhandle []byte) (*u2f.Registration, error)

func (*KeychainStore) StoreCredentials

func (k *KeychainStore) StoreCredentials(credentials *KubernetesCredentials) error

func (*KeychainStore) StoreRegistration

func (k *KeychainStore) StoreRegistration(registration *u2f.Registration) error

type KubernetesCredentials

type KubernetesCredentials struct {
	Cluster         string `json:"cluster"`
	ExpectedExpiry  string `json:"expected_expiry"`
	CredentialsType string `json:"credentials_type"`
	AccessToken     string `json:"access_token"`
	RefreshToken    string `json:"refresh_token"`

	// KeyHandle from U2F is set by the package for privileged credentials only
	KeyHandle string `json:"keyhandle"`
}

KubernetesCredentials represents OIDC tokens issued for access to

func (*KubernetesCredentials) ToKeychainPayload

func (c *KubernetesCredentials) ToKeychainPayload() ([]byte, error)

Jump to

Keyboard shortcuts

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