DATA-12994: add npm audit CI gate for production deps - #35
Open
pragyash258 wants to merge 3 commits into
Open
Conversation
Adds a minimal CI job running 'npm audit --omit=dev --audit-level=high' so high/critical CVEs in the production dependency tree block merges. Scoped to prod deps at high level to match the current clean state.
Addresses Semgrep github-actions-mutable-action-tag findings; matches the SHA-pinning style already used in Semgrep.yml.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Adds a minimal CI workflow (
.github/workflows/npm-audit.yml) that runs:on PRs and pushes to
master/main, so high/critical CVEs in the production dependency tree block merges.Why
DATA-12994 (F-011) flags no automated
npm auditin CI — known-CVE prod deps can sit undetected. This closes the CI-control half of that finding.Scope decisions (deliberately minimal)
--omit=dev— only gates on production deps (what consumers of this published package actually install). The repo's 13 open dev-scope alerts (eslint transitive: lodash/minimatch/js-yaml/etc.) are intentionally out of scope.--audit-level=high— gates on high/critical only. Verified green against the currentmasterlockfile today (sole prod advisory isuuidmedium, below the gate), so it does not break existing PRs.Semgrep.ymlstyle.dependabot.yml— omitted by design. CVE detection is already covered by Dependabot alerts (enabled), and no sibling repo in the fleet uses version-update config.