package awa

  1. Overview
  2. Docs
type t =
  1. | Plaintext
  2. | Aes128_ctr
  3. | Aes192_ctr
  4. | Aes256_ctr
  5. | Aes128_cbc
  6. | Aes192_cbc
  7. | Aes256_cbc
  8. | Chacha20_poly1305
val aead : t -> bool
type key = {
  1. cipher : t;
  2. cipher_key : cipher_key;
}
val to_string : t -> string
val of_string : string -> (t, string) result
val key_len : t -> int
val iv_len : t -> int
val block_len : t -> int
val mac_len : t -> int
val known : string -> bool
val enc_dec : bool -> len:bool -> int32 -> key -> Cstruct.t -> (Cstruct.t * key, string) result
val encrypt : len:bool -> int32 -> key -> Cstruct.t -> Cstruct.t * key
val decrypt : len:bool -> int32 -> key -> Cstruct.t -> (Cstruct.t * key, string) result
val preferred : t list
OCaml

Innovation. Community. Security.