Skip to content

fix(security): redact API key from logs + audit fix dev deps#1931

Merged
ryanio merged 2 commits intomainfrom
fix/security-audit-key-logging-and-deps
Mar 11, 2026
Merged

fix(security): redact API key from logs + audit fix dev deps#1931
ryanio merged 2 commits intomainfrom
fix/security-audit-key-logging-and-deps

Conversation

@ryanio
Copy link
Collaborator

@ryanio ryanio commented Mar 11, 2026

Summary

  • Redact API key from logger outputsrc/api/api.ts was serializing the full req.headers (including X-API-KEY) into the logger. Stripped the key before logging so it doesn't leak to console, log files, or observability tools.
  • npm audit fix — Patched 8 of 10 dev dependency vulnerabilities (ReDoS in minimatch/babel/ajv/brace-expansion/diff, prototype pollution in lodash/js-yaml). The remaining 2 (serialize-javascript via mocha) require a breaking mocha major version upgrade and are left for a separate PR.

Test plan

  • Verify logger output no longer contains X-API-KEY
  • Verify existing tests pass (npm test)
  • Confirm npm audit shows only 2 remaining high-severity issues (mocha/serialize-javascript)

🤖 Generated with Claude Code

ryanio and others added 2 commits March 11, 2026 12:50
The logger serialized the full request headers including X-API-KEY,
which could expose the key in console logs, log files, or
observability tools. Strip the key before logging.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Resolves 8 of 10 dev dependency vulnerabilities (ReDoS in minimatch,
babel, ajv, brace-expansion, diff; prototype pollution in lodash,
js-yaml). Remaining 2 (serialize-javascript via mocha) require a
breaking major version upgrade.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@ryanio ryanio merged commit 1e50e90 into main Mar 11, 2026
7 checks passed
@ryanio ryanio deleted the fix/security-audit-key-logging-and-deps branch March 11, 2026 19:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant