Repository navigation
ci(security): add cargo audit --deny warnings and pnpm audit with SARIF upload - #608
Open
DevJoshhie wants to merge 1 commit into
Open
DevJoshhie wants to merge 1 commit into
DevJoshhie wants to merge 1 commit into
Conversation
…IF upload (DevNiola#408) - Run cargo audit --deny warnings as the fail gate for Rust dependencies - Generate SARIF report from cargo audit JSON output and upload to code scanning - Split pnpm audit into a matrix across apps/web, apps/server, extensions/vscode - Generate SARIF from pnpm audit JSON output per workspace and upload to code scanning - Requires security-events: write permission on audit jobs Closes DevNiola#408
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.
Summary
The security workflow had
cargo auditandpnpm auditjobs but ran without--deny warningsand produced no SARIF output, so advisories in existing lockfiles were not surfaced in GitHub's code-scanning tab. This PR hardens both audit jobs and uploads results as SARIF.What was implemented
Rust audit (
cargo-auditjob)security-events: writepermission to allow SARIF uploadcargo-auditwith thesariffeaturecargo audit --deny warningsas the fail gate — the job fails on any advisory including warningscargo audit --jsonvia a Python scriptcargo-auditcategoryJavaScript audit (
javascript-auditjob)apps/web,apps/server,extensions/vscodepnpm audit --audit-level=highscoped to that workspacepnpm audit --jsonoutputFiles changed
.github/workflows/security.ymlCloses #408