project screenshot 1
project screenshot 2
project screenshot 3
project screenshot 4

NoxFi

NoxFi, an innovative on-chain private double auction DEX, uses ZKP to enable private, large-scale trades with zero market impact. Unlike existing DEXs, NoxFi minimizes slippage, prevents front-running, and is ideal for low liquidity pools and institutional investors.

NoxFi

Created At

ETHGlobal Paris

Winner of

trophy

🔀 Polygon — Best use of zkEVM

trophy

🛠️ Chainlink — Awesome Project

Project Description

NoxFi is a pioneering on-chain private double auction platform, leveraging Zero-Knowledge Proofs (ZKP). It offers users the privilege of conducting their transactions with utmost privacy and negligible market impact.

Existing Decentralized Exchanges (DEXs) often grapple with significant market impact when they're faced with large-scale orders that surpass their liquidity. This prompts whales and institutional investors to migrate their assets to Centralized Exchanges (CEXs) when they're contemplating large-scale trades, taking risk of "Whale alerts".

NoxFi, a novel breed of DEX, is designed to proficiently manage large orders, thereby complementing the current range of DEXs. Inspired by "dark pool" in traditional financial markets, NoxFi operates a private double auction which aids institutional investors in large-scale trading. The auction process in NoxFi is bifurcated into two phases.

The first is the open auction phase, where traders submit the ZKP of their balance along with their encrypted orders. During this stage, orders are accumulated but not processed. Once the auction concludes, the secret sharing Multiparty Computation (MPC) servers anonymously compare the orders to ascertain a single settlement price. This ensures all corresponding orders are settled instantly at this unified price, with zero spread.

NoxFi delivers several notable advantages to the ecosystem. It serves as a dark pool for institutional investors, similar to traditional markets, thereby drawing in large scale orders previously handled exclusively by CEXs. Furthermore, token pairs with lower liquidity pools can leverage NoxFi to minimize their slippage. Moreover, NoxFi effectively neutralizes the advantage of any front-runners prevalent in current DEXs, as they can't extract any pre-trade information from public transactions.

In essence, NoxFi is reshaping the landscape of decentralized exchanges by offering a more secure, efficient, and confidential trading platform.

How it's Made

On the web side, we began the project using the React, with vite bundler. For the connection with blockchain, we adopted Viem and Wagmi.sh libraries as core. using this, created a contract instance to call the contract mutate function and read data. The function to get ETH/DAI price from Chainlink was implemented through Viem, and the communicating with NoxFi Contract was handled using both Viem and Wagmi. For styling, we used Emotion styled components, Tailwind CSS with Twin.macro, also we developed components using Storybook. As a substitute for a database, we used browser local storage. We enforced consistent code style using Lint and Prettier and managed Git branch conflicts by allowing only rebase and pull request merge.

On the contract side, we deployed our contract on the Polygon ZK EVM testnet. We implemented a setup for the ZK circuit using Circom and Groth-16 from snark.js. The proving key was locally utilized by the web client, while the verifying key was deployed as a contract. Our system consists of five verifier contracts - Deposit, Withdraw, Order, Settle, and Cancel - all managed by one main contract. All actions within our service are secured, ensuring every public transaction remains private without exposing sensitive information.

background image mobile

Join the mailing list

Get the latest news and updates