crypto

package
v0.0.0-...-31fc120 Latest Latest
Warning

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

Go to latest
Published: Dec 5, 2019 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DecryptionKey

type DecryptionKey interface {
	EncryptionKey

	// Decrypt bytes.
	Decrypt([]byte) ([]byte, error)
}

EncryptionKey represents a key that can be used for decryption.

func ParseDecryptionKey

func ParseDecryptionKey(k []byte) (DecryptionKey, error)

ParseDecryptionKey returns a DecryptionKey from k.

type EncryptionKey

type EncryptionKey interface {
	// Encrypt bytes.
	Encrypt([]byte) ([]byte, error)

	// Marshal to bytes.
	Marshal() ([]byte, error)
}

EncryptionKey represents a key that can be used for encryption.

func ParseEncryptionKey

func ParseEncryptionKey(k []byte) (EncryptionKey, error)

ParseEncryptionKey returns an EncryptionKey from k.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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