Compare commits

..

1 Commits

Author SHA1 Message Date
Flea Flicker c7007051d7 GRO-2294: Route Optimization security hardening (LOW)
CI / Test (pull_request) Successful in 28s
CI / Lint & Typecheck (pull_request) Successful in 34s
CI / Build & Push Docker Images (pull_request) Successful in 1m28s
Two defense-in-depth fixes from the GRO-2162 feature-level security review:

1. Enforce the documented ?limit cap on POST /api/clients/geocode-batch.
   The handler now clamps limit to GEOCODE_BATCH_MAX_LIMIT (500) after the
   positive-integer check, bounding synchronous request duration and per-request
   external API cost when routeOptimizationProvider = "google".

2. Redact the encrypted googleMapsApiKey from GET /api/admin/settings on both
   the existing-row and auto-create branches. The ciphertext is never needed
   client-side and is now stripped via redactSettings().

Adds route-level tests for the limit clamp (default/passthrough/clamp/floor/
reject) and the settings redaction (both branches). Updates UAT_PLAYBOOK.md
TC-API-2.13a and TC-API-13.1.

Co-Authored-By: Paperclip <noreply@paperclip.ing>
2026-06-09 06:12:42 +00:00

Diff Content Not Available