A fully functional identity verification app built with Solstice SDK and Protocol. Users must verify their age (18+) using their Aadhaar QR code to access restricted content.
- โ Zero-Knowledge Age Verification: Prove you're 18+ without revealing your date of birth
- ๐ธ QR Code Scanning: Scan Aadhaar QR codes directly from your camera
- ๐ค Image Upload: Upload QR code images for verification
A demonstration of how third-party applications integrate with the Solstice Protocol for age verification. This app showcases the challenge-response architecture where users verify their age through the main Solstice app, not by sharing their Aadhaar data directly.
This is a third-party consumer app that:
- Generates verification challenge QR codes
- Displays challenges for users to scan with the main Solstice app
- Waits for zero-knowledge proof responses
- Verifies proofs and grants access
Important: This app does NOT scan Aadhaar QR codes. Identity registration happens once in the main Solstice app.
- ๐ฎ Age-Gated Content: Access restricted to verified adults (18+)
- ๐ Privacy-Preserving: Uses challenge-response with zero-knowledge proofs
- ๐ฑ QR Challenge Generation: Creates challenges that users scan in the main Solstice app
- ๐งช Demo Mode: Skip verification for testing the UI
- โก Solana Integration: Proofs verified on Solana devnet
- ๐จ Beautiful UI: Modern, responsive design with Solana-themed gradients
- ๐ Privacy-First: All personal data stays on your device
- ๐ Built on Solana: Fast and cost-efficient blockchain verification
- ๐จ Beautiful UI: Built with Tailwind CSS and shadcn/ui
-
Third-Party App (this app):
- Generates a verification challenge using
sdk.generateChallenge() - Encodes challenge into a QR code
- Displays QR code for user to scan
- Generates a verification challenge using
-
User Action:
- Opens the main Solstice app (where they registered identity once)
- Scans the challenge QR code
- Solstice app generates ZK proof and sends it back
-
Verification:
- Third-party app receives the proof response
- Verifies proof using
sdk.verifyProofResponse() - Grants access if verified
-
Privacy:
- No personal data (Aadhaar, DOB, etc.) is ever shared
- Only a ZK proof confirming "user is 18+" is transmitted
- User maintains full control over their identity data
[This App] [User's Solstice App] [Solana Blockchain]
| | |
| 1. Generate Challenge | |
|----------------------------------->| |
| (Display QR Code) | |
| | |
| 2. Scan QR & Generate ZK Proof |
| |----------------------------->|
| | 3. Verify on-chain |
| |<-----------------------------|
| | |
| 4. Send Proof Response | |
|<-----------------------------------| |
| | |
| 5. Verify Proof | |
| | |
| 6. Grant Access | |
For testing without a real Aadhaar QR code, click "Use Demo Mode" to skip verification.
- @solsticeprotocol/sdk - Zero-knowledge identity verification
- React 19 - UI framework
- TypeScript - Type safety
- Tailwind CSS - Styling
- shadcn/ui - UI components
- html5-qrcode - QR code scanning
- Solana Web3.js - Blockchain integration
- Lucide React - Icons
- Node.js 18+ and npm
- A modern web browser with camera access (for QR scanning)
- Install dependencies:
npm install- Start the development server:
npm run dev- Open your browser to the URL shown (typically http://localhost:5173)
The app includes two ways to test:
-
Generate Verification QR: Creates a challenge QR code that users would scan with the main Solstice app
- In this demo, verification is simulated after 5 seconds
- In production, you'd poll a backend API for the actual proof response
-
Skip Verification (Demo Mode): Bypass verification to see the restricted content immediately
For the full flow to work:
- User must first register in the main Solstice app (
solstice-website/frontend) - User scans the challenge QR from this app
- Main app generates ZK proof and submits it
- This app receives and verifies the proof
See ARCHITECTURE.md for complete integration details.
src/
โโโ App.tsx # Main application component
โโโ components/
โ โโโ ui/
โ โโโ button.tsx # Button component
โ โโโ card.tsx # Card component
โโโ lib/
โโโ utils.ts # Utility functions
- Age-Gated Gaming Platform: Verify users are 18+ to access mature games
- DeFi KYC: Regulatory compliance for decentralized exchanges
- DAO Voting: Sybil-resistant governance with one person = one vote
- NFT Mints: Fair distribution to unique verified humans
- Geographic Compliance: Verify nationality for restricted services
- โ Zero-Knowledge Proofs: Only proves age โฅ 18, doesn't reveal exact age or other data
- โ Client-Side Proof Generation: Personal data never leaves your browser
- โ Cryptographic Commitments: Only hash commitments are stored on-chain
- โ Groth16 SNARKs: 128-bit security with BN254 elliptic curves
- โ 256-byte Proofs: Constant-size proofs for efficient verification
Skips verification for testing purposes
Opens camera to scan QR codes in real-time
Uploads and scans QR code from image file
Generates age proof and verifies on-chain using Solstice SDK
The app uses Solana Devnet by default. To change networks, update the SDK configuration in App.tsx:
const solsticeSDK = new SolsticeSDK({
endpoint: 'https://api.devnet.solana.com', // Change to mainnet or testnet
programId: new PublicKey('8jrTVUyvHrL5WTWyDoa6PTJRhh3MwbvLZXeGT81YjJjz'),
network: 'devnet', // mainnet | devnet | testnet
debug: true
});- Grant camera permissions in your browser settings
- Try uploading a QR code image instead
- Check your internet connection
- Verify you're using the correct Solana RPC endpoint
- Ensure QR code is from official mAadhaar app
- Check that QR code is clearly visible and not blurry
- Try Demo Mode to test the UI without real verification
- Wallet integration for on-chain proof storage
- Multi-proof support (age + nationality + uniqueness)
- Proof history and management
- Social sharing of verified status
- More game content and challenges
- NFT rewards for verified users
MIT License - See LICENSE file for details
For issues and questions, please open an issue on the GitHub repository.