Advanced Authentication & Secure Authenticator Management Platform π
Secure β’ Fast β’ Modern β‘
Developed by Amit Das
SecureAuth is a modern full-stack authentication platform built for secure OTP authentication, encrypted authenticator account management, session monitoring, and advanced account protection.
The platform provides secure WhatsApp OTP verification, JWT-based authentication, encrypted account storage, multi-device session management, backup & restore functionality, and PWA support.
Built with performance and security in mind, SecureAuth delivers a reliable authentication experience for modern applications.
- WhatsApp OTP Authentication
- JWT-based Secure Authentication
- HTTP-only Cookie Sessions
- Secure OTP Expiration Handling
- Rate Limited Authentication Endpoints
- Multi-device Session Support
- Active Session Tracking
- Remote Session Revocation
- Current Device Detection
- Session Activity Monitoring
- AES Encryption for Sensitive Data
- Secure PIN-based App Lock
- Helmet Security Middleware
- Express Rate Limiting
- Encrypted Backup System
- Secure Session Validation
- Store Authenticator Accounts
- Encrypted Secret Storage
- Account Rename Support
- Backup & Restore Accounts
- TOTP Account Management
- Oracle Authenticator Support
- Progressive Web App (PWA)
- Responsive UI Design
- Firebase Realtime Database Integration
- WhatsApp OTP Delivery via TextSnap
- Secure Cloud Sync
- User enters phone number
- OTP is generated securely
- OTP sent via WhatsApp
- User verifies OTP
- JWT session created securely
- Session stored in Firebase
- User accesses protected dashboard
- Authenticator accounts encrypted before storage
git clone https://github.com/AmitDas4321/SecureAuth.git
cd SecureAuthnpm installCreate a .env file in the root directory:
# ===============================================
# SecureAuth - ENVIRONMENT CONFIGURATION
# ===============================================
APP_NAME="SecureAuth"
APP_URL="https://example.com"
# TEXTSNAP CONFIG
TEXTSNAP_INSTANCE_ID="YOUR_INSTANCE_ID"
TEXTSNAP_ACCESS_TOKEN="YOUR_ACCESS_TOKEN"
# FIREBASE CONFIG
FIREBASE_DATABASE_URL="YOUR_FIREBASE_DATABASE_URL"
FIREBASE_DATABASE_SECRET="YOUR_FIREBASE_DATABASE_SECRET"
# SECURITY CONFIG
JWT_SECRET="YOUR_SECRET_KEY"
ENCRYPTION_KEY="YOUR_ENCRYPTION_KEY"npm run devOpen:
http://localhost:3000- React
- TypeScript
- Vite
- Tailwind CSS
- Express.js
- JWT Authentication
- Firebase Realtime Database
- AES Encryption
- Helmet
- Express Rate Limit
-
TextSnap API β https://textsnap.in/
Get your API credentials for WhatsApp OTP delivery
-
Firebase Realtime Database
SecureAuth
βββ dist/
βββ node_modules/
βββ src/
βββ .env
βββ .env.example
βββ .gitignore
βββ index.html
βββ metadata.json
βββ package-lock.json
βββ package.json
βββ README.md
βββ server.ts
βββ tsconfig.json
βββ vite.config.ts| Endpoint | Method | Description |
|---|---|---|
/api/auth/send-otp |
POST | Send OTP |
/api/auth/verify-otp |
POST | Verify OTP |
/api/auth/me |
GET | Get current user |
/api/auth/logout |
POST | Logout user |
/api/auth/complete-profile |
POST | Complete profile |
| Endpoint | Method | Description |
|---|---|---|
/api/auth/sessions |
GET | Get active sessions |
/api/auth/sessions/others |
DELETE | Revoke all other sessions |
/api/auth/sessions/:sessionId |
DELETE | Revoke specific session |
| Endpoint | Method | Description |
|---|---|---|
/api/auth/app-lock/setup |
POST | Setup app lock |
/api/auth/app-lock/verify |
POST | Verify PIN |
/api/auth/app-lock/toggle |
POST | Enable or disable app lock |
/api/auth/app-lock/settings |
POST | Update app lock settings |
| Endpoint | Method | Description |
|---|---|---|
/api/accounts |
GET | Get accounts |
/api/accounts |
POST | Add account |
/api/accounts/:id |
PUT | Update account |
/api/accounts/:id |
DELETE | Delete account |
/api/accounts/:id/rename |
PATCH | Rename account |
| Endpoint | Method | Description |
|---|---|---|
/api/backup/export |
POST | Export encrypted backup |
/api/backup/import |
POST | Import backup |
SecureAuth uses multiple layers of security:
- JWT session validation
- Secure HTTP-only cookies
- AES encryption for sensitive data
- Rate-limited API requests
- PIN hashing for app lock
- Session revocation support
- OTP expiration system
npm run buildnpm startnpm install -g pm2
pm2 start ecosystem.config.cjs
pm2 save
pm2 startupserver {
server_name yourdomain.com;
location / {
proxy_pass http://localhost:3000;
proxy_set_header Host $host;
}
}docker build -t secureauth .
docker run -d -p 3000:3000 --env-file .env --name secureauth-app secureauth- Use HTTPS
- Protect environment variables
- Enable firewall security
- Use strong JWT secrets
- Monitor server logs
- Rotate credentials regularly
- Backup encrypted data safely
MIT License Β© 2026 Amit Das
Made with β€οΈ by Amit Das
β Support development: PayPal.me/AmitDas4321

