crypto

package
v1.1.2 Latest Latest
Warning

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

Go to latest
Published: Jun 25, 2019 License: Apache-2.0 Imports: 10 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

View Source
const (
	AES = "AES"
	RSA = "RSA"
)

consts

Variables

This section is empty.

Functions

func NewDecryptor

func NewDecryptor(alog string) cccsp.Decryptor

NewDecryptor creates a new decryptor

func NewEncryptor

func NewEncryptor(alog string) cccsp.Encryptor

NewEncryptor creates a new encryptor

Types

type AESCBCPKCS7Opts

type AESCBCPKCS7Opts struct {
	// IV is the initialization vector to be used by the underlying cihper.
	IV []byte

	// PRNG is an interface of a PRNG to be used by the underlying cihper.
	PRNG io.Reader
}

AESCBCPKCS7Opts contains options for AES encryption in CBC mode with PKCS7 padding.

type RSAOAEPOpts

type RSAOAEPOpts struct {
	Label []byte
	Hash  hash.Hash
}

RSAOAEPOpts contains options for RSA-OAEP encryption.

type RSAPKCS1v15Opts

type RSAPKCS1v15Opts struct{}

RSAPKCS1v15Opts contains options for RSA and the padding scheme from PKCS#1 v1.5

Jump to

Keyboard shortcuts

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