If you cloned this repository before 2026-01-11, your .env.local may contain an exposed OpenAI API key.
-
Revoke the key:
- Go to https://platform.openai.com/api-keys
- Find key starting with
sk-proj-fHChBCV... - Click "Revoke"
-
Generate new key:
- Create new secret key
- Copy to
.env.local(NEVER commit) - Set spending limits
-
Verify
.gitignore:# Ensure .env.local is ignored grep ".env.local" .gitignore
-
Remove from Git history (if committed):
# WARNING: Rewrites history, coordinate with team git filter-branch --force --index-filter \ "git rm --cached --ignore-unmatch .env.local" \ --prune-empty --tag-name-filter cat -- --all git push --force --all git push --force --tags
| Version | Supported |
|---|---|
| 1.0.x | β |
DO NOT open a public GitHub issue for security vulnerabilities.
Instead:
- Email: security@yourapp.com (replace with actual email)
- Include:
- Description of vulnerability
- Steps to reproduce
- Potential impact
- Suggested fix (optional)
We will respond within 48 hours.
- β
DO: Use
.env.localfor secrets (gitignored) - β
DO: Prefix client-safe vars with
NEXT_PUBLIC_ - β DON'T: Commit
.env.localto Git - β DON'T: Log secrets to console
- β DO: Implement rate limiting (10 req/min)
- β DO: Validate all inputs
- β DO: Use server-side API keys only
- β DON'T: Trust client input without validation
- β
DO: Deploy Firestore rules (
npm run firebase:rules) - β
DO: Use user-scoped paths:
/users/{userId}/... - β DON'T: Allow public read/write access
- β
DO: Run
npm auditregularly - β DO: Update dependencies quarterly
- β DON'T: Ignore security warnings
| Secret | Rotation Frequency | Last Rotated |
|---|---|---|
| OpenAI API Key | 90 days | 2026-01-11 |
| Firebase Service Account | 180 days | TBD |
For questions: security@yourapp.com