Module Box.Public_key

Public keys.

Use keypair to generate one.

type t

The type for public keys.

val length : int

length is the byte length of public keys.

val equal : t -> t -> bool

equal pk pk' determines in constant time if pk and pk' are bytewise equal.

val of_bytes : Bytes.t -> t

of_bytes b is a public key from bytes b. Raises Invalid_argument if b's length differs from length.

val to_bytes : t -> Bytes.t

to_bytes pk are the bytes of pk.

val pp : Stdlib.Format.formatter -> t -> unit

pp ppf pk is an unspecified formatter for public keys.