package octez-libs

  1. Overview
  2. Docs
type t = {
  1. cv : CV.t;
  2. epk : DH.epk;
  3. payload_enc : Bytes.t;
  4. nonce_enc : Tezos_crypto.Crypto_box.nonce;
  5. payload_out : Bytes.t;
  6. nonce_out : Tezos_crypto.Crypto_box.nonce;
}
val encoding : t Data_encoding.encoding
type plaintext = {
  1. diversifier : Viewing_key.diversifier;
  2. amount : int64;
  3. rcm : Rcm.t;
  4. memo : Bytes.t;
}
val plaintext_encoding : plaintext Data_encoding.encoding
val get_memo_size : t -> int
val decompose_plaintext_out : bytes -> R.pkd * R.esk
val encrypt : int64 -> Viewing_key.address -> Viewing_key.t -> Rcm.t -> Bytes.t -> (R.cv * R.commitment * R.epk) -> R.esk -> t
val encrypt_without_ovk : int64 -> Viewing_key.address -> Rcm.t -> Bytes.t -> R.esk -> CV.t -> t
val decrypt : t -> Viewing_key.t -> (Viewing_key.address * int64 * Rcm.t * Bytes.t) option
val decrypt_ovk : t -> R.ovk -> (R.commitment * R.epk) -> (Viewing_key.address * int64 * Rcm.t * Bytes.t) option
OCaml

Innovation. Community. Security.