A comprehensive platform for discovering, validating, and tracking unsecured API keys across various code repositories and platforms. This project serves educational and security awareness purposes by demonstrating how easily API keys can be exposed in public repositories.
This project is designed for educational and security awareness purposes. It demonstrates common security vulnerabilities in API key management. Please use responsibly and in accordance with applicable laws and regulations.
The project consists of several interconnected components:
- WebAPI (.NET 9): Core backend providing REST endpoints and real-time SignalR communication
- UI (Next.js): Frontend interface with educational content and API key discovery features
- Data Layer (Entity Framework + PostgreSQL): Comprehensive data modeling and persistence
- Providers Library: Extensible validation framework for different API providers
- Verification Bot: Automated validation of discovered keys
- Scraper Bot: Automated discovery of API keys across platforms
- API Key Discovery: Search and discover exposed API keys across multiple platforms
- Validation Engine: Verify the validity and functionality of discovered keys
- Real-time Updates: Live statistics and updates using SignalR
- Educational Interface: Learn about API security through interactive examples
- Modular Design: Clean separation between discovery, validation, and presentation layers
- Extensible Provider System: Easy addition of new API validation providers
- Comprehensive Analytics: Track discoveries, validations, and security metrics
- Rate Limiting: Intelligent rate limiting with user-based overrides
- Discord Integration: Enhanced features for authenticated users
- .NET 9 - Modern web API framework
- Entity Framework Core - ORM for database operations
- PostgreSQL - Primary database
- SignalR - Real-time communication
- Docker - Containerization support
- Next.js 14 - React framework with TypeScript
- HeroUI - Modern component library
- Tailwind CSS - Utility-first CSS framework
- Framer Motion - Animation library
- Docker Compose - Multi-container development
- Entity Framework Migrations - Database schema management
- Sentry - Error tracking and monitoring
- GitHub Actions - CI/CD pipeline
- Docker and Docker Compose
- PostgreSQL database
- .NET 9 SDK
- Node.js 18+ and npm/yarn
- (Optional) Discord Application for OAuth
- (Optional) Sentry account for error tracking
git clone https://github.com/TSCarterJr/UnsecuredAPIKeys-OpenSource.git
cd UnsecuredAPIKeys-OpenSource
# Copy example configuration files
cp UnsecuredAPIKeys.WebAPI/appsettings.example.json UnsecuredAPIKeys.WebAPI/appsettings.json
cp UnsecuredAPIKeys.UI/.env.example UnsecuredAPIKeys.UI/.env.development
cp UnsecuredAPIKeys.Bots.Verifier/appsettings.example.json UnsecuredAPIKeys.Bots.Verifier/appsettings.json
docker run --name unsecured-api-keys-db \
-e POSTGRES_DB=UnsecuredAPIKeys \
-e POSTGRES_USER=postgres \
-e POSTGRES_PASSWORD=your_password \
-p 5432:5432 \
-d postgres:15
cd UnsecuredAPIKeys.WebAPI
dotnet ef database update --project ../UnsecuredAPIKeys.Data --startup-project .
cd UnsecuredAPIKeys.WebAPI
dotnet run
cd UnsecuredAPIKeys.UI
npm install
npm run dev
cd UnsecuredAPIKeys.Bots.Verifier
dotnet run
- UI: http://localhost:3000
- API: http://localhost:7227
- API Documentation: http://localhost:7227/scalar/v1
- Deployment Guide - Comprehensive deployment instructions
- Open Source Cleanup Plan - Details about the open source preparation
- API Documentation - API provider integration guide
- UI Implementation Summary - Frontend architecture overview
UnsecuredAPIKeys-OpenSource/
βββ UnsecuredAPIKeys.WebAPI/ # Main API server
βββ UnsecuredAPIKeys.UI/ # Next.js frontend
βββ UnsecuredAPIKeys.Data/ # Entity Framework data layer
βββ UnsecuredAPIKeys.Providers/ # API provider validation logic
βββ UnsecuredAPIKeys.Bots.Verifier/ # Verification bot
βββ UnsecuredAPIKeys.Bots.Scraper/ # Scraper bot
βββ UnsecuredAPIKeys.Common/ # Shared utilities
βββ docs/ # Documentation
- Repository Pattern: Clean data access abstraction
- Provider Pattern: Extensible API validation system
- CQRS: Separation of read/write operations
- Event-Driven: Real-time updates using SignalR
- Modular Architecture: Independent, testable components
CONNECTION_STRING="Host=localhost;Database=UnsecuredAPIKeys;Username=postgres;Password=your_password;Port=5432"
PRODUCTION_DOMAIN="yourdomain.com"
SCRAPER_SERVICE_NAME="api-scraper"
VERIFIER_SERVICE_NAME="api-verifier"
NEXT_PUBLIC_API_URL="http://localhost:7227"
NEXT_PUBLIC_GA_MEASUREMENT_ID="YOUR_GA_MEASUREMENT_ID"
SENTRY_ORG="your-sentry-org"
SENTRY_PROJECT="your-sentry-project"
- Discord OAuth: Enhanced rate limits and user features
- Google Analytics: Usage tracking and insights
- Sentry: Error tracking and performance monitoring
- Fork the repository
- Create a 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
- Follow .NET and React best practices
- Include tests for new features
- Update documentation for API changes
- Ensure all builds pass before submitting
This project is licensed under a custom attribution-required license based on MIT - see the LICENSE file for complete details.
Any use of this code (even partial) requires UI attribution. If you use ANY portion of this project in software with a public-facing interface, you MUST:
- Display a link to this GitHub repository in your UI
- Link text should be "Based on UnsecuredAPIKeys Open Source" or similar
- Link to:
https://github.com/TSCarterJr/UnsecuredAPIKeys-OpenSource
- Must be visible on main page or footer
This applies whether you use the entire project, just the backend APIs, validation logic, bots, or any other component. Removing attribution violates the license and constitutes copyright infringement.
- Educational Purpose: This tool is designed for security education and awareness
- Responsible Use: Users are responsible for compliance with applicable laws
- No Warranty: The software is provided as-is without warranty
- Ethical Guidelines: Use only for legitimate security research and education
- The open source community for inspiration and tools
- Security researchers who highlight the importance of proper API key management
- Contributors who help improve the project
The domain unsecuredapikeys.com is available for sale. If you're interested in acquiring this domain for your own security-focused project or business, please reach out through the GitHub repository.
For issues specific to this open source version:
- Check the Issues section
- Create a new issue with detailed information about your setup
- Provide logs and configuration details (without sensitive information)
Remember: This project is for educational purposes. Always use responsibly and in accordance with applicable laws and regulations.