Winner of Google Developer Groups @ McMaster Hackathon π
CodeTurret is an automated security architect designed for the era of vibe-coding. Point it at any GitHub repository and it will scan for vulnerabilities, stream results live, and automatically open a pull request with AI-generated fixes.
- Dual-Pass AI Scanning -> Gemini Flash for rapid triage across all files, Gemini Pro for deep analysis on high-severity findings
- Real-Time Streaming -> scan progress streams file-by-file via Server-Sent Events; no waiting for a blocking response
- Auto-Fix PRs -> after a scan, one click generates AI patches for every vulnerability and opens a GitHub Pull Request
- Git Intelligence -> git blame, hot-file detection, and security commit analysis enrich every finding with authorship context
- Ask Cortex -> natural-language security consultant powered by Snowflake Cortex AI; ask "who introduced the SQL injection?" and get an answer
- Async Job Queue -> scans are processed via RabbitMQ workers; the API returns instantly and the UI streams progress
Next.js Frontend
β
βββ POST /api/scan ββββββββββββββββββΊ RabbitMQ [scan.requests]
βββ GET /api/scans/{id}/stream βββββ SSE β RabbitMQ [scan.progress]
βββ GET /api/findings/{scanId}
βββ POST /api/ask βββββββββββββββββββΊ Snowflake Cortex AI
Spring Boot 3.3 (Java 21)
βββ ScanWorker β clones repo, runs Gemini Flash + Pro, persists findings
βββ FixWorker β generates patches with Gemini Pro, pushes branch, opens PR
Storage
βββ PostgreSQL β repos, scans, findings, fix PRs
βββ Snowflake β Cortex AI for natural-language Q&A over findings
| Layer | Technology |
|---|---|
| Backend | Java 21, Spring Boot 3.3 |
| Message Queue | RabbitMQ |
| Primary DB | PostgreSQL + Flyway |
| AI Scanning | Google Gemini 2.0 Flash + 2.5 Pro |
| AI Chat | Snowflake Cortex (llama3.1-8b) |
| Frontend | Next.js 14, Tailwind CSS |
| Git Operations | JGit |
- Java 21
- Maven
- Docker Desktop (for PostgreSQL + RabbitMQ)
- A Gemini API key
- Snowflake account (for the Ask feature β optional)
# 1. Start PostgreSQL + RabbitMQ
cd backend
docker-compose up -d
# 2. Configure environment
cp .env.example .env
# Fill in GEMINI_API_KEY, ENCRYPTION_SECRET_KEY
# Add SNOWFLAKE_* credentials if you want the Ask feature
# 3. Start the backend (Flyway auto-creates tables on first run)
mvn spring-boot:run
# 4. Start the frontend
cd ../frontend
cp .env.local.example .env.local
npm install && npm run devBackend: http://localhost:8080 Β· Frontend: http://localhost:3000
| Method | Endpoint | Description |
|---|---|---|
POST |
/api/scan |
Queue a scan, returns scanId immediately |
GET |
/api/scans/{id}/stream |
SSE stream of real-time scan progress |
GET |
/api/scans |
List recent scans |
GET |
/api/findings/{scanId} |
Get findings for a scan |
POST |
/api/scans/{id}/fix |
Queue auto-fix PR generation |
GET |
/api/scans/{id}/fix |
Get fix PR status |
POST |
/api/ask |
Ask Cortex a question about a scan |
POST |
/api/repos |
Register a repo with a GitHub PAT |
| Homepage | Scanner | Reports |
|---|---|---|
![]() |
![]() |
![]() |


