encryption

package
v1.16.0 Latest Latest
Warning

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

Go to latest
Published: Mar 10, 2021 License: AGPL-3.0 Imports: 6 Imported by: 0

Documentation

Overview

Package encryption handles all KMS operations.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type API

type API interface {
	DecryptConfig([]byte, interface{}) error
	EncryptConfig(interface{}) ([]byte, error)
}

API defines the interface which can be used for mocking.

type Key

type Key struct {
	ID *string
	// contains filtered or unexported fields
}

Key encapsulates a connection to the KMS encryption key.

func New

func New(ID string, sess *session.Session) *Key

New creates AWS clients to interface with the encryption key.

func (*Key) DecryptConfig

func (key *Key) DecryptConfig(ciphertext []byte, config interface{}) error

DecryptConfig uses KMS to decrypt an output configuration.

func (*Key) EncryptConfig

func (key *Key) EncryptConfig(config interface{}) ([]byte, error)

EncryptConfig uses KMS to encrypt an output configuration.

Jump to

Keyboard shortcuts

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