Avoid returning raw errors from Express error middleware
Express error handlers should not send the err object directly to clients in production paths.
#Metadata
#Why it matters
Returning raw errors leaks stack traces, internal identifiers, and implementation details to attackers.
#Remediation
Log detailed errors server-side and return stable, generic client responses with correlation identifiers.
#Repository path
The generated metadata points to critiq-rules/libs/rules/catalog/rules/typescript/ts.security.express-error-handler-information-disclosure.rule.yaml.