chacha

package
v0.0.6 Latest Latest
Warning

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

Go to latest
Published: Dec 6, 2023 License: BSD-2-Clause Imports: 3 Imported by: 4

Documentation

Overview

Package chacha contains logic for encryption and decryption using the chacha20poly1305 encryption algorithm.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Decrypt

func Decrypt(key, data []byte) (plaintext []byte, err error)

Decrypt decrypts ciphertext data using using chacha20poly1305. This encryption algorithm is initialized by passing in the encryption key, which must be 256 bits.

func Encrypt

func Encrypt(key, data []byte, rng csprng.Source) (ciphertext []byte, error error)

Encrypt encrypts plaintext data using using chacha20poly1305. This encryption algorithm is initialized by passing in the encryption key, which must be 256 bits.

Types

This section is empty.

Jump to

Keyboard shortcuts

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