Repository navigation
Generate Cargo.lock before running the security audit - #1178
Open
ajaysehwal wants to merge 1 commit into
Open
ajaysehwal wants to merge 1 commit into
ajaysehwal wants to merge 1 commit into
Conversation
Since we bumped `rustsec/audit-check` to `v2` in b3fe392, the action no longer generates a lockfile itself. As we don't commit `Cargo.lock`, every scheduled audit run since 2026-04-09 failed with `Couldn't load ./Cargo.lock`, meaning we haven't been notified about any new RUSTSEC advisories since. Here, we fix this by generating the lockfile in a dedicated step before running the audit. This change was prepared with the assistance of AI tools (Claude Code).
|
I've assigned @tnull as a reviewer! |
ajaysehwal
marked this pull request as ready for review
October 18, 2026 16:12
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.
Since we bumped
rustsec/audit-checktov2in b3fe392, the action no longer generates a lockfile itself (v1.4.1 did). As we don't commitCargo.lock(we're a library, see.gitignore), every scheduled run of theSecurity Auditworkflow since 2026-04-09 has failed:
The last 5 scheduled runs all concluded with
failure, and the last successful run was on 2026-04-08. In practice, this means we haven't been notified about any new RUSTSEC advisories for about six months (the last RUSTSEC issue we filed was #836).Here, we fix this by generating the lockfile in a dedicated step before running the audit.
Notes for reviewers
trigger it via
workflow_dispatchand link the run here.dev-only dependencies that currently have no fix, e.g., via the
ldk-node =0.6.2dev-dependency used by the upgrade tests (rustls 0.21,rustls-webpki 0.101,h2 0.3,rustls-pemfile 1.0.4). If that gets too noisy,we could add them to the action's
ignore:input in a follow-up. Happy todo that here instead if preferred.
users get today rather than a pinned lock.
AI disclosure: this change was prepared with the assistance of AI tools (Claude Code).