Axiom V2 Docs Old
  • Introduction
    • What is Axiom?
    • Quickstart
  • Examples
    • Autonomous Airdrop
      • AxiomREPL Code
      • Contract
      • Web App
      • DataQuery-only Version
  • Developers
    • Axiom for Developers
    • Specifying a Query into Axiom
    • AxiomREPL
      • AxiomREPL Examples
    • Exporting a Client Side Prover
    • Handling Axiom Callbacks
    • Common Issues
      • Callback Debugging
  • SDK and REPL Reference
    • Axiom SDK Reference
      • QueryBuilderV2
      • Data Subqueries
        • Header Subquery
        • Account Subquery
        • Storage Subquery
        • Transaction Subquery
        • Receipt Subquery
        • Solidity Nested Mapping Subquery
    • AxiomREPL Reference
      • Circuit Types
      • Circuit Functions
      • Data Functions
      • Compute Functions
  • Protocol Design
    • Architecture Overview
    • Caching Block Hashes
    • Axiom Query Protocol
      • Axiom Query Format
    • ZK Circuits for Axiom Queries
    • Ethereum On-chain Data
    • Guardrails
  • Transparency and Security
    • KZG Trusted Setup
    • Contract Addresses
    • On-chain ZK Verifiers
    • Security
  • Zero Knowledge Proofs
    • Introduction to ZK
    • ZK Examples
    • Getting Started with halo2
    • halo2-repl
  • Additional Resources
    • Axiom V2 Explorer
    • Github
    • Website
    • Telegram
    • Discord
    • Axiom V1 Docs
Powered by GitBook
On this page
  1. Transparency and Security

On-chain ZK Verifiers

How Axiom verifies ZK proofs on-chain.

PreviousContract AddressesNextSecurity

Last updated 1 year ago

To verify ZK proofs on-chain, Axiom uses specialized smart contracts which are programmatically generated for each SNARK. This was done with the library developed by the group at the Ethereum Foundation, which generates Solidity assembly code for verifying any given ZK circuit.

Deployed Verifier Contracts

We deployed the verifier contracts to Goerli from Solidity source code using solc Version: 0.8.19. The Solidity assembly code for each contract can be inspected on Etherscan.

We will soon be open-sourcing the Rust code used to programmatically generate the Solidity code above.

Checking Verifiers are not Metamorphic

In AxiomV2CoreMockHistoricaland AxiomV2Query, each of these verifiers is subject to a timelock upgrade guarantee. To ensure that this timelock guarantee cannot be bypassed by a , users should verify on each upgrade that the bytecode for verifier contracts above does not contain DELEGATECALL or SELFDESTRUCT opcodes. This can be done either by searching the Solidity assembly code or analyzing the compiled bytecode itself. Thanks to Zellic for pointing out this concern.

snark-verifier
Privacy Scaling Explorations
metamorphic contract attack
AxiomV2CoreGoerliVerifier
AxiomV2QueryVerifier