Versions in this module Expand all Collapse all v0 v0.1.0 Sep 22, 2023 Changes in this version + const Extension + var DefaultKDFParams = Params + var ErrUnauthenticated = errors.New("ciphertext verification failed") + func CiphertextLength(plaintextSize int) int + func NewBlobBuffer(size int) []byte + func NewRandomNonce() []byte + func NewSalt() ([]byte, error) + func PlaintextLength(ciphertextSize int) int + type EncryptionKey [32]byte + func (k *EncryptionKey) MarshalJSON() ([]byte, error) + func (k *EncryptionKey) UnmarshalJSON(data []byte) error + func (k *EncryptionKey) Valid() bool + type Key struct + func KDF(p Params, salt []byte, password string) (*Key, error) + func NewRandomKey() *Key + func (k *Key) NonceSize() int + func (k *Key) Open(dst, nonce, ciphertext, _ []byte) ([]byte, error) + func (k *Key) Overhead() int + func (k *Key) Seal(dst, nonce, plaintext, additionalData []byte) []byte + func (k *Key) Valid() bool + type MACKey struct + K [16]byte + R [16]byte + func (m *MACKey) MarshalJSON() ([]byte, error) + func (m *MACKey) UnmarshalJSON(data []byte) error + func (m *MACKey) Valid() bool + type Params struct + N int + P int + R int + func Calibrate(timeout time.Duration, memory int) (Params, error)