@iden3/circuits
v0.0.1
Published
iden3 circuits
Downloads
11
Keywords
Readme
circuits
Circuits used by the iden3 core protocol.
Warning: This repository is in a very early stage.
The circuits of this repository are compatible with the go-iden3-core implementation
Circuits:
- Identity Ownership: circuit used to verify that the prover is the owner of the Identity
- Identity Ownership Genesis: wrapper on top of idOwnership.circom to check the ownership only for a Genesis Id state
- Identity State Update: circuit used to verify validity when updating an Identity State
- BuildClaimKeyBBJJ: circuit used build ClaimKeyBabyJubJub
- BuildClaimBasicAboutId: circuit used build ClaimBasic about a specific Id
- Credential: circuit used to verify a Credential. This means that the prover is the owner of the identity, and the identity is inside a claim with Subject OtherIden, and that claim is inside the MerkleTree of the Issuer identity, and the claim is not revoked.
Examples of circuits usage:
- Identity State Update: Identity state update circuit with genesis proofs of at most 4 levels.
- Credential Demo Wrapper: Credential demo circuit that proves ownership of a claim of type ClaimOtherIden (with some values set to 0 for simplicity).
Building and trusted setup
First install the npm dependencies:
npm ci
Then build the circuit and do the "trusted" setup:
./compile-circuit.sh CIRCUIT_PATH
Examples:
./compile-circuit.sh circuits/examples/idState.circom
./compile-circuit.sh circuits/examples/credentialDemoWrapper.circom