User Flow Overview
The platform caters to two primary user roles, each with a streamlined, encrypted interaction path designed for maximum security.
Privacy-preserving sealed-bid auction platform, built on Zama's FHEVM v0.9. Truly confidential bidding where bid amounts remain encrypted throughout the lifecycle.
Bid amounts are encrypted client-side and never revealed during calculation.
Cryptographic proofs ensure the winner is valid without leaking amounts.
Native support for ERC-721 and ERC-1155 collectible targets.
Real-time state tracking powered by decentralized subgraphs.
The platform caters to two primary user roles, each with a streamlined, encrypted interaction path designed for maximum security.
Initial validation
Bidding window open
Homomorphic calculation
Winner declared
Computation succeeded on-chain without any party (including validators) seeing the actual values.
Next.js / React / MetaMask
Wagmi + Ethers.js / Viem
Zama Relayer SDK (TFHE-rs)
Solidity + FHEVM Protocol
Sepolia Testnet / Zama L1
No validator can view the bid amounts. Only the KMS can decrypt results based on threshold signatures.
All computations are deterministic and verified on-chain. Decryption proofs must be submitted by the reveal agent.
Zama FHEVM v0.9 powers a suit of privacy features that shield auction mechanics from prying eyes.
| Privacy Component | Benefit |
|---|---|
| Encrypted Bids | Bid amounts hidden until auction ends |
| Encrypted Winner | Winner identity hidden during active phase |
| Private Reserve | Minimum price hidden from bidders to prevent strategic gaming |
| Hidden Bidder Count | Total participation volume obscured during live bidding |
| Self-Relaying Decryption | Oracle-free verifiable decryption via v0.9 |
We use FHE.allow() to ensure only the authorized contract and the bidder can interact with the encrypted data.
// Grant access permissions
FHE.allowThis(bidAmount); // Contract can use this value
FHE.allow(bidAmount, msg.sender); // Bidder can decrypt their own bid
// Compare without revealing
ebool isGreater = FHE.gt(currentBid, maxBid);
maxBid = FHE.select(isGreater, currentBid, maxBid);Comprehensive coverage across factory deployment, FHE operations, and edge cases.
# Run full protocol suite
npx hardhat test
# Scalability Verification
npx hardhat test test/Scalability.test.tsAutomated notifications via Resend for seamless participant engagement.
Alerts seller to reveal winner.
Step-by-step NFT claim instructions.
Refund status and result summary.
POST /api/send-notification
{
"to": "recipient@example.com",
"type": "winner_announced",
"data": { "auctionTitle": "Rare Artifact", "winningBid": "5.5 ETH" }
}| Method | Params | Type |
|---|---|---|
| placeBid() | euint32, bytes proof | External |
| revealWinner() | uint32, bytes proof | Public |
git clone https://github.com/fhe-auction/protocol.git
npm install
npx hardhat node --network fhevm
# Configure Environment
RESEND_API_KEY=re_xxx
SEPOLIA_RPC=xxxUse MetaMask or any Web3 wallet. Ensure you are on the Sepolia Testnet (Chain ID: 11155111).
Input your bid. The Zama SDK will immediately salt and encrypt this value locally.
A public escrow (>= bid) is required to guarantee final settlement. This is fully refundable.
Confirm the transaction. Your bid is transmitted as an opaque handle to the EVM.
Your escrow is held by the smart contract's immutable logic. If you do not win the auction, your funds are automatically available for claim immediately after the reveal phase.