## Summary - harden the web runtime with JSON body limits, stricter generation input validation, rate limiting, and trusted Origin/Referer checks for cookie-authenticated mutations - redact password-reset tokens from debug email transport logs and fail closed for unsupported email providers - scope generation idempotency keys per user with a Prisma migration and regression coverage ## Testing - docker build -f infra/docker/web.Dockerfile -t nroxy-web-check . - docker run --rm --entrypoint sh nroxy-web-check -lc "pnpm --filter @nproxy/providers test && pnpm --filter @nproxy/db test && pnpm --filter @nproxy/web test" Closes #14 Closes #7 Closes #8 Co-authored-by: sirily <sirily@git.shararam.party> Reviewed-on: #21
nproxy
Product codebase for a crypto-subscription image gateway.
The repository contains:
- runtime applications and shared packages;
- the agreed system plan and architecture documents;
- operational notes for deployment, Telegram pairing, and provider key rotation;
- directory-scoped instructions so Codex runs implement against the same decisions.
Chosen baseline
- Product: B2C website
- Billing: one monthly plan, paid with crypto through a payment processor
- Model support: starts with
nano_banana - Generation modes: text-to-image and image-to-image
- Infra target: one VPS with Docker Compose
- Admin surfaces: web admin and Telegram bot
- Key management: multiple provider keys with round-robin routing, failover, cooldown, balance tracking, and optional per-key proxy
Main directories
apps/runtime entrypointspackages/shared domain and adapter codedocs/source-of-truth planning documentsinfra/deployment templatesscripts/operational helpers
Read first
docs/plan/system-plan.mddocs/architecture/system-overview.mddocs/ops/deployment.mdCONTRIBUTING.md
Description
Languages
TypeScript
94.5%
JavaScript
3.2%
Dockerfile
2.3%