Technical Details

Proof Generation and Verification

The ZK coprocessor generates and verifies proofs through several key components:

Proof Data Generation

The get_proof_data functionality is central to the protocol's cross-chain operations:

  1. Guest Program

    • Executes inside the RISC Zero zkVM

    • Verifies cross-chain state through zero-knowledge proofs

    • Validates user positions and market states across chains

    • Generates cryptographic proofs of state verification

    • Handles view calls to market contracts for state verification

Chain-Specific Verification

​Each supported chain has specialized verification mechanisms:

  1. Ethereum (L1)

    • Light client verification through beacon chain

    • Proof state via OPstack L1 reads

  2. Optimism/Base (OpStack)

    • Sequencer commitment verification

    • Dispute game validation

    • L1 block inclusion proofs

  3. Linea

    • Sequencer commitment verification

    • L1 block inclusion proofs

Self-Sequencing

​While the Sequencer Infrastructure handles proof generation and submission for most users, the protocol maintains censorship resistance through self-sequencing capabilities. Users can generate and submit their own proofs if:

  • The Sequencer is unavailable

  • The Sequencer attempts to censor transactions

  • Users prefer to handle their own proof generation

  • Additional security guarantees are required

Self-Sequencing Guide​To generate proofs independently:

  1. Setup

  1. Environment Configuration Create a .env file with required RPC endpoints:

  1. Proof Generation Use the Malda SDK to generate proofs:

  1. Transaction Preparation Extract the required data for on-chain submission:

Note: For self-sequencing, l1_inclusion must be set to true to ensure additional security guarantees against potential reorg exploits.

Last updated