Avalanche ZkProof Precompile
A zkSNARK precompile implemented using gnark library
About
The problem it solves A zkSNARK precompile, addresses critical issues by enabling efficient, private, and secure transactions. It provides: 1. Privacy: zkSNARKs allow for confidential transactions, concealing both sender and receiver, enhancing user privacy. 2. Scalability: They reduce the computational load, improving Ethereum's scalability and lowering gas costs. 3. Auditability: zkSNARKs ensure data integrity while preserving the ability to verify transactions on the public ledger. 4. Secure Data Sharing: Users can selectively disclose transaction details, enhancing data sharing while maintaining confidentiality. 5. Regulatory Compliance: zkSNARKs offer a balance between privacy and transparency, facilitating compliance with evolving regulations.
How it's made
Challenges we ran into The biggest challenge we ran into was integrating the gnark circuit with the codebase had to eventually settle for a simplified zkproof method We also faced difficulty with the precompile-evm setup itself which was resolved using the github codespaces. Selection of the curves was also a difficult task as the math behind zkSNARK is difficult to understand completely even though it was an interesting read for us. Consensys conducted workshops on generating proofs using gnark which saved use a lot of time.