Repository navigation
fix(deps): pin bitmaps 3.1.0 to clear RUSTSEC-2025-0167 (unsound) - #1588
Conversation
…pins imbl-sized-chunks 0.2 bitmaps has no patched release and upstream is archived. It is reached only via nickel-lang-core -> nickel-lang-vector -> imbl-sized-chunks 0.1, which uses Bitmap solely as SparseChunk's private index map and never calls the unsound TryFrom<&[u8]> / AsMut<[u8]> impls; nickel-lang-vector uses only Chunk. imbl-sized-chunks 0.2.0 drops bitmaps, but nickel (the pinned rev and master) still requires "0.1". Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
|
Navigate logical layers of code changes, visualize relationships, and explore their blast radius. No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Essentials Run ID: ⛔ Files ignored due to path filters (1)
📒 Files selected for processing (1)
Included review availability: Your plan provides up to 5 included reviews per hour; 1 remains after this review. 📝 WalkthroughWalkthroughThe deny configuration now rejects ChangesDependency version ban
Priority: ➖ Normal Estimated code review effort: 1 (Trivial) | ~5 minutes Change: Other Suggested reviewers: Merge Risk: ⚪ Minimal · up to The dependency is pinned outside the advisory range, and the version ban blocks affected upgrades; no actionable merge risk remains. 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
A rabbit checks the crate list twice, Comment |
There was a problem hiding this comment.
Copilot review overview
🟢 Approval recommended
No unresolved review comments remain.
Review effort: Lite
Findings: None
What changed in this PR
Accepts the known unsound bitmaps advisory until Nickel upgrades its dependency.
Changes:
- Adds
RUSTSEC-2025-0167todeny.toml. - Documents reachability, rationale, and removal conditions.
| File | Description |
|---|---|
deny.toml |
Records the accepted transitive advisory risk and dependency upgrade rationale. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
|
Reviewed: 1 finding, none blocking at Address the comments on the diff. Clobber: none: |
RUSTSEC-2025-0167 affects bitmaps >= 3.2.0 (unaffected: < 3.2.0); the unsound TryFrom<&[u8]> / AsMut<[u8]> impls on Bitmap do not exist in 3.1.0. imbl-sized-chunks 0.1.3 requires bitmaps ^3.1.0, so downgrading the lockfile entry is a lockfile-only change. Replace the accept-risk ignore with the pin, and add a [bans] deny for bitmaps >=3.2.0 so a later `cargo update` can't silently bring 3.2.x back. Remove both with the RUSTSEC-2026-0292 ignore once nickel moves to imbl-sized-chunks 0.2, which drops bitmaps. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Summary
Clears
RUSTSEC-2025-0167(bitmapsunsound:Bitmap'sTryFrom<&[u8]>/AsMut<[u8]>can create invalid values) by pinningbitmapsto 3.1.0 inCargo.lock. It no longer needs an advisory ignore.cargo update -p bitmaps --precise 3.1.0changes only thebitmapsentry inCargo.lock(3.2.1 -> 3.1.0). The advisory listspatched = []andunaffected = ["< 3.2.0"], so 3.1.0 is outside the affected range. The two unsound impls (AsMut<[u8]>andTryFrom<&[u8]>insrc/bitmap.rs) exist in 3.2.1 and not in 3.1.0.imbl-sized-chunks0.1.3 requiresbitmaps ^3.1.0, so the pin is compatible.[bans].denyentry{ crate = "bitmaps:>=3.2.0", ... }makescargo deny check bansfail if a latercargo updatebrings 3.2.x back. The comment says to remove it together with theRUSTSEC-2026-0292ignore once nickel moves toimbl-sized-chunks0.2, which dropsbitmaps. Note that cargo-deny'sname@verform matches an exact version only.bitmaps@>=3.2.0is accepted without error but matches nothing, so the guard uses thename:reqform.Why not upgrade nickel instead:
imbl-sized-chunks0.2.0 dropsbitmaps, butnickel-lang-vectorrequiresimbl-sized-chunks = "0.1"both at our pinned nickel rev (21decd29) and on nickelmaster.Context on reachability (supporting only): even on 3.2.1, minimal did not appear to reach the unsound code:
bitmapscomes in only via nickel-lang-core -> nickel-lang-vector -> imbl-sized-chunks 0.1.3.Bitmaponly asSparseChunk's private index map and never calls either unsound API.Chunk, neverSparseChunk.Resolves the dep-drift finding tracked in https://github.com/gominimal/inbox/issues/496
Testing
cargo 1.98.1, cargo-deny 0.20.2:
cargo check --workspace: finished with exit 0.cargo deny check:advisories ok, bans ok, licenses ok, sources ok. The remainingadvisory-not-detectedwarning is the existingRUSTSEC-2026-0009entry.unsound = "all"temporarily added to[advisories], using this branch'sdeny.toml(no RUSTSEC-2025-0167 ignore) and the 3.1.0 lock:advisories ok. For comparison,main(3.2.1, no ignore) gaveerror[unsound] RUSTSEC-2025-0167->advisories FAILED.cargo update -p bitmaps --precise 3.2.1, thencargo deny check bans:Checklist
BREAKING CHANGE:footer present if this is a breaking change (n/a)🤖 Generated with Claude Code
Summary by CodeRabbit