encryption

package
v0.0.0-...-ac8b7ce Latest Latest
Warning

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

Go to latest
Published: Jan 27, 2021 License: GPL-3.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

View Source
const KeyLength = 32

Variables

This section is empty.

Functions

func New

func New(padding int, initCtr uint32, hashFunc func() hash.Hash) *encryption

Types

type Encryption

type Encryption interface {
	Encrypt(data []byte, key Key) ([]byte, error)
	Decrypt(data []byte, key Key) ([]byte, error)
}

type Key

type Key []byte

func GenerateRandomKey

func GenerateRandomKey() (Key, error)

Jump to

Keyboard shortcuts

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