Open-source manufacturing ERP, MES and QMS. Quoting, MRP, inventory, shop floor, quality and lot/serial traceability on one Postgres schema, with a REST API and MCP server. Self-host or use Carbon Cloud.
TypeScript ai-agentsbill-of-materialserpinventory-managementleanmanufacturingmanufacturing-execution-systemmcp-servermesmrpopen-source-erppostgresqlproduction-planningqmsquality-management-systemreact-routerself-hostedsupabasetraceabilitytypescript
Run: NIST 2.1 — Per-account failed-login lockout (3.1.8)
- Branch:
feat/nist-2.1-login-lockout(basenist-800-110-audit) - Mode: FULLY AUTONOMOUS
/feature— plan → execute → self-review (research & grill skipped; design pre-resolved in.ai/plans/2026-08-15-nist-800-171-app-remediation.md§2.1) - Autonomy: no human gates; gated PR is the supervision point.
Grounding (verified in code)
- ERP
apps/erp/app/routes/_public+/login.tsxL94-110: IP-only sliding-window rate-limit (Ratelimit.slidingWindow(RATE_LIMIT, "1 h"), key =ip), emitslogin_rate_limited. - MES
apps/mes/app/routes/_public+/login.tsxL79-94: same IP-only limit, no auth-event logging at all. @carbon/kvexportsRatelimit(upstash-compatible, ioredis) +redis.Durationtype available.logAuthEvent+AuthEventunion inpackages/auth/src/services/auth-events.server.ts; re-exported via@carbon/auth/auth.server.redisclient is ioredisRedis(supports incr/expire/pttl/set EX/del).
Design (resolved)
- New
@carbon/kvmodulesrc/lockout/— email-keyed lockout layered ON TOP of the IP limit (additive).- Pure, TDD'd helpers:
normalizeLoginIdentifier,lockDurationSeconds(exponential backoff, capped),evaluateLockout. AccountLockoutclass:status()(read lock TTL),recordFailure()(count viaRatelimit.slidingWindow; engage/extend exponential lock when window exceeded),reset().
- Pure, TDD'd helpers:
- New auth event
login_lockedadded toAuthEventunion (+ failure classification). Closes 1A.1 "no lockout event". - Wire into ERP + MES login actions: check
status(block early), elserecordFailure(block on tip-over), generic non-enumerating message, emitlogin_locked. IP limit and all existing behavior preserved.
Progress
- Ground in real code
- Red→green unit tests for pure helpers + class
-
login_lockedevent - ERP wiring
- MES wiring
- Scoped typecheck / lint / tests
- Runtime/browser proof (UNVERIFIED — needs running stack + redis)
Gates
- see final report