Unizwap

Privacy-preserving Uniswap v4 hook with ZK-proof swaps, liquidity provision & withdrawals

HackMoney 2026Shipped January 30, 2026 Shipping#defi#privacy#zk#security#depin
Visit Repo
Unizwap banner

About

Unizwap is a privacy-preserving decentralized exchange protocol that brings zero-knowledge privacy to Uniswap V4 through its hooks architecture. Unlike traditional privacy DEXes that require separate liquidity pools or off-chain sequencers, Unizwap extends Uniswap V4's existing infrastructure to enable private swaps, private liquidity provision, and cross-wallet withdrawals—all while maintaining full trustless execution on Ethereum L1.

The Problem:

Current DEXes expose complete trading activity: wallet addresses, swap amounts, liquidity positions, and transaction history are all publicly visible. This creates serious privacy concerns—MEV bots exploit this transparency to frontrun trades, competitors analyze trading strategies, and users have zero protection from address-based surveillance. Existing privacy solutions either fragment liquidity into separate shielded pools, rely on trusted hardware (TEEs), or require centralized sequencers.

Our Solution:

Unizwap leverages Uniswap V4's hook system to implement commitment-based privacy at the protocol level. When users swap or provide liquidity, output tokens and positions are stored by cryptographic commitments (Poseidon hashes of secret values) rather than wallet addresses. These commitments are inserted into a Merkle tree, creating an anonymity set. To withdraw funds or remove liquidity, users generate zero-knowledge proofs (using Circom circuits and Groth16) that prove ownership of a commitment without revealing their secret or linking transactions. Crucially, withdrawals can be made from completely different wallet addresses, breaking on-chain linkability.

Technical Architecture:

Our implementation consists of three main components:

UnizwapHook Contract: Implements Uniswap V4 hook permissions (beforeSwap, afterSwap, beforeAddLiquidity, beforeRemoveLiquidity) to intercept operations and manage privacy. The hook captures swap outputs, stores them by commitment, and requires ZK proof verification for withdrawals.

ZK Circuits: Two Circom circuits verify commitment ownership—one for swap withdrawals and one for liquidity removal. Each circuit enforces Merkle inclusion proofs, nullifier checks (preventing double-spending), and commitment validation. Public signals include only the Merkle root, nullifier, and withdrawal parameters—no wallet addresses or secrets are revealed.

Merkle Tree with History: A 10-level Poseidon Merkle tree stores commitments with multiple root history, allowing proofs to remain valid even as new commitments are added. This prevents race conditions and maintains a robust anonymity set.

Key Innovations:

Hook-Native Privacy: First privacy solution built directly into Uniswap V4 hooks, not a separate protocol No Liquidity Fragmentation: Uses existing Uniswap V4 pools—no need for separate privacy pools Zero Trust: Pure smart contracts + ZK proofs—no TEEs, sequencers, or relayers required Cross-Wallet Withdrawals: Prove ownership from any wallet, completely breaking address linkability Router Pattern: Direct execution without pre-deposits, simplified UX compared to vault-based systems Current Status: Unizwap is fully deployed and operational on Sepolia testnet with verified contracts and real transaction evidence:

Hook Contract: 0x33a0529f481140fdc2d14a47d2ce8f2b9d1e4ac4 Complete transaction flow: Pool creation → Add liquidity → Private swap → ZK withdrawal → LP removal All operations verified on-chain with working frontend at unizwap-ktkl.vercel.app Gas costs optimized: ~250-280K gas for ZK proof verification Privacy Guarantees: What's hidden: Swap output destinations, LP position ownership, withdrawal recipients, position linkability What remains public: Input wallet addresses (router pattern), token amounts, pool activity, timing Protected against: MEV exploitation, address surveillance, trading strategy analysis, portfolio tracking This represents a practical privacy model—not perfect anonymity, but significant protection against the most common threats while maintaining on-chain transparency for regulatory compliance.

Future Roadmap:

We're developing cross-chain privacy bridges, intent-based private swaps with solver networks, private limit orders with ZK-revealed execution, and scalable Merkle trees with dynamic expansion. Our goal is to make privacy the default for DeFi operations while maintaining full compatibility with Uniswap V4's ecosystem.

Unizwap demonstrates that meaningful DEX privacy is achievable today on Ethereum L1 without sacrificing trustlessness, liquidity, or user experience—paving the way for privacy-preserving DeFi at scale.

From the public ETHGlobal showcase page. Votes, swipes and the judge score are hackfeed's own.

AI judge

Not judged yet. A free model reads this page, compares it with similar projects and this event's winners, then scores it and says what would make it win.

Still being built?

ShippingLast push 25 days ago

Swipe stats

0upvotes
0skips
0saves

Discussion 0

No comments yet. Ask the team something, or say what you'd use it for.

Posting as a guest. Plain text, 1,000 characters max.

Already built nearby

Closest projects by meaning and shared words. Similar isn't the same as copied: read them.

GrimSwap

Privacy DEX on Uniswap v4 — ZK-SNARK proofs + stealth addresses break the sender-receiver link.

HackMoney 2026Prize winner Dormant#defi#privacy

Confidential Hook

ZK-powered hook that enable confidential trading with compliance, policy, and strategy verification