Skip to main content

Key Derivation Generator Overrides

All cryptographic keys are derived from the master seed via KMAC256 or Poseidon. Every derivation step is injectable. The following generator types appear as optional deps across the functions that use them.

Master Viewing Key Generators

Used by: registration, Stealth Pool Note creation (self-burnable and receiver-burnable), burning.

Poseidon Private Key Generators

Used by: registration, Stealth Pool Note creation, burning.

X25519 / Curve25519 Keypair Generators

Used by: registration, Stealth Pool Note creation. Also exposed via getMintEncryptionKeyRotatorFunction deps (in @umbra-privacy/sdk/account).

Viewing Key Generators (Poseidon sub-hierarchy)

Used by: Stealth Pool Note creation (the second viewing key scopes the note ciphertext).

Commitment Factor Generators

Ephemeral Stealth Pool Note key generators

Each note operation uses per-note ephemeral keys parameterised by the on-chain generation index. All are injectable. The TypeScript names retained their V13 spellings (EphemeralUtxo*) and the burn-side interfaces re-export them under V18 aliases:
Used by: all Stealth Pool Note creation and burner factories.

Cryptographic Operation Overrides

Beyond key generation, the low-level cryptographic operations themselves are injectable.

Rescue Cipher (RC) - Encryption and Decryption

The Rescue cipher is used to encrypt Stealth Pool Note payloads and EncryptedTokenAccount balances.
  • getRcEncryptor and getRcKeyGenerator appear in: registration, Stealth Pool Note creation deps.
  • rcDecryptor appears in: getEncryptedBalanceQuerierFunction deps — override to provide a custom decryption backend.

AES Encryption

AES-GCM is used for symmetric encryption of Stealth Pool Note commitment payloads.
Used by: Stealth Pool Note creator factories.

Poseidon Hash, Encryption, and Keystream

See Poseidon for the hash construction and security properties.
Used by: registration, Stealth Pool Note creation, burning.

Fiat-Shamir Challenge and Polynomial Evaluation

Used by: registration, Stealth Pool Note creation. Override to run evaluation in a Web Worker or swap in a WASM implementation.

User Commitment Generator

Used by: registration, Stealth Pool Note creation.