keystore

package
v0.0.0-...-17e6b21 Latest Latest
Warning

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

Go to latest
Published: Oct 30, 2024 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type HSMKeyStore

type HSMKeyStore struct {
	// contains filtered or unexported fields
}

func NewHSMKeyStore

func NewHSMKeyStore(metrics *metrics.QuantumStorageMetrics, tracer tracing.Tracer) *HSMKeyStore

func (*HSMKeyStore) GetKey

func (ks *HSMKeyStore) GetKey(ctx context.Context, keyID string) (*KeyMetadata, error)

func (*HSMKeyStore) ListKeys

func (ks *HSMKeyStore) ListKeys(ctx context.Context, filter map[string]string) ([]*KeyMetadata, error)

func (*HSMKeyStore) RevokeKey

func (ks *HSMKeyStore) RevokeKey(ctx context.Context, keyID string) error

func (*HSMKeyStore) StoreKey

func (ks *HSMKeyStore) StoreKey(ctx context.Context, keyType string, key []byte, metadata *KeyMetadata) error

type KeyMetadata

type KeyMetadata struct {
	ID            string
	Algorithm     string
	CreatedAt     time.Time
	ExpiresAt     time.Time
	Status        KeyStatus
	Version       int
	RotationCount int
	Tags          map[string]string
}

type KeyStatus

type KeyStatus string
const (
	KeyStatusActive   KeyStatus = "active"
	KeyStatusInactive KeyStatus = "inactive"
	KeyStatusRotating KeyStatus = "rotating"
	KeyStatusRevoked  KeyStatus = "revoked"
)

Jump to

Keyboard shortcuts

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