keymanage

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Oct 8, 2023 License: MIT Imports: 1 Imported by: 0

Documentation

Overview

Package keymanage defines the interface of Key Management Algorithms.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Algorithm

type Algorithm interface {
	NewKeyWrapper(key Key) KeyWrapper
}

Algorithm is an algorithm for wrapping or unwrapping Content Encryption Key (CEK).

type Key

type Key interface {
	PrivateKey() crypto.PrivateKey
	PublicKey() crypto.PublicKey
}

Key is a key for wrapping or unwrapping Content Encryption Key (CEK).

type KeyDeriver

type KeyDeriver interface {
	DeriveKey(opts any) (cek, encryptedCEK []byte, err error)
}

type KeyWrapper

type KeyWrapper interface {
	WrapKey(cek []byte, opts any) (data []byte, err error)
	UnwrapKey(data []byte, opts any) (cek []byte, err error)
}

func NewInvalidKeyWrapper

func NewInvalidKeyWrapper(err error) KeyWrapper

Jump to

Keyboard shortcuts

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