fix(deps): override smol-toml to 1.7.2 for GHSA-7w5x-hrqm-74c2 - #4187
Conversation
markdownlint-cli2 0.23.2 (its latest release) exact-pins smol-toml 1.7.0, which is vulnerable to a denial of service via malformed TOML documents. No upstream release carries the fix yet, so an npm override forces the patched 1.7.2 into the resolved tree. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01KcBf2VNNsVTuiqZ1N5RuCu
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
|
Claude finished @kyle-sexton's task in 3m 44s —— View job Code review complete
Ran
No other issues found — this is a small, well-scoped dependency-override fix with a clear removal condition documented in the PR description. |
|
Claude finished @kyle-sexton's task in 30s —— View job Security review complete
Skip gate applied — no security-relevant surface. The diff is limited to
This is a dependency-version pin that fixes GHSA-7w5x-hrqm-74c2 (moving No security findings for this PR. |
|
Last security-reviewed head: |
|
Claude has reviewed this PR 1 time. The lane skips further automatic reviews after 5; deleting this comment resets the count. |
No related issue: closes Dependabot alert #48 (GHSA-7w5x-hrqm-74c2), which has no tracking issue.
Summary
Dependabot reports one high-severity vulnerability on the default branch:
smol-toml <= 1.7.0is open to a denial of service via malformed TOMLdocuments (GHSA-7w5x-hrqm-74c2). It reaches this repo as a transitive
development dependency of
markdownlint-cli2, the markdown-format hook'srepo-local linter.
Dependabot could not open a bump PR for it:
markdownlint-cli2@0.23.2is itsown latest release and exact-pins
smol-tomlat1.7.0, so no version of theparent resolves the advisory.
Fix
Add an npm
overridesentry pinningsmol-tomlto1.7.2, the patched line(first patched release is
1.7.1), and regenerate the lockfile. The pin staysinside the
1.7.xpatch line the parent selected rather than moving to1.8.0.Remove the override once
markdownlint-cli2depends onsmol-toml >= 1.7.1onits own; until then an exact override would hold back a future parent bump that
requires a newer parser.
Verification
npm install --package-lock-only --ignore-scripts— lockfile resolvessmol-toml@1.7.2; the only changed entries are that package and its integrity hash.npm ci --dry-run --ignore-scripts— clean install resolvessmol-toml 1.7.2.npm audit—found 0 vulnerabilities(was 1 high).npm ci --ignore-scriptsthenmarkdownlint-cli2 README.md—markdownlint-cli2 v0.23.2 (markdownlint v0.41.1),0 issues in 0 files; thelinter loads and runs against the overridden parser.
smol-tomlTOML parse smoke test against the overridden install returns theexpected object, confirming the config-parsing path markdownlint-cli2 uses
still works.
git clone --depth 1of this branch into an emptydirectory, then
npm ci—npm ls smol-tomlreportsmarkdownlint-cli2@0.23.2 -> smol-toml@1.7.2 overridden, andnpm auditreports
found 0 vulnerabilities. Same stateci.yml:1445runs in.npm 11.19.0 does not mirror the
overridesfield into the lockfile's rootpackages[""]entry; it records the override by resolving the tree instead.rm -rf node_modules && npm install --package-lock-onlyreproduces thecommitted lockfile byte-for-byte, and
npm cireadsoverridesfrompackage.jsondirectly, so that field's absence from the lock is npm's ownoutput rather than drift.
Related
🤖 Generated with Claude Code
https://claude.ai/code/session_01KcBf2VNNsVTuiqZ1N5RuCu