kdf

package
v1.2.2-dev.102 Latest Latest
Warning

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

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

Documentation

Overview

Package kdf implements the key deriviation function (KDF) for creation of encryption keys to protect the Vault key shares

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type KeyDeriver

type KeyDeriver interface {
	// DeriveKey returns a byte array that is of keyLen length and
	// an error if errors where encountered while deriving the key
	// inputKeyingMaterial and info are inputs
	// to the key deriviation function, an keyLen
	// is the desired length of the derived key.
	// inputKeyingMaterial is a secret
	// and info is used to cause the KDF to generate
	// different output keys from the same inputKeyingMaterial.
	// Please see the application notes for RFC 5869
	// https://tools.ietf.org/html/rfc5869#3 for
	// details for details about the key derivation algorithm.
	DeriveKey(inputKeyingMaterial []byte, keyLen uint, info string) ([]byte, error)
}

KeyDeriver is the interface that the main program expects for returning a derived key.

func NewKdf

func NewKdf(fileIoPerformer fileioperformer.FileIoPerformer, persistencePath string, hashConstructor func() hash.Hash) KeyDeriver

NewKdf creates a new KeyDeriver

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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