Legend:
Library
Module
Module type
Parameter
Class
Class type
Library
Module
Module type
Parameter
Class
Class type
Primitive used by this implementation. Currently "curve25519xsalsa20poly1305"
.
val random_keypair : unit -> keypair
random_keypair ()
generates a random key pair.
val random_nonce : unit -> nonce
random_nonce ()
generates a random nonce.
increment_nonce ?step n
interprets nonce n
as a big-endian number and returns the sum of n
and step
with wrap-around. The default step
is 1.
val wipe_key : 'a key -> unit
wipe_key k
overwrites k
with zeroes.
precompute sk pk
precomputes the channel key for the secret key sk
and the public key pk
, which can be used to speed up processing of any number of messages.
equal_public_keys a b
checks a
and b
for equality in constant time.
equal_secret_keys a b
checks a
and b
for equality in constant time.
equal_channel_keys a b
checks a
and b
for equality in constant time.
module type S = sig ... end