Cryptographic proof that your exchange is solvent. Privacy-preserving. On-chain verified. Trustless.
Quick Links:
- π Live Backend API - Health check responding
- π Registry Contract on Etherscan - Verified proofs on-chain
- π Verifier Contract on Etherscan - Groth16 ZK verifier
- π» Frontend App - React dashboard with real-time verification
- π API Documentation - Complete endpoint reference
| Feature | Traditional Audit | SolvencyProof | Benefit |
|---|---|---|---|
| Privacy | Exposes all balances | Zero-knowledge proofs | Users stay private |
| Frequency | Quarterly/Annual | Real-time, on-demand | Always current |
| Trust | Trust the auditor | Cryptographic verification | Trustless |
| Verification | PDF reports | On-chain, anyone can verify | Transparent |
| Cost | $100K+ per audit | Gas fees only | 1000x cheaper |
- β
SolvencyProofRegistry Contract on Sepolia:
0x7a9f15BCD95FDD20cf31A480f37CAA9b708aB33d - β
Groth16Verifier Contract on Sepolia:
0x5e22F8cB0CfbC0df5F2251009674E1266E1D2DD6 - β Backend API on Railway: Live Health Check - All 21 endpoints operational
- β Frontend Dashboard with React + TailwindCSS: Complete verification portal
- β Circom ZK Circuits: Groth16 solvency proof generation (solvency.circom)
- β Yellow Network State Channels: Off-chain balance management with instant updates
- β Merkle Tree Commitments: Privacy-preserving liability aggregation
- β On-chain Verification: Smart contract validates ZK proofs cryptographically
- β Privacy-Preserving Solvency: Prove reserves > liabilities WITHOUT revealing individual balances
- β User Inclusion Proofs: Any user can verify their balance is included (Merkle proof)
- β Real-time State Channels: Update liabilities instantly via Yellow Network (zero gas)
- β Epoch-Based History: Full audit trail of all verified proofs on-chain
- β 21 API endpoints fully functional
- β ZK circuit compiled and tested
- β Smart contracts deployed and verified
- β Frontend with authentication, caching, and real-time updates
- β Comprehensive test suite
After FTX, Celsius, and countless exchange collapses, users have ONE question:
- $20B+ lost in exchange collapses (FTX alone: $8B)
- No real-time verification - monthly "attestations" are meaningless
- Privacy violations - traditional audits expose user data
- Costly and slow - $100K+ and months for each audit
- Trust-based - "just believe us" doesn't work anymore
| Approach | Problem |
|---|---|
| Merkle Trees only | Doesn't prove reserves exist |
| PoR attestations | Point-in-time, easily manipulated |
| Full transparency | Exposes competitive data & user privacy |
| Third-party audits | Slow, expensive, trust the auditor |
SolvencyProof combines three cryptographic primitives into a complete solution:
1. LIABILITIES (Merkle Tree)
βββ Commit to ALL user balances with single hash
βββ Users can verify inclusion privately
βββ Total is hidden but provable
2. RESERVES (On-chain Scan)
βββ Real ETH balances from blockchain
βββ Publicly verifiable addresses
βββ No trust required
3. ZK PROOF (Groth16)
βββ Proves: reserves >= liabilities
βββ Reveals: NOTHING about individual balances
βββ Verified: On-chain by smart contract
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β SOLVENCY PROOF PROTOCOL β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ€
β β
β ββββββββββββββββ ββββββββββββββββ ββββββββββββββββ β
β β YELLOW β β MERKLE β β RESERVE β β
β β NETWORK βββββΆβ TREE β β SCANNER β β
β β (Sessions) β β (Commit) β β (On-chain) β β
β ββββββββββββββββ ββββββββββββββββ ββββββββββββββββ β
β β β β β
β βΌ βΌ βΌ β
β βββββββββββββββββββββββββββββββββββββββββββββββββββββββ β
β β ZK PROOF GENERATOR β β
β β (Groth16 Solvency Circuit) β β
β β β β
β β INPUT: liabilitiesRoot, reservesTotal, epochId β β
β β OUTPUT: isSolvent (1 or 0) β β
β βββββββββββββββββββββββββββββββββββββββββββββββββββββββ β
β β β
β βΌ β
β βββββββββββββββββββββββββββββββββββββββββββββββββββββββ β
β β SMART CONTRACT VERIFICATION β β
β β (SolvencyProofRegistry.sol) β β
β β β β
β β β’ Verifies Groth16 proof on-chain β β
β β β’ Stores epoch data permanently β β
β β β’ Emits SolvencyProved event β β
β βββββββββββββββββββββββββββββββββββββββββββββββββββββββ β
β β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
- β Privacy: Individual balances NEVER revealed
- β Trustless: Math, not auditors
- β Real-time: Generate proofs on-demand
- β Cheap: ~$5 gas vs $100K audit
- β Verifiable: Anyone can check on-chain
Connect Wallet β Create Session β Add Users β Build Tree β Scan Reserves β Generate Proof β Submit On-Chain
(Login) (Yellow) (Instant) (Merkle) (ETH) (ZK) (Verified!)
Detailed Flow:
- Login - Authenticate to access the verification portal
- Yellow Sessions - Create state channel for instant balance updates
- Add Participants - Add users with their balances (off-chain, instant)
- Build Merkle Tree - Commit all liabilities to single hash
- Scan Reserves - Query on-chain ETH balances of reserve addresses
- Generate ZK Proof - Prove reserves >= liabilities without revealing amounts
- Submit On-Chain - Smart contract verifies and stores proof permanently
- Anyone Verifies - Public can check solvency status on Etherscan
| Component | Status | Description | Proof |
|---|---|---|---|
| ZK Solvency Circuit | β Complete | Groth16 proof of reserves >= liabilities | solvency.circom |
| Merkle Tree Builder | β Complete | Privacy-preserving liability commitment | liabilities-builder.ts |
| Reserve Scanner | β Complete | On-chain ETH balance verification | reserves-scanner.ts |
| Yellow Network | β Complete | State channels for instant updates | API /api/yellow/* |
| Smart Contracts | β Deployed | On-chain proof verification | Etherscan |
| Backend API | β Live | 21 endpoints, Railway hosted | API Health |
| Frontend Portal | β Complete | React dashboard with auth | Frontend |
| User Inclusion Proofs | β Complete | Merkle proofs for individual users | GET /api/liabilities/verify/:userId |
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β FRONTEND (React + Vite) β
β βββββββββββββββ βββββββββββββββ βββββββββββββββ βββββββββββββββ β
β β Dashboard β β Yellow β β Liabilities β β Proof β β
β β /verify β β /yellow β β /liabilitiesβ β /proof β β
β βββββββββββββββ βββββββββββββββ βββββββββββββββ βββββββββββββββ β
β β β β β β
β ββββββββββββββββΌββββββββββββββββΌββββββββββββββββ β
β βΌ βΌ β
β βββββββββββββββββββββββββββββββββββββββ β
β β useSolvencyProof() Hook β β
β β (API client with caching) β β
β βββββββββββββββββββββββββββββββββββββββ β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β
βΌ HTTPS
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β BACKEND (Node.js + Express) β
β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β
β β API Server β β
β β /health /api/liabilities /api/reserves /api/proof /api/yellowβ β
β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β
β β β β β β
β βΌ βΌ βΌ βΌ β
β βββββββββββββ βββββββββββββ βββββββββββββ βββββββββββββ β
β β Merkle β β Reserve β β ZK β β Yellow β β
β β Builder β β Scanner β β Prover β β Sessions β β
β βββββββββββββ βββββββββββββ βββββββββββββ βββββββββββββ β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β
βΌ JSON-RPC
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β ETHEREUM SEPOLIA BLOCKCHAIN β
β βββββββββββββββββββββββββββββββ βββββββββββββββββββββββββββββββ β
β β Groth16Verifier.sol β β SolvencyProofRegistry.sol β β
β β 0x5e22F8...E1D2DD6 β β 0x7a9f15...b708aB33d β β
β β β β β β
β β β’ verifyProof() β β β’ submitProof() β β
β β β’ Validates ZK proofs ββββ β’ getProof() β β
β β β β β’ getEpochCount() β β
β βββββββββββββββββββββββββββββββ βββββββββββββββββββββββββββββββ β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
Copy-paste these commands to verify the system works:
# 1. Health Check
curl -s "https://solvency-proof-production.up.railway.app/health" | jq
# 2. Get Current Liabilities (Merkle Root)
curl -s "https://solvency-proof-production.up.railway.app/api/liabilities" | jq
# 3. Get Reserve Balances
curl -s "https://solvency-proof-production.up.railway.app/api/reserves" | jq
# 4. Get Deployed Contract Addresses
curl -s "https://solvency-proof-production.up.railway.app/api/contracts" | jq
# 5. Get Epoch Count (Number of Verified Proofs)
curl -s "https://solvency-proof-production.up.railway.app/api/contracts/epoch-count" | jq
# 6. Get Yellow Network Sessions
curl -s "https://solvency-proof-production.up.railway.app/api/yellow/sessions" | jqExpected Output:
- β
status: "ok"- Backend healthy - β
root: "0x..."- Liabilities committed - β
addresses: [...]- Reserve addresses with ETH balances - β
epochCount: N- Number of on-chain proofs
template Solvency() {
// Public inputs
signal input liabilitiesRoot;
signal input reservesTotal;
signal input epochId;
// Private inputs (hidden!)
signal input liabilitiesTotal;
// Output: 1 = solvent, 0 = insolvent
signal output isSolvent;
// Core constraint: reserves >= liabilities
component gte = GreaterEqThan(252);
gte.in[0] <== reservesTotal;
gte.in[1] <== liabilitiesTotal;
isSolvent <== gte.out;
isSolvent === 1; // Proof fails if not solvent!
}function submitProof(
bytes32 epochId,
bytes32 liabilitiesRoot,
uint256 reservesTotal,
uint256[2] calldata _pA,
uint256[2][2] calldata _pB,
uint256[2] calldata _pC,
uint256[4] calldata _pubSignals
) external {
// Validate public signals
require(_pubSignals[0] == 1, "Proof shows insolvency");
require(_pubSignals[2] == reservesTotal, "Reserves mismatch");
// Verify ZK proof on-chain
bool valid = verifier.verifyProof(_pA, _pB, _pC, _pubSignals);
require(valid, "Invalid proof");
// Store verified proof permanently
proofs[epochId] = SolvencyProof({...});
emit SolvencyProved(epochId, liabilitiesRoot, reservesTotal, ...);
}- Runtime: Node.js + TypeScript
- Framework: Express.js
- Blockchain: Viem (Ethereum interactions)
- ZK: Circom 2.1.6, SnarkJS, Groth16
- State Channels: Yellow Network / Nitrolite
- Hosting: Railway
- Framework: React 18 + TypeScript
- Build: Vite
- Styling: TailwindCSS + shadcn/ui
- State: TanStack Query (React Query)
- Routing: React Router v6
- Components: Radix UI primitives
- Language: Solidity 0.8.24
- Framework: Hardhat
- Network: Ethereum Sepolia
- Verification: Groth16Verifier (auto-generated from circuit)
- Language: Circom 2.1.6
- Proving System: Groth16
- Curve: BN128
- Libraries: circomlib
| Contract | Address | Purpose |
|---|---|---|
| SolvencyProofRegistry | 0x7a9f15BCD95FDD20cf31A480f37CAA9b708aB33d |
Stores verified solvency proofs |
| Groth16Verifier | 0x5e22F8cB0CfbC0df5F2251009674E1266E1D2DD6 |
Verifies ZK proofs on-chain |
| Service | URL | Status |
|---|---|---|
| Production API | solvency-proof-production.up.railway.app | β Live |
| Health Endpoint | /health | β Responding |
- β NOT just another Merkle tree
- β NOT just a proof-of-reserves attestation
- β NOT centralized auditor trust
- β IS a complete ZK solvency protocol with privacy guarantees
| Layer | Innovation | Impact |
|---|---|---|
| Privacy | ZK proofs hide individual balances | Users stay anonymous |
| State Channels | Yellow Network for instant updates | No gas for balance changes |
| Merkle Commitments | Single hash for all liabilities | Efficient on-chain storage |
| On-chain Verification | Smart contract validates proofs | Trustless, anyone can verify |
| User Inclusion | Individual Merkle proofs | Users verify their own balance |
- β Post-FTX world demands proof of reserves
- β Privacy regulations require data protection
- β ZK technology is now production-ready
- β L2s make on-chain verification affordable
| Document | Description |
|---|---|
| π API Documentation | Complete endpoint reference (21 endpoints) |
| π Enterprise Audit Guide | Security and audit information |
| β‘ ZK Circuit | Groth16 solvency proof circuit |
| π Smart Contracts | Solidity source code |
| π¨ Frontend | React dashboard source |
User Balances β Hash Each β Build Tree β Single Root
alice: 1000 β β β
bob: 2000 ββββββΌβββββββββββΌβββββββββββββΌββββΆ 0x60700382e80fbacd...
carol: 1500 β β β
- Each user balance is hashed with their ID
- Merkle tree aggregates all hashes
- Root commits to ALL balances with single 32-byte value
- Users can prove inclusion without revealing others
Reserve Addresses β Query Blockchain β Sum Balances
0xABC... β β
0xDEF... βββββββββββΌβββββββββββββββββββΌββββΆ 0.355 ETH
0x123... β β
- Exchange provides list of reserve addresses
- Backend queries actual on-chain ETH balances
- Sum is publicly verifiable by anyone
Private: liabilitiesTotal (hidden)
Public: liabilitiesRoot, reservesTotal, epochId
β
βΌ
βββββββββββββββββ
β ZK Circuit β
β reserves >= β
β liabilities β
βββββββββββββββββ
β
βΌ
Proof: {pA, pB, pC}
Output: isSolvent = 1
- Prover knows actual liability total (private)
- Circuit proves reserves >= liabilities
- Output reveals ONLY solvency status, not amounts
// Smart contract verifies proof
bool valid = verifier.verifyProof(pA, pB, pC, pubSignals);
require(valid, "Invalid proof");
require(pubSignals[0] == 1, "Not solvent");
// Store permanently
proofs[epochId] = SolvencyProof{...};
emit SolvencyProved(epochId, ...);- Anyone can verify on Etherscan
- Proof is permanent and immutable
- Full audit trail of all epochs
- Node.js 18+
- pnpm (recommended) or npm
- Circom 2.1.6 (for circuit development)
# Clone the repository
git clone https://github.com/your-org/Solvency-Proof.git
cd Solvency-Proof
# Backend
cd SolvencyProff_Core-Backend/backend
pnpm install
pnpm dev
# Frontend (new terminal)
cd Solvency-Proof-Frontend
pnpm install
pnpm dev
# Smart Contracts
cd SolvencyProff_Core-Backend/contracts
pnpm install
npx hardhat compile
npx hardhat test# Backend (.env)
SEPOLIA_RPC_URL=https://sepolia.infura.io/v3/YOUR_KEY
PRIVATE_KEY=0x...
PORT=3001
# Frontend (.env)
VITE_API_URL=https://solvency-proof-production.up.railway.app# Backend tests
cd SolvencyProff_Core-Backend/backend
pnpm test
# Contract tests
cd SolvencyProff_Core-Backend/contracts
npx hardhat test
# Frontend tests
cd Solvency-Proof-Frontend
pnpm test# Backend to Railway
cd SolvencyProff_Core-Backend/backend
railway up
# Frontend to Vercel
cd Solvency-Proof-Frontend
vercel deploySolvency-Proof/
βββ Solvency-Proof-Frontend/ # React Frontend
β βββ src/
β β βββ components/ # UI components (shadcn/ui)
β β βββ contexts/ # Auth context
β β βββ hooks/ # useSolvencyProof API hook
β β βββ pages/ # Route pages
β β β βββ app/ # Dashboard, Liabilities, Reserves, etc.
β β βββ lib/ # Utilities and constants
β βββ package.json
β βββ vite.config.ts
β
βββ SolvencyProff_Core-Backend/ # Backend + Contracts + Circuits
β βββ backend/
β β βββ src/
β β β βββ api/ # Express server
β β β βββ liabilities-builder.ts
β β β βββ reserves-scanner.ts
β β β βββ solvency-prover.ts
β β β βββ submit-proof.ts
β β βββ API.md # Endpoint documentation
β β
β βββ circuits/
β β βββ solvency.circom # ZK solvency circuit
β β βββ scripts/ # Compilation scripts
β β
β βββ contracts/
β β βββ contracts/
β β β βββ Groth16Verifier.sol # Auto-generated verifier
β β β βββ SolvencyProofRegistry.sol
β β βββ scripts/ # Deployment scripts
β β βββ test/ # Contract tests
β β
β βββ data/ # Sample data files
β
βββ README.md # This file
MIT License - See LICENSE for details.
- Fork the repository
- Create your feature branch (
git checkout -b feature/amazing-feature) - Commit your changes (
git commit -m 'Add amazing feature') - Push to the branch (
git push origin feature/amazing-feature) - Open a Pull Request
Built with β€οΈ by the SolvencyProof Team