Module sodium

Module sodium 

Source
Expand description

Crypto module provides cryptographic interfaces and implementations for DSF

Constants§

SK_META

Functions§

hash
Hash performs a hash function over the provided slice
new_pk
new_pk creates a new public/private key pair
new_sk
new_sk creates a new secret key for symmetric encryption and decryption
pk_sign
pk_sign generates a signature for the provided slice of data
pk_validate
pk_validate checks a provided signature against a public key and slice of data
sk_decrypt
sk_decrypt2
sk_decrypt2 decrypts the data in-place in the provided buffer, this will strip NONCE and TAG information, and returns the data length (decrypted data w/out overheads)
sk_encrypt
sk_encrypt2
sk_encrypt2 encrypts data_len bytes of the data in-place in the provided buffer, appends NONCE and TAG information to the buffer, and returns the complete length (encrypted data + overheads)