Skip to content

ZK-011: Add explicit domain separation tags to note commitments #255

@ANAVHEOBA

Description

@ANAVHEOBA

Wave: PrivacyLayer ZK Wave 1
Issue Key: ZK-011
Area: commitment
Priority: High
Drips Complexity: High

Summary

Commitments should be domain-separated from Merkle node hashes and nullifier hashes so the protocol does not rely on positional conventions alone.

Relevant Code

  • circuits/lib/src/hash/commitment.nr
  • circuits/lib/src/hash/nullifier.nr
  • circuits/lib/src/hash/pair.nr
  • circuits/commitment/src/main.nr
  • sdk/src/note.ts

Scope

  • Define a domain-separation scheme for note commitments inside the hash input layout.
  • Update the Noir hash helper and SDK commitment path together.
  • Add regression tests that prove commitment, nullifier, and Merkle hashing occupy distinct domains.

Acceptance Criteria

  • Commitment hashing uses an explicit domain-separated preimage format.
  • Cross-stack fixtures are updated to the new encoding.
  • Regression tests catch accidental reuse of the old hash domain.

Out of Scope

  • Soroban contract changes
  • Frontend and wallet UI work

Dependencies

  • ZK-001
  • ZK-009

References

  • circuits/lib/src/hash/commitment.nr
  • circuits/lib/src/hash/nullifier.nr
  • circuits/lib/src/hash/pair.nr
  • circuits/commitment/src/main.nr
  • sdk/src/note.ts

Metadata

Metadata

Assignees

Labels

area: commitmentCommitment, note, and hash design workbountyEligible for Drips Wave bounty reviewcircuitsNoir circuit and proving workcomplexity: highDrips complexity: high / 200 pointspriority: highCritical path work for the current wavewave: zk-1Wave 1: ZK system buildout before contract work

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions