DocFast session 139: CORS security fix on /v1/email-change
This commit is contained in:
parent
39d22c3cff
commit
0f5953c58c
2 changed files with 22 additions and 2 deletions
|
|
@ -1,5 +1,25 @@
|
||||||
# Session Log
|
# Session Log
|
||||||
|
|
||||||
|
## Session 139 — 2026-03-07 10:00 UTC (Saturday Late Morning)
|
||||||
|
- **Production:** v0.5.1 ✅ healthy, 2 replicas, 0 restarts, ~9d uptime
|
||||||
|
- **Staging:** v0.5.2 ✅ commit 1d5d9ad (49+ commits ahead of prod)
|
||||||
|
- **K8s cluster:** All 3 nodes Ready
|
||||||
|
- **Support:** Zero tickets
|
||||||
|
- **Completed:**
|
||||||
|
1. **CORS security fix (TDD)** — `/v1/email-change` was missing from the restricted CORS origin list, receiving `Access-Control-Allow-Origin: *` instead of `https://docfast.dev`. Any website could make cross-origin requests to change a user's email if they had the API key. Fixed by adding `/v1/email-change` to `isAuthBillingRoute` check. TDD test added to app-routes.test.ts. Commit 1d5d9ad.
|
||||||
|
2. **Full codebase audit** — Reviewed: CORS config (found the gap above), XSS in verify page (safe — all inputs server-generated), admin endpoints not in OpenAPI (correct), heading hierarchy (correct), ARIA attributes (24 occurrences), npm audit (0 vulns), dependency versions (all stable), OpenAPI spec (18 paths documented).
|
||||||
|
3. **Infrastructure health check** — All 3 K8s nodes Ready, both prod replicas healthy (0 restarts, ~9d uptime), DB connected (PostgreSQL 17.4), browser pool 15/15 on both environments.
|
||||||
|
- **Total tests:** 527 (all passing, 0 errors), 40 test files
|
||||||
|
- **Open bugs:** ZERO 🎉
|
||||||
|
- **CI runner:** Still absent. Managed by Cloonar — needs investor action.
|
||||||
|
- **Investor test:**
|
||||||
|
1. Would a stranger trust this with money? Yes ✅
|
||||||
|
2. Pod crash = data loss? No — CNPG WAL archiving + MinIO ✅
|
||||||
|
3. Free tier abuse? No — removed, demo rate-limited ✅
|
||||||
|
4. Pro key recovery? Yes — with DB fallback across pods ✅
|
||||||
|
5. Every feature works? Yes ✅
|
||||||
|
- **Recommendation:** Staging v0.5.2 production-ready. 49+ commits ahead with 527 tests. Awaiting investor approval for production tag + CI runner restoration.
|
||||||
|
|
||||||
## Session 138 — 2026-03-07 07:00 UTC (Saturday Morning)
|
## Session 138 — 2026-03-07 07:00 UTC (Saturday Morning)
|
||||||
- **Production:** v0.5.1 ✅ healthy, 2 replicas, 0 restarts, ~9d uptime
|
- **Production:** v0.5.1 ✅ healthy, 2 replicas, 0 restarts, ~9d uptime
|
||||||
- **Staging:** v0.5.2 ✅ commit dd337d3 (48+ commits ahead of prod)
|
- **Staging:** v0.5.2 ✅ commit dd337d3 (48+ commits ahead of prod)
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@
|
||||||
"phaseLabel": "Build Production-Grade Product",
|
"phaseLabel": "Build Production-Grade Product",
|
||||||
"status": "launch-ready",
|
"status": "launch-ready",
|
||||||
"product": "DocFast — HTML/Markdown to PDF API",
|
"product": "DocFast — HTML/Markdown to PDF API",
|
||||||
"currentPriority": "Production on v0.5.1. Staging v0.5.2 (48+ commits ahead). npm audit 0 vulns. 527 tests passing (40 files). ZERO open bugs. Added GET /v1/usage/me for user-facing usage stats. Fixed shutdown usage flush race condition. Ready for production tag when investor approves.",
|
"currentPriority": "Production on v0.5.1. Staging v0.5.2 (49+ commits ahead). npm audit 0 vulns. 527 tests passing (40 files). ZERO open bugs. Fixed CORS security gap on /v1/email-change. Ready for production tag when investor approves.",
|
||||||
"ownerDirectives_PRIORITY": "Process these IN ORDER. Do not skip. Remove items marked ✅ DONE/FIXED during housekeeping.",
|
"ownerDirectives_PRIORITY": "Process these IN ORDER. Do not skip. Remove items marked ✅ DONE/FIXED during housekeeping.",
|
||||||
"ownerDirectives": [
|
"ownerDirectives": [
|
||||||
"Stripe Product ID for DocFast: prod_TygeG8tQPtEAdE — webhook handler must filter by this product_id to ignore events from other projects on the same Stripe account."
|
"Stripe Product ID for DocFast: prod_TygeG8tQPtEAdE — webhook handler must filter by this product_id to ignore events from other projects on the same Stripe account."
|
||||||
|
|
@ -83,7 +83,7 @@
|
||||||
"LOW": [],
|
"LOW": [],
|
||||||
"note": "All bugs resolved. BUG-105 fixed 4f6659c. BUG-104 fixed 503e651. BUG-103 (template validation bypass) fixed 47571c8. BUG-102 (sanitized options ignored) fixed ba2e542. BUG-101 (body limits) fixed c03f217. BUG-100 (flush poisoning) fixed d2f819d. BUG-099 (memory leak) fixed 5f776db. BUG-098 (interceptor leak) fixed 024fa00."
|
"note": "All bugs resolved. BUG-105 fixed 4f6659c. BUG-104 fixed 503e651. BUG-103 (template validation bypass) fixed 47571c8. BUG-102 (sanitized options ignored) fixed ba2e542. BUG-101 (body limits) fixed c03f217. BUG-100 (flush poisoning) fixed d2f819d. BUG-099 (memory leak) fixed 5f776db. BUG-098 (interceptor leak) fixed 024fa00."
|
||||||
},
|
},
|
||||||
"sessionCount": 138
|
"sessionCount": 139
|
||||||
},
|
},
|
||||||
"blockers": [],
|
"blockers": [],
|
||||||
"startDate": "2026-02-14"
|
"startDate": "2026-02-14"
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue