#transaction #notes #phoenix #model #privacy-preserving #gadget #merkle-tree #sender #nullifier #dusk

phoenix-circuits

Circuit definitions for Phoenix, a privacy-preserving ZKP-based transaction model

13 releases (5 breaking)

0.6.0 Feb 7, 2025
0.5.0 Dec 18, 2024
0.4.0 Aug 14, 2024
0.3.0 Aug 14, 2024
0.1.0 May 22, 2024

#6 in #dusk

Download history 136/week @ 2025-03-24 53/week @ 2025-03-31 99/week @ 2025-04-07 93/week @ 2025-04-14 103/week @ 2025-04-21 87/week @ 2025-04-28 59/week @ 2025-05-05 59/week @ 2025-05-12 59/week @ 2025-05-19 104/week @ 2025-05-26 45/week @ 2025-06-02 47/week @ 2025-06-09 100/week @ 2025-06-16 79/week @ 2025-06-23 42/week @ 2025-06-30 63/week @ 2025-07-07

287 downloads per month
Used in 13 crates (via dusk-core)

MPL-2.0 license

100KB
2K SLoC

Phoenix Circuits

Phoenix is the transaction model used by Dusk, an open-source public blockchain with a UTXO-based architecture that allows for the execution of obfuscated transactions and confidential smart contracts.

This library contains the implementation of the Phoenix-circuits, to prove, in zero-knowledge, that the following conditions hold true:

  1. Membership: every note that is about to be spent is included in the Merkle tree of notes.
  2. Ownership: the sender holds the note secret key for every note that is about to be spent.
  3. Nullification: the nullifier is calculated correctly.
  4. Minting: the value commitment for the newly minted notes are computed correctly.
  5. Balance integrity: the sum of the values of all spent notes is equal to the sum of the values of all minted notes + the gas fee + a deposit, where a deposit refers to funds being transfered to a contract.

Dependencies

~6.5MB
~139K SLoC