Sukura is a privacy-preserving transaction mixer built on Solana. It enables users to deposit and withdraw funds anonymously by leveraging zk-proofs.
- Privacy-Preserving Transactions – Uses ZKPs to ensure transactions remain confidential.
- Solana Smart Contracts – Efficient, low-cost on-chain interactions.
- Relayer Support – Withdraw funds without linking addresses.
- Web3 Integration – Works with wallets like Phantom and Solflare.
- Fast & Scalable – Built on Solana for high-speed transactions.
- Solana – Blockchain infrastructure
- Anchor – Solana smart contract framework
- Next.js – Frontend & API routes
- MongoDB – Stores Merkle tree data off-chain
- Mongoose – ODM for MongoDB
- Shyft API – Transaction relayer
- Circom – Used for writing ZK circuit.
git clone https://github.com/truthixify/sukura.git
cd sukura
npm install
Create a .env.local file and configure it:
MONGODB_URI=<your_mongodb_connection_string>
API_KEY=<your_shyft_api_key>
NETWORK_URL=<solana_rpc_url>
NETWORK_URL=devnet # or mainnet
NODE_ENV=development # or production
npm run dev
Your Next.js app should now be running at http://localhost:3000
- User Generates a Commitment
- During deposit, a random secret is generated.
- The Poseidon hash function is used to create a commitment hash.
- Commitment is Stored On-Chain
- The commitment is submitted to the Solana smart contract.
- The commitment is also stored off-chain in a Merkle tree (MongoDB).
- User Downloads a Note
- After a successful deposit, the user downloads a “Note”.
- The note contains the secret key and nullifier needed for withdrawal.
Deposit Parameters:
{
commitment: string // Unique commitment hash
}
- User Uploads Their Note
- To withdraw, the user must upload the Note downloaded during deposit.
- This note contains the secret key used to prove ownership.
- Zero-Knowledge Proof is Generated
- A ZK proof is created to verify the deposit without revealing its details.
- The proof is submitted to the smart contract along with the Merkle root.
- Relayer Facilitates the Transaction
- A relayer submits the withdrawal transaction on behalf of the user.
- The withdrawal amount is sent to the recipient address without linking it to the original deposit.
Withdrawal Parameters:
{
nullifierHash: string // Prevents double spending
root: string // Current Merkle tree root
proof: Proof // Zero-knowledge proof
publicSignals: PublicSignals // Public inputs for verification
fee: BN // Transaction fee
recipientAddress: PublicKey // Address receiving the funds
relayerWallet: PublicKey // Relayer handling the transaction
vaultAddress: PublicKey // Vault holding the funds
}
- Fork the repo
- Create a new branch (
git checkout -b feature/new-feature
) - Commit your changes (
git commit -m 'Add new feature'
) - Push the branch (
git push origin feature/new-feature
) - Open a pull request
MIT License © 2025 Sukura Team
- Twitter: @truthixify
- Email: [email protected]