{"id":30594080,"url":"https://github.com/theartificialdev/ybe-crm","last_synced_at":"2025-09-26T15:49:36.371Z","repository":{"id":310301657,"uuid":"1039379113","full_name":"TheArtificialDev/ybe-crm","owner":"TheArtificialDev","description":null,"archived":false,"fork":false,"pushed_at":"2025-08-17T07:23:04.000Z","size":91,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"master","last_synced_at":"2025-08-29T20:27:55.342Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"https://ybe-crm.vercel.app","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/TheArtificialDev.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2025-08-17T05:02:55.000Z","updated_at":"2025-08-17T07:23:06.000Z","dependencies_parsed_at":null,"dependency_job_id":"de47c160-dd28-4e0f-9452-2c4dc32bbc83","html_url":"https://github.com/TheArtificialDev/ybe-crm","commit_stats":null,"previous_names":["theartificialdev/ybe-crm"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/TheArtificialDev/ybe-crm","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TheArtificialDev%2Fybe-crm","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TheArtificialDev%2Fybe-crm/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TheArtificialDev%2Fybe-crm/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TheArtificialDev%2Fybe-crm/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/TheArtificialDev","download_url":"https://codeload.github.com/TheArtificialDev/ybe-crm/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TheArtificialDev%2Fybe-crm/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":277103473,"owners_count":25761397,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-09-26T02:00:09.010Z","response_time":78,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2025-08-29T19:35:47.652Z","updated_at":"2025-09-26T15:49:36.355Z","avatar_url":"https://github.com/TheArtificialDev.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Y-Be.tech CRM\n\nA secure internal CRM tool built with Next.js, featuring strong authentication with mandatory 2FA and Supabase integration.\n\n## Features\n\n- ✅ **Secure Authentication**: Username/password with comprehensive security\n- ✅ **Mandatory 2FA**: TOTP authenticator app integration with QR setup\n- ✅ **Account Security**: Failed attempt tracking and automatic lockouts\n- ✅ **Session Management**: 2-hour sessions with automatic expiry\n- ✅ **Supabase Integration**: Secure database with Row Level Security\n- ✅ **Audit Logging**: Complete security event logging\n- ✅ **Vercel Deployment Ready**: Optimized for production deployment\n\n## Getting Started\n\n### Prerequisites\n\n- Node.js 18+ and npm\n- Supabase project setup\n- An authenticator app (Google Authenticator, Authy, etc.)\n\n### Installation\n\n1. **Install dependencies:**\n```bash\nnpm install\n```\n\n2. **Configure Environment:**\n```bash\ncp .env.example .env.local\n```\n\nEdit `.env.local` with your Supabase credentials:\n\n```env\nNEXT_PUBLIC_SUPABASE_URL=https://your-project.supabase.co\nNEXT_PUBLIC_SUPABASE_ANON_KEY=your_supabase_anon_key\nJWT_SECRET=your_very_strong_jwt_secret_at_least_32_chars\n```\n\n3. **Start the development server:**\n```bash\nnpm run dev\n```\n\n4. **Access the application:**\n   - Open [http://localhost:3000](http://localhost:3000)\n   - Login with: `admin` / `admin123`\n   - Set up 2FA when prompted\n\n## Authentication Flow\n\n1. **Login**: Username/password validation\n2. **Account Security**: Lockout after 5 failed attempts (30 minutes)\n3. **2FA Setup**: QR code generation for authenticator apps\n4. **2FA Verification**: 6-digit code validation\n5. **Session Creation**: Secure session with 2-hour expiry\n6. **Dashboard Access**: Protected application interface\n\n### Default Credentials\n\n⚠️ **CHANGE IN PRODUCTION!**\n- **Username:** `admin`\n- **Password:** `admin123`\n- **2FA:** Setup required on first login\n\n## Deployment\n\n### Vercel Deployment\n\n1. **Connect repository to Vercel**\n2. **Set environment variables in Vercel dashboard:**\n   ```env\n   NEXT_PUBLIC_SUPABASE_URL=https://your-project.supabase.co\n   NEXT_PUBLIC_SUPABASE_ANON_KEY=your_supabase_anon_key\n   JWT_SECRET=your_very_strong_jwt_secret\n   ```\n3. **Deploy**\n\n## Security Features\n\n- **Account Lockout**: 5 failed attempts = 30-minute lockout\n- **Session Security**: 2-hour maximum session duration\n- **Password Hashing**: Bcrypt with 12 salt rounds\n- **2FA Required**: Mandatory for all users\n- **Audit Logging**: All authentication events logged\n- **Row Level Security**: Database-level access control\n\n## Project Structure\n\n```\nsrc/\n├── app/\n│   ├── api/auth/              # Authentication APIs\n│   ├── auth/verify-2fa/       # 2FA verification page\n│   ├── dashboard/             # Protected dashboard\n│   └── page.tsx              # Login page\n├── lib/\n│   ├── auth-service.ts       # Authentication service\n│   └── supabase.ts          # Supabase client\n└── middleware.ts             # Route protection\n```\n\n## License\n\nInternal use only - Y-Be.tech\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftheartificialdev%2Fybe-crm","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftheartificialdev%2Fybe-crm","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftheartificialdev%2Fybe-crm/lists"}