- Hexagonal identity module: domain ports, use cases, argon2id hasher, pg repos - Migration 002_identity: identity_users + identity_sessions (token hash only) - Opaque 512-bit session tokens; DB stores SHA-256 hash; 7-day TTL in SQL - Cookie HttpOnly + Secure (COOKIE_SECURE, default true) + SameSite=Lax - LoginRateLimiter: 10 failures -> 429 + Retry-After, 15-min cooldown - Anti-enumeration: identical generic 401 + dummy-hash timing equalization - buildApp gains optional pool/cookieSecure; foundation-only app preserved - 47 unit + 14 integration tests; live smoke covers all acceptance criteria
36 lines
3.0 KiB
Markdown
36 lines
3.0 KiB
Markdown
# Historial (append-only)
|
|
|
|
> Añadir entradas al final. No reescribir historial previo.
|
|
|
|
## 2026-08-14 — F-001 Scaffold modular monolith skeleton — DONE
|
|
- Gates: reviewer APPROVED, security APPROVED, qa APPROVED, verify.sh exit 0
|
|
- Entregable: skeleton TypeScript + Fastify en project/ con boundary checker testeado; specs/F-001-scaffold completos; spec/tech.md con justificación de dependencias
|
|
- Artefactos: work/artifacts/F-001/ (architect.md, implementer.md, reviewer.json, security.json, qa.json, documenter.md, leader-close.json)
|
|
- Nota: el boundary checker detectó una violación real durante build (test escapando del módulo) y se corrigió moviendo los tests de composición a src/app
|
|
|
|
## 2026-08-14 — F-002 Database foundation with module-owned schemas — DONE
|
|
- Gates: reviewer APPROVED, security APPROVED (con ronda de hardening), qa APPROVED, verify.sh exit 0
|
|
- Entregable: migraciones node-pg-migrate (up/down/no-op probados contra PostgreSQL 16 real), pool fail-fast, docker-compose (Postgres + Redis), convención <module>_<table> documentada
|
|
- Nota: security devolvió un hallazgo bajo (interpolación de identificador en DDL de tests); se mitigó con validación estricta + tests de regresión
|
|
- Artefactos: work/artifacts/F-002/
|
|
|
|
## 2026-08-14 — F-003 HTTP foundation and request context — DONE
|
|
- Gates: reviewer APPROVED, security APPROVED, qa APPROVED, verify.sh exit 0
|
|
- Entregable: request_id (generado o propagado-sanitizado), logs JSON correlacionados, error envelope v2 con requestId, hook de validación parseJson (zod), server con logging inyectable
|
|
- Nota: doc stage rebotó a build para escribir README (project/ está gateado a build/implementer/running); comportamiento correcto del guardrail
|
|
- Artefactos: work/artifacts/F-003/
|
|
|
|
## 2026-08-14 — F-004 Typed config and feature flags — DONE
|
|
- Gates: reviewer APPROVED, security APPROVED, qa APPROVED, verify.sh exit 0
|
|
- Entregable: loadConfig fail-fast (DATABASE_URL requerido, errores solo con nombres de variables), módulo flags tras FeatureFlagProvider (default OFF, flip en runtime sin redeploy), app.flags decorado
|
|
- Nota: los tests detectaron un bug real en build (case-normalization del store); corregido antes de gates con test de regresión
|
|
- Cero dependencias nuevas
|
|
- Artefactos: work/artifacts/F-004/
|
|
|
|
## 2026-08-14 — F-005 Identity: register, login, sessions — DONE
|
|
- Gates: reviewer APPROVED, security APPROVED, qa APPROVED, verify.sh exit 0
|
|
- Entregable: módulo identity hexagonal (domain/application/infrastructure/api), migración 002 reversible, argon2id OWASP tras puerto PasswordHasher, sesiones opacas (solo SHA-256 del token en DB), cookie HttpOnly+Secure+SameSite=Lax, rate limit 10 fallos -> 429 + Retry-After tras interfaz, 401 idéntico anti-enumeración con timing igualado
|
|
- Nota: review detectó falta de tests para COOKIE_SECURE; fix aplicado antes de aprobar el gate. Suite de migraciones F-002 actualizada a rollback completo (count:0) por tener ahora 2 migraciones
|
|
- Deps nuevas: argon2, @fastify/cookie (justificadas en spec/tech.md)
|
|
- Artefactos: work/artifacts/F-005/
|