A hybrid web application that provides digital identity verification and fraud reporting/tracking functionality.
The project has two main components:
-
OTID (One-Time Digital Identity Verification)
- User registration with name, email, photo, and ID document
- AI-based face matching for identity verification
- Generation of unique OTID tokens stored on a simulated blockchain
-
FAN (Fraud Alert Network)
- Form for reporting fraud incidents
- Secure database for storing fraud reports
- Association of fraud reports with OTIDs
- API endpoint to check fraud status of any OTID
- Frontend: React.js with React Bootstrap
- Backend: Node.js with Express
- Database: MongoDB
- Additional Tools:
- face-api.js for facial recognition
- ethers.js for blockchain simulation
- JWT for authentication
-
Clone the repository:
git clone https://github.com/848deepak/OTID-FAN.git cd OTID-FAN -
Install dependencies:
npm run install-all -
Create a
.envfile in the root directory with:MONGODB_URI=your_mongodb_connection_string JWT_SECRET=your_jwt_secret PORT=5000 -
Create the uploads directories:
mkdir -p uploads/photos uploads/ids uploads/evidence -
Start the backend development server:
npm run dev -
In a separate terminal, start the frontend:
cd client npm start -
Open your browser and navigate to
http://localhost:3000
Ready to deploy? Check out our comprehensive Deployment Guide for step-by-step instructions to host your application on:
- Vercel (Recommended - Free tier available)
- Netlify + Railway
- Render
OTID-FAN/
├── client/ # React frontend
│ ├── public/ # Static files
│ └── src/ # React source code
│ ├── components/ # React components
│ │ ├── auth/ # Authentication components
│ │ ├── fraud/ # Fraud reporting components
│ │ ├── layout/ # Layout components
│ │ ├── otid/ # Identity verification components
│ │ └── pages/ # Page components
│ ├── App.js # Main App component
│ └── index.js # Entry point
├── server/ # Node.js backend
│ ├── models/ # MongoDB models
│ ├── routes/ # API routes
│ ├── utils/ # Utility functions
│ └── index.js # Server entry point
├── uploads/ # Uploaded files directory
├── DEPLOYMENT.md # Deployment guide
└── .env # Environment variables
-
Authentication
POST /api/auth/register- Register a new userPOST /api/auth/login- Login a userGET /api/auth/me- Get current user's data
-
OTID
POST /api/otid/upload- Upload identity documentsPOST /api/otid/verify- Verify identity and generate OTIDGET /api/otid/validate/:otid- Validate an OTID
-
Fraud
POST /api/fraud/report- Submit a fraud reportGET /api/fraud/check/:otid- Check if an OTID has fraud reportsGET /api/fraud/all- Get all fraud reports (admin only)
-
User Registration and Authentication
- Secure user registration and login
- JWT-based authentication
-
Identity Verification
- Upload of selfie photo and ID document
- Simulated face matching verification
- Generation of unique OTID
-
Blockchain Integration
- Simulated blockchain for storing OTID hashes
- Optional Ethereum testnet integration
-
Fraud Reporting System
- Detailed fraud reporting form
- Association with OTID if known
- Evidence upload capabilities
-
Fraud Lookup
- OTID validation
- Fraud status checking
- Detailed fraud report display
- Fork the repository
- Create your feature branch (
git checkout -b feature/AmazingFeature) - Commit your changes (
git commit -m 'Add some AmazingFeature') - Push to the branch (
git push origin feature/AmazingFeature) - Open a Pull Request
This project is licensed under the MIT License - see the LICENSE file for details.
If you encounter any issues or have questions:
- Check the Deployment Guide for common issues
- Open an issue on GitHub
- Review the troubleshooting section in the deployment guide