package pkcs11

  1. Overview
  2. Docs

Big integers used in PKCS#11.

PKCS#11 expects them to be encoded in big-endian, so manipulating the underlying representation is error-prone.

type t
val equal : t -> t -> Ppx_deriving_runtime.bool
val compare : t -> t -> Ppx_deriving_runtime.int
val pp : Ppx_deriving_runtime.Format.formatter -> t -> Ppx_deriving_runtime.unit
val to_yojson : t -> Yojson.Safe.t
val encode : t -> string

Convert to/from a big-endian byte array.

val decode : string -> t
val to_int : t -> int
val of_int : int -> t
val to_string : t -> string
val zero : t
val of_z : Z.t -> t
val to_z : t -> Z.t
OCaml

Innovation. Community. Security.