gostdlib

package
v0.3.5 Latest Latest
Warning

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

Go to latest
Published: Nov 8, 2024 License: GPL-3.0 Imports: 21 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

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AesCTR

type AesCTR struct {
	tools.ToolLogicBase
	// contains filtered or unexported fields
}

AesCTR implements the cryptographic interface for AES-CTR encryption.

func (*AesCTR) Decrypt

func (aesctr *AesCTR) Decrypt(data []byte) ([]byte, error)

Decrypt implements the ToolLogic interface.

func (*AesCTR) Encrypt

func (aesctr *AesCTR) Encrypt(data []byte) ([]byte, error)

Encrypt implements the ToolLogic interface.

func (*AesCTR) Reset

func (aesctr *AesCTR) Reset() error

Reset implements the ToolLogic interface.

func (*AesCTR) Setup

func (aesctr *AesCTR) Setup() (err error)

Setup implements the ToolLogic interface.

type AesGCM

type AesGCM struct {
	tools.ToolLogicBase
	// contains filtered or unexported fields
}

AesGCM implements the cryptographic interface for AES-GCM encryption.

func (*AesGCM) AuthenticatedDecrypt

func (aesgcm *AesGCM) AuthenticatedDecrypt(data, associatedData []byte) ([]byte, error)

AuthenticatedDecrypt implements the ToolLogic interface.

func (*AesGCM) AuthenticatedEncrypt

func (aesgcm *AesGCM) AuthenticatedEncrypt(data, associatedData []byte) ([]byte, error)

AuthenticatedEncrypt implements the ToolLogic interface.

func (*AesGCM) Reset

func (aesgcm *AesGCM) Reset() error

Reset implements the ToolLogic interface.

func (*AesGCM) Setup

func (aesgcm *AesGCM) Setup() (err error)

Setup implements the ToolLogic interface.

type ChaCha20Poly1305

type ChaCha20Poly1305 struct {
	tools.ToolLogicBase
	// contains filtered or unexported fields
}

ChaCha20Poly1305 implements the cryptographic interface for ChaCha20-Poly1305 encryption.

func (*ChaCha20Poly1305) AuthenticatedDecrypt

func (chapo *ChaCha20Poly1305) AuthenticatedDecrypt(data, associatedData []byte) ([]byte, error)

AuthenticatedDecrypt implements the ToolLogic interface.

func (*ChaCha20Poly1305) AuthenticatedEncrypt

func (chapo *ChaCha20Poly1305) AuthenticatedEncrypt(data, associatedData []byte) ([]byte, error)

AuthenticatedEncrypt implements the ToolLogic interface.

func (*ChaCha20Poly1305) Reset

func (chapo *ChaCha20Poly1305) Reset() error

Reset implements the ToolLogic interface.

func (*ChaCha20Poly1305) Setup

func (chapo *ChaCha20Poly1305) Setup() (err error)

Setup implements the ToolLogic interface.

type Ed25519

type Ed25519 struct {
	tools.ToolLogicBase
}

Ed25519 implements the cryptographic interface for Ed25519 signatures.

func (*Ed25519) BurnKey

func (ed *Ed25519) BurnKey(signet tools.SignetInt) error

BurnKey implements the ToolLogic interface. This is currently ineffective, see known issues in the project's README.

func (*Ed25519) GenerateKey

func (ed *Ed25519) GenerateKey(signet tools.SignetInt) error

GenerateKey implements the ToolLogic interface.

func (*Ed25519) LoadKey

func (ed *Ed25519) LoadKey(signet tools.SignetInt) error

LoadKey implements the ToolLogic interface.

func (*Ed25519) Sign

func (ed *Ed25519) Sign(data, associatedData []byte, signet tools.SignetInt) ([]byte, error)

Sign implements the ToolLogic interface.

func (*Ed25519) StoreKey

func (ed *Ed25519) StoreKey(signet tools.SignetInt) error

StoreKey implements the ToolLogic interface.

func (*Ed25519) Verify

func (ed *Ed25519) Verify(data, associatedData, signature []byte, signet tools.SignetInt) error

Verify implements the ToolLogic interface.

type HKDF

type HKDF struct {
	tools.ToolLogicBase
	// contains filtered or unexported fields
}

HKDF implements the cryptographic interface for HKDF key derivation.

func (*HKDF) DeriveKey

func (keyder *HKDF) DeriveKey(size int) ([]byte, error)

DeriveKey implements the ToolLogic interface.

func (*HKDF) DeriveKeyWriteTo

func (keyder *HKDF) DeriveKeyWriteTo(newKey []byte) error

DeriveKeyWriteTo implements the ToolLogic interface.

func (*HKDF) InitKeyDerivation

func (keyder *HKDF) InitKeyDerivation(nonce []byte, material ...[]byte) error

InitKeyDerivation implements the ToolLogic interface.

type HMAC

type HMAC struct {
	tools.ToolLogicBase
	// contains filtered or unexported fields
}

HMAC implements the cryptographic interface for HMAC message authentication codes.

func (*HMAC) MAC

func (hm *HMAC) MAC(data, associatedData []byte) ([]byte, error)

MAC implements the ToolLogic interface.

func (*HMAC) Reset

func (hm *HMAC) Reset() error

Reset implements the ToolLogic interface.

func (*HMAC) Setup

func (hm *HMAC) Setup() (err error)

Setup implements the ToolLogic interface.

type PBKDF2

type PBKDF2 struct {
	tools.ToolLogicBase
	// contains filtered or unexported fields
}

PBKDF2 implements the cryptographic interface for PBKDF2 password derivation.

func (*PBKDF2) DeriveKeyFromPassword

func (pd *PBKDF2) DeriveKeyFromPassword(password []byte, salt []byte) ([]byte, error)

DeriveKeyFromPassword implements the ToolLogic interface.

type Poly1305

type Poly1305 struct {
	tools.ToolLogicBase
	// contains filtered or unexported fields
}

Poly1305 implements the cryptographic interface for Poly1305 message authentication codes.

func (*Poly1305) MAC

func (poly *Poly1305) MAC(data, associatedData []byte) ([]byte, error)

MAC implements the ToolLogic interface.

func (*Poly1305) Reset

func (poly *Poly1305) Reset() error

Reset implements the ToolLogic interface.

func (*Poly1305) Setup

func (poly *Poly1305) Setup() (err error)

Setup implements the ToolLogic interface.

type RsaOAEP

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

RsaOAEP implements the cryptographic interface for RSA OAEP encryption.

func (*RsaOAEP) BurnKey

func (base *RsaOAEP) BurnKey(signet tools.SignetInt) error

BurnKey implements the ToolLogic interface. This is currently ineffective, see known issues in the project's README.

func (*RsaOAEP) EncapsulateKey

func (oaep *RsaOAEP) EncapsulateKey(key []byte, signet tools.SignetInt) ([]byte, error)

EncapsulateKey implements the ToolLogic interface.

func (*RsaOAEP) GenerateKey

func (base *RsaOAEP) GenerateKey(signet tools.SignetInt) error

GenerateKey implements the ToolLogic interface.

func (*RsaOAEP) LoadKey

func (base *RsaOAEP) LoadKey(signet tools.SignetInt) error

LoadKey implements the ToolLogic interface.

func (*RsaOAEP) SecurityLevel

func (base *RsaOAEP) SecurityLevel(signet tools.SignetInt) (int, error)

SecurityLevel implements the ToolLogic interface.

func (*RsaOAEP) StoreKey

func (base *RsaOAEP) StoreKey(signet tools.SignetInt) error

StoreKey implements the ToolLogic interface.

func (*RsaOAEP) UnwrapKey

func (oaep *RsaOAEP) UnwrapKey(wrappedKey []byte, signet tools.SignetInt) ([]byte, error)

UnwrapKey implements the ToolLogic interface.

type RsaPSS

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

RsaPSS implements the cryptographic interface for RSA PSS signatures.

func (*RsaPSS) BurnKey

func (base *RsaPSS) BurnKey(signet tools.SignetInt) error

BurnKey implements the ToolLogic interface. This is currently ineffective, see known issues in the project's README.

func (*RsaPSS) GenerateKey

func (base *RsaPSS) GenerateKey(signet tools.SignetInt) error

GenerateKey implements the ToolLogic interface.

func (*RsaPSS) LoadKey

func (base *RsaPSS) LoadKey(signet tools.SignetInt) error

LoadKey implements the ToolLogic interface.

func (*RsaPSS) SecurityLevel

func (base *RsaPSS) SecurityLevel(signet tools.SignetInt) (int, error)

SecurityLevel implements the ToolLogic interface.

func (*RsaPSS) Sign

func (pss *RsaPSS) Sign(data, associatedData []byte, signet tools.SignetInt) ([]byte, error)

Sign implements the ToolLogic interface.

func (*RsaPSS) StoreKey

func (base *RsaPSS) StoreKey(signet tools.SignetInt) error

StoreKey implements the ToolLogic interface.

func (*RsaPSS) Verify

func (pss *RsaPSS) Verify(data, associatedData, signature []byte, signet tools.SignetInt) error

Verify implements the ToolLogic interface.

type SCRYPT

type SCRYPT struct {
	tools.ToolLogicBase
	// contains filtered or unexported fields
}

SCRYPT implements the cryptographic interface for SCRYPT password derivation.

func (*SCRYPT) DeriveKeyFromPassword

func (sc *SCRYPT) DeriveKeyFromPassword(password []byte, salt []byte) ([]byte, error)

DeriveKeyFromPassword implements the ToolLogic interface.

type Salsa20

type Salsa20 struct {
	tools.ToolLogicBase
	// contains filtered or unexported fields
}

Salsa20 implements the cryptographic interface for Salsa20 encryption.

func (*Salsa20) Decrypt

func (salsa *Salsa20) Decrypt(data []byte) ([]byte, error)

Decrypt implements the ToolLogic interface.

func (*Salsa20) Encrypt

func (salsa *Salsa20) Encrypt(data []byte) ([]byte, error)

Encrypt implements the ToolLogic interface.

func (*Salsa20) Reset

func (salsa *Salsa20) Reset() error

Reset implements the ToolLogic interface.

func (*Salsa20) Setup

func (salsa *Salsa20) Setup() (err error)

Setup implements the ToolLogic interface.

Jump to

Keyboard shortcuts

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