HpkeContext class final
An HPKE encryption context (RFC 9180 §5.2).
seal and open are ordered. Sequence n on the sender matches
sequence n on the recipient. A failed open does not advance the
sequence. export does not use the sequence.
dispose is best-effort zeroization of the context secrets. It is not a claim that the keys have left process memory.
Properties
Methods
-
dispose(
) → void - Best-effort wipe of the key, base nonce, and exporter secret.
-
export(
Uint8List exporterContext, int length) → Uint8List -
RFC 9180
Context.Export.lengthis1 .. 255 * Nh. -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
open(
Uint8List ciphertext, {Uint8List? aad}) → Uint8List -
Decrypts
ciphertext(ciphertext || tag). -
seal(
Uint8List plaintext, {Uint8List? aad}) → Uint8List -
Encrypts
plaintext. Returnsciphertext || tag. -
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited