package hpke

  1. Overview
  2. Docs

Module Hpke.Public_keySource

Sourcetype t

A validated public key tagged with its KEM.

Sourceval of_bytes : kem:Kem.id -> string -> (t, Error.t) result

Parse an exact-length canonical encoding. NIST keys must use uncompressed SEC1 form. X25519 low-order rejection occurs when the key is used.

Sourceval to_bytes : t -> string
Sourceval kem : t -> Kem.id