Repository navigation
Conversation
bytes 1.10.1 and 1.11.0 were RUSTSEC-2026-0007. futures-util 0.3.34 drops pin-utils (RUSTSEC-2026-0441). anyhow, rand, and tokio move to the patched releases those scans reported. The root Cargo.lock is unchanged. The nested locks also record the graph cargo deny resolves from the current path manifests. Co-authored-by: Andrew Brown <lazyxeon@users.noreply.github.com>
cargo audit and cargo deny were resolving the root lock only. scan_cargo_locks.sh discovers locks with git ls-files, including the nested spec that does not match the root file. The policy test fails when a tracked lock is dropped or a scan failure is ignored. Co-authored-by: Andrew Brown <lazyxeon@users.noreply.github.com>
|
Important
This repository does not receive automatic reviews because it has fewer than 10 stars.
|
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. |
There was a problem hiding this comment.
Not a clearance at 5a0e6c5984a26c074a83bde27add96a34fdfd903. The scanner does reach all four tracked locks, and the nested lock updates are what make that pass. Deny does not assert the committed lock.
git diff 7ea1d200d88f9a7df6e7dbe19430082ff85098c4...HEAD -- Cargo.lock is empty. The diff does not touch a hashed crate, deny.toml, or .cargo/audit.toml. No new ignore. No git source and no openssl / openssl-sys in the three nested locks. Registry packages in those locks have checksums. The versions I checked on crates.io are not yanked, and the highest rust-version among them is 1.88 (image 0.25.10, icu_* 2.4.0), under the 1.89.0 pin.
cargo metadata --locked exited 0 for tools/parse_probe, astraweave-ecs/fuzz, and crates/astraweave-blend/fuzz. bash scripts/ci/scan_cargo_locks.sh deny exited 0 (four times advisories ok, bans ok, licenses ok, sources ok) and left the tree clean. bash scripts/ci/scan_cargo_locks.sh audit exited 0 (36, 1149, 171, and 147 crate dependencies). python3 scripts/ci/test_workflow_policy.py exited 0 (40 tests). bash scripts/ci/player_facing_names.sh exited 0.
The parent locks are not clean. cargo audit --file on 7ea1d200's blend and parse_probe locks exits 1 on RUSTSEC-2026-0007 (bytes 1.11.0 and 1.10.1; patched is >= 1.11.1, and this PR has 1.12.1). The same command on the old ecs lock exits 0: anyhow, rand, and tokio are unsound warnings. cargo deny check advisories on the old blend lock exits 1 (bytes). On the old parse_probe lock it exits 1 (RUSTSEC-2026-0190, RUSTSEC-2026-0007, RUSTSEC-2026-0441). On the old ecs lock, without --locked, it rewrites the file and exits 0.
Outside .cargo/audit.toml, the new blend lock warns only on the existing ignores RUSTSEC-2024-0436 (paste 1.0.15) and RUSTSEC-2025-0141 (bincode). cargo tree -p image for the blend fuzz workspace shows image 0.25.10 with features exr, hdr, jpeg, png, rayon and does not link ravif. Root still has image 0.25.8 and tokio 1.53.3. Tokio 1.54.1 is inside the patched range for RUSTSEC-2026-0386 (>= 1.53.3) and is not yanked. That float is wider than the advisory bumps. It is not a second gate failure on the versions above.
git ls-files on git 2.43.0 matches the comment: **/Cargo.lock is the three nested locks, and Cargo.lock is the root file only.
- Head
5a0e6c5984a26c074a83bde27add96a34fdfd903. Required checks were still pending (Cargo Deny Check, Security Audit, Gate, replay hash). Not green. - Commands: policy test exit 0;
scan_cargo_locks.sh denyexit 0;scan_cargo_locks.sh auditexit 0;player_facing_names.shexit 0;cargo metadata --lockedexit 0 on each nested manifest;cargo deny --lockedon the current ecs fuzz manifest exit 0 and on the parent ecs lock exit 1. - Not run: determinism replay (root
Cargo.lockand hashed sources unchanged).aw_trace_sync --check(diff does not touchCLAUDE.md,docs/architecture/, or aCargo.toml). GPU frame budget (not a render change; this host cannot measure the 1660 Ti). - Measurements: not measured.
- Replay hashes: expected unchanged. Root
Cargo.lockmatches7ea1d200. Not re-run. - Deferred issue links: none.
scripts/dev.sh security_audit still runs bare cargo audit / cargo deny check and returns 0 either way. That helper is outside this gate.
Sent by Cursor Automation: ASTRA PR AUDIT AGENT
| fi | ||
| echo "::group::cargo deny ${lock}" | ||
| # Extra args are check options (for example --hide-inclusion-graph). | ||
| cargo deny --manifest-path "$manifest" check "$@" bans sources advisories licenses |
There was a problem hiding this comment.
cargo deny here does not pass --locked, so a stale lock is rewritten and then approved.
I copied astraweave-ecs/fuzz/Cargo.lock from 7ea1d200 over the file in this PR and ran cargo deny --manifest-path astraweave-ecs/fuzz/Cargo.toml check advisories. Exit 0. The only lock change was adding the path package astraweave-profiling 0.4.0. anyhow stayed 1.0.100 and rand stayed 0.9.2, and the command still printed advisories ok. The same command with --locked exits 1 (the lock file ... needs to be updated but --locked was passed) and does not rewrite the file. This PR's ecs lock accepts --locked (exit 0, advisories ok).
The runner discards that rewrite, so the deny job is not a check of the committed bytes. cargo audit --file is. Audit's default exit status does not fail the unsound advisories: the parent ecs lock audits exit 0. A nested lock can drift, deny can rewrite it into a passing graph, and both jobs stay green.
Use cargo deny --locked --manifest-path "$manifest" check "$@" bans sources advisories licenses. --hide-inclusion-graph still belongs to check, which is what aravath-windows.yml passes through. The three nested locks in this PR already satisfy --locked (cargo metadata --locked exited 0 for each). The policy helper below accepts this line without --locked, so the flag needs an assertion or the next deletion will not fail the test.
| else: | ||
| uses_lock = ( | ||
| 'manifest="$(dirname -- "$lock")/Cargo.toml"' in code | ||
| and 'cargo deny --manifest-path "$manifest" check' in code |
There was a problem hiding this comment.
This helper reports full coverage when two substrings are present and the git ls-files specs, minus a quoted grep -v, name every tracked lock. It does not run the script. These edits still produce an empty missing list, so test_every_tracked_cargo_lock_is_scanned stays green:
locks=(Cargo.lock)on the line beforefor lock in "${locks[@]}"cargo audit --file "$lock" "$@" || exit 0- a pipe to
grep -v tools/parse_probe/Cargo.lockwith an unquoted pattern (_GREP_V_REonly matches quotedgrep -v) sort -u | head -n 1sort -u | sed '/fuzz/d'
Replacing the final exit 1 of the Aravath deny retry with exit 0 also yields no cargo_lock_scan_gaps. The mutations this test already performs (drop one pathspec, quoted grep -v, bare cargo audit, || true, continue-on-error) do fail, and the suite exited 0 (40 tests).
The deny arm also matches cargo deny --manifest-path "$manifest" check with or without --locked. The rewrite in the scanner comment is invisible here. scripts/ci/scan_cargo_locks.sh says the policy test fails if a tracked lock is left out. That holds for the cases above only.
There was a problem hiding this comment.
Warning
Copilot couldn't run its full agentic review because it didn't start before the timeout. Make sure your repository has a runner available, or add a copilot-code-review.yml file specifying one with the runs-on attribute. See the docs for more details.
Copilot review overview
5 open issues
This step previously appended a single JSON output fromcargo audit --format json; now it appends… · Newscan_cargo_locks.sh audit --format jsonwill emit non-JSON::group::markers and (because it… · New This regex only matchesgrep -v -E .../grep -v -F ...(with a space), but won’t match common… · Newline.split('#', 1)[0]strips everything after#even when#appears inside quotes (valid in… · Newtracked_cargo_locks()shells out togit ls-files.cargo_lock_scan_gaps()calls it per… · New
What changed in this PR
Updates CI security gates so cargo audit and cargo deny scan every tracked Cargo.lock (root + nested workspaces/fuzz crates), and adds a policy test to prevent regressions.
Changes:
- Add
scripts/ci/scan_cargo_locks.shto discover and scan all tracked lockfiles forauditanddeny. - Update GitHub workflows to call the script instead of scanning only the root lock.
- Extend
scripts/ci/test_workflow_policy.pyto enforce that all tracked lockfiles are scanned and that workflows don’t weaken the gate.
| File | Description |
|---|---|
| scripts/ci/test_workflow_policy.py | Adds policy checks ensuring workflows and the scanner cover every tracked Cargo.lock. |
| scripts/ci/scan_cargo_locks.sh | New shared scanner that iterates all tracked lockfiles and runs cargo audit / cargo deny per lock. |
| docs/current/CI_ARCHITECTURE.md | Updates CI architecture docs to reflect the new shared scanning script usage. |
| .github/workflows/security-audit.yml | Switches security audit jobs to use scan_cargo_locks.sh for deny/audit. |
| .github/workflows/dependency-management.yml | Switches scheduled audits/deny to use the shared scanner (including the json report step). |
| .github/workflows/aravath-windows.yml | Switches Aravath supply-chain job deny/audit invocations to the shared scanner (with retries). |
Review effort: Lite
| echo "### Security Audit Results" >> audit-report.md | ||
| echo '```' >> audit-report.md | ||
| cargo audit --format json >> audit-report.md 2>&1 || true | ||
| bash scripts/ci/scan_cargo_locks.sh audit --format json >> audit-report.md 2>&1 |
| echo "::group::cargo audit ${lock}" | ||
| cargo audit --file "$lock" "$@" | ||
| echo "::endgroup::" |
| r"git\s+ls-files\s+--\s+(?P<specs>(?:'[^']*'|\"[^\"]*\")(?:\s+(?:'[^']*'|\"[^\"]*\"))*)" | ||
| ) | ||
| _GREP_V_RE = re.compile( | ||
| r"grep\s+-v(?:\s+-[EF])?\s+'([^']+)'|grep\s+-v(?:\s+-[EF])?\s+\"([^\"]+)\"" |
| def _uncomment(script: str) -> str: | ||
| kept: list[str] = [] | ||
| for line in script.splitlines(): | ||
| if line.lstrip().startswith("#"): | ||
| continue | ||
| kept.append(line.split("#", 1)[0]) |
| def cargo_lock_scan_gaps(workflow_text: str, scanner_text: str) -> list[str]: | ||
| """Gaps in one workflow. Empty means every audit/deny step scans every lock.""" | ||
| gaps: list[str] = [] | ||
| tracked = tracked_cargo_locks() |
|
Devastation (T3 D-CI + D-DEPS) @
Report: https://cursor.com/agents/bc-5bcea109-f11a-545c-a21c-7cf6c8f36cd0 |




Gate: Cargo Deny Check and Security Audit (cargo-audit) now scan every tracked Cargo.lock.
Fixes #701
Description
cargo auditandcargo denywere resolving the root lock only.tools/parse_probeis its own workspace, and both fuzz crates keep their own locks, so those files never failed the pull-request gate.scripts/ci/scan_cargo_locks.shdiscovers locks withgit ls-files -- '**/Cargo.lock' 'Cargo.lock'. The**/spec matches nested locks only; the root spec is separate. The security-audit jobs, the daily dependency-management audit, and the Aravath supply-chain job all call that script.scripts/ci/test_workflow_policy.pyfails if a trackedCargo.lockis not scanned. The negative case drops the nested pathspec, drops the root pathspec, filters one lock out withgrep -v, replaces the per-lockcargo audit --filewith a barecargo audit, and ignores a failure with|| trueandcontinue-on-error.Lockfiles
Cargo.lock(unchanged)tools/parse_probe/Cargo.lockastraweave-ecs/fuzz/Cargo.lockcrates/astraweave-blend/fuzz/Cargo.lockAdvisories fixed
No new
RUSTSECignore.tools/parse_probe:astraweave-ecs/fuzz:crates/astraweave-blend/fuzz:cargo update -p tokiostopped at unpatched 1.50.0;--precise 1.54.1is the patched release)The nested locks were also refreshed to the graph
cargo denyresolves from the current path manifests (parse_probe gained the url/icu stack; blend fuzz gained the image/rav1e stack, including paste 1.0.15, which is the existing RUSTSEC-2024-0436 ignore). NoCargo.tomldependency was added. The rootCargo.lockis unchanged.Type of change
Security Considerations
Cargo.tomldependency. Newly locked crates are transitive deps the path manifests already required.Report
5a0e6c5984a26c074a83bde27add96a34fdfd903. Required checks have not been reported on this SHA yet.python3 scripts/ci/test_workflow_policy.pyexit 0 (40 tests)bash scripts/ci/scan_cargo_locks.sh auditexit 0bash scripts/ci/scan_cargo_locks.sh denyexit 0 (four timesadvisories ok, bans ok, licenses ok, sources ok)bash scripts/ci/scan_cargo_locks.sh audit --format jsonexit 0bash scripts/ci/player_facing_names.shexit 0git diff --exit-code -- Cargo.lockexit 0Cargo.lockand hashed crates unchanged).aw_trace_sync --check(diff does not touchCLAUDE.md,docs/architecture/, or aCargo.toml). GPU frame budget (not a render change; this host cannot measure the 1660 Ti).Cargo.lockwas not edited.