Social Media

Privacy-Preserving Payment Layer using Zero-Knowledge Proofs & Rust

Project Snapshot

    • 🔹Client: Confidential (DeFi Infrastructure Provider targeting APAC + EU region)
    • 🔹Industry: Decentralized Finance (DeFi), Privacy Infrastructure
    • 🔹Duration: 10 Months
    • 🔹Team: 8 Rust + ZK Engineers, 2 Cryptographers, 1 Ethereum Architect

    🔹Environment: Ethereum Layer 1 & Testnets (Goerli, Sepolia), Rust-native zkStack

Objectives

  • 🔹To build a modular, privacy-preserving payment layer that operates on top of Ethereum or other L1 chains—allowing users to send, receive, and mix funds without leaking metadata or transaction history.

    🔹Inspired by Tornado Cash, Zether, and Aztec, the goal was to implement a regulatory-aware, off-chain privacy layer using Zero-Knowledge Proofs, without compromising composability or performance.

Solution

      • TechSteck Solutions architected a Rust-powered zk-based mixer and shielded payment system capable of supporting arbitrary ERC-20 and ETH deposits, with off-chain proof generation and a zk-SNARK-based L1 bridge for trustless withdrawals.

        Core Technologies Used

        • 🔹Rust – Backend microservices, prover services, SNARK coordination layer
        • 🔹arkworks-rs – Circuit design and cryptographic primitives
        • 🔹bulletproofs – For confidential range proofs and commitment schemes
        • 🔹circom-rs – Native Circom circuit compiler with WASM backends
        • 🔹Poseidon Hash / MiMC – ZK-friendly hashing for note commitment & Merkle proofs
        • 🔹Solidity – Smart contracts for deposit, withdrawal, and Merkle tree root management
        •  
        • Key Features & Architecture

        •  

          1. Shielded Transactions

          • 🔹Users generate shielded notes off-chain using a Rust client, each representing a fixed denomination.
          • Each note includes:
            • 🔹Commitment: Poseidon(Msg + blinding)
            • 🔹Nullifier: Prevents double-spending
            • 🔹Serial Number: Revealed only on withdrawal for verification

          2. Off-chain ZK Proof Generation

          • 🔹ZK circuits compiled via circom-rs and proven via snarkjs/groth16 or Bulletproofs.
          • 🔹Rust orchestrator handles:
            • 🔹Input signal generation
            • 🔹Merkle proof path computation
            • 🔹Proof verification before submission to L1
          • 🔹Designed for light-client compatibility via WebAssembly

          3. Ethereum L1 Bridge (zk-SNARKs)

          • Solidity smart contract:
            • 🔹Validates incoming zk-proofs (Groth16)
            • 🔹Manages the Merkle tree root history
            • 🔹Allows trustless withdrawals only if the proof is valid & nullifier unused

          Additional Security Features

          • 🔹Anti-frontrunning: Used a commit-reveal scheme to prevent withdrawal sniping
          • 🔹Trusted Setup Ceremony: Phase 1 MPC coordinated using powers-of-tau in-browser
          • 🔹Circuit Size Optimizations: Reduced constraint count by 30% using elliptic-friendly hashes and fixed-denomination optimizations

Results & Impact

 

Metric

Impact

On-chain Footprint

Reduced calldata size by ~70% via off-chain proof generation

Anonymity Set Growth

Grew to 12,000+ shielded notes in first 4 months

Withdrawal Latency

<15s (including proof gen and submission)

Regulatory Controls

Designed optional compliance hooks for blacklisting UTXOs/nullifiers

Gas Cost for Withdrawals

Averaged 190k gas per Groth16 verified tx

Lessons Learned

  • 🔹ZK Circuits Are Fragile: Minor changes to note structure or hashing drastically impact proof size and performance.
  • 🔹Rust + ZK is Powerful but Demands Rigor: Using Rust’s strong type system and arkworks helped avoid low-level cryptographic errors, but required expert familiarity.
      • 🔹Composability Tradeoffs Exist: Full privacy often comes at the cost of reduced L1 composability. Selective transparency can help.
      • 🔹User Experience Matters: Integrated browser-based proof generators for accessibility.

Conclusion

      • TechSteck Solutions successfully delivered a scalable, zk-powered privacy layer for Ethereum that empowers users with financial privacy while aligning with regulatory realities. The client now offers this privacy layer as a white-labeled SDK to fintech and wallet partners in Europe and Asia.

        This project sets a foundation for privacy-enhancing DeFi—without needing a new chain or exotic consensus models.

GET STARTED

If you would like to work with us or just want to get in touch, we’d love to hear from you!