package octez-libs

  1. Overview
  2. Docs
A package that contains multiple base libraries used by the Octez suite

Install

Dune Dependency

Authors

Maintainers

Sources

tezos-18.1.tar.gz
sha256=aa2f5bc99cc4ca2217c52a1af2a2cdfd3b383208cb859ca2e79ca0903396ca1d
sha512=d68bb3eb615e3dcccc845fddfc9901c95b3c6dc8e105e39522ce97637b1308a7fa7aa1d271351d5933febd7476b2819e1694f31198f1f0919681f1f9cc97cb3a

doc/octez-libs.crypto/Tezos_crypto/Crypto_box/Secretbox/index.html

Module Crypto_box.SecretboxSource

Sourcetype key
Sourceval unsafe_of_bytes : Bytes.t -> key
Sourceval secretbox : key -> Bytes.t -> nonce -> Bytes.t

secretbox key msg nonce encrypts and authenticates the data in msg using key and nonce and returns the authentication tag and the ciphertext in one buffer. For this reason, the returned buffer will be tag_length longer than msg.

Sourceval secretbox_open : key -> Bytes.t -> nonce -> Bytes.t option

secretbox_open key cmsg nonce verifies and decrypts cmsg using key and nonce and returns the plaintext if successful. As above, the returned buffer will be tag_length shorter than cmsg.

OCaml

Innovation. Community. Security.