Skip to content

πŸ”§ Move sensitive path markers from lib/ to configΒ #3953

Description

@PierreBrisorgueil

What β€” Shared lib/ hardcodes route vocabulary owned by feature modules.
Why β€” lib/ must stay module-agnostic; hardcoded lists rot silently when a module adds a token-bearing route.

Scope β€” SENSITIVE_PATH_MARKERS = ['reset', 'verify', 'verify-email'] in lib/helpers/redactUrl.js:19 bakes auth/invitations route segments into a shared helper (#3935). Source the list from config (e.g. config.log.sensitivePathMarkers, current values as defaults) so modules and consumers extend it without editing lib/; give SENSITIVE_QUERY_KEYS the same treatment while there. Note the primary redaction path (req.route?.path placeholder) is already generic β€” only the fallback list moves.

Refs: internal audit 2026-07-16, H2. Related: #3951.
Created via /dev:issue

Metadata

Metadata

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions