fake

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Apr 17, 2019 License: Apache-2.0 Imports: 0 Imported by: 0

Documentation

Overview

Package fake is a fake KMS provider for testing purposes

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Fake

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

Fake is a fake KMS provider

func Empty

func Empty() *Fake

Empty creates an empty (as in does nothing) fake KMS provider

func New

func New(encrypt Operation, decrypt Operation) *Fake

New creates a custom fake KMS provider

func (*Fake) Decrypt

func (f *Fake) Decrypt(ciphertext []byte) ([]byte, error)

Decrypt is a fake decryption operation

func (*Fake) Encrypt

func (f *Fake) Encrypt(plaintext []byte) ([]byte, error)

Encrypt is a fake encryption operation

type Operation

type Operation func(input []byte) ([]byte, error)

Operation represents a Fake operation

Jump to

Keyboard shortcuts

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