RB
← All projectsRust Bitcoin

rust-bitcoin

Rust library for Bitcoin data structures, serialization, consensus encoding, and scripts.

BitcoinCryptographic librariesNormal
Repository coverage

2297 commits in the local evidence base

Every captured commit receives deterministic security triage and a separate communication-quality score. Security candidates and broader second-pass signals receive full-patch Ollama analysis.

527security candidates507second-pass queue2197AI analyses
143commits · 30 days
279commits · 60 days
1155commits · 180 days
2045commits · 365 days
Backfill bands
Aug 5 → Feb 6787 seen32 candidatesComplete
Feb 6 → Jun 6878 seen53 candidatesComplete
Jun 6 → Jul 6211 seen15 candidatesComplete
Jul 6 → Aug 5184 seen2 candidatesComplete
Commit communication

Does the history explain itself?

Message quality measures whether a commit identifies its scope, purpose, rationale, testing, and supporting references. It does not change the security-severity score.

66/100 average clarity
496Strong · 80–100
1083Adequate · 60–79
567Thin · 40–59
151Opaque · 0–39
20security candidates with opaque commit messaging
Read the scoring rubric →
Developer activity

Who is changing the project?

Public Git author strings; identities are not independently verified.

DeveloperCommitsCandidatesAnalyzedHigh riskMessage avg.
Mitchell Bagot649193645068
Andrew Poelstra21775149089
Tobin C. Harding41566410063
jrakibi944994068
Nick Johnson19121190060
Jamil Lambert, PhD11919116061
satsfy (Renato Britto)381527066
Fmt Bot331431045
Trevor Arjeski111111069
Shing Him Ng31731056
Ismail Daif22622050
Martin Habovstiak29527068
Analysis record

Published AI watches

Last scanned 49 minutes ago

Informational 19 AI analysisMessage 100 · Strong
RB Rust Bitcoinrust-bitcoin BitcoinCryptographic libraries

Merge rust-bitcoin/rust-bitcoin#6922: Use `try_fold` instead of `fold` in `Sum` impl

This is a code-quality and performance improvement, not a security fix. It changes how the library adds up lists of Bitcoin amounts so that it stops early once an overflow is detected, rather than continuing to process the rest of the list…

No security-relevant signal in commit message or diffRefactor preserves overflow-checking behavior (short-circuits instead of continuing)New API method `NumOpResult::from_result` is a pure inverse of existing `into_result`
86e4d5daby Andrew Poelstra+60−562 files
No security note in commit
Moderate 52 AI analysisMessage 91 · Strong
RB Rust Bitcoinrust-bitcoin BitcoinCryptographic libraries

Merge rust-bitcoin/rust-bitcoin#6893: units: Reject malformed amount strings

This update fixes a bug in how the library reads Bitcoin amount strings like '1.5 BTC'. Previously, certain malformed inputs such as '.', '._', '1_', '1_.0', and '1._0' were incorrectly accepted and treated as valid amounts (often zero), i…

Input validation bypass in amount parserMalformed strings silently parsed as zero or ordinary amountsUnderscore separator placement not enforced
fcb14622by Andrew Poelstra+88−343 files
Vendor flagged security relevance
Low 48 AI analysisMessage 91 · Strong
RB Rust Bitcoinrust-bitcoin BitcoinCryptographic libraries

Merge rust-bitcoin/rust-bitcoin#6921: units: fix div_by_fee_rate_ceil precision

This commit fixes a rounding bug in how the rust-bitcoin library calculates the minimum transaction weight needed to pay a given fee at a given fee rate. The old code rounded the fee rate up too early, which could produce a weight slightly…

Incorrect fee-weight calculation due to premature integer roundingPotential transaction fee shortfall when using div_by_fee_rate_ceilOverflow protection added for Amount::MAX * 4_000_000 intermediate value
b31212e0by Andrew Poelstra+38−82 files
No security note in commit
Informational 15 AI analysisMessage 91 · Strong
RB Rust Bitcoinrust-bitcoin BitcoinCryptographic libraries

Merge rust-bitcoin/rust-bitcoin#6898: Release tracking PR: `consensus-encoding 1.3.0`

This is a routine release-management commit that bumps the version number of the `bitcoin-consensus-encoding` crate from 1.2.0 to 1.3.0 and updates lock files accordingly. It contains no code changes that fix or introduce a security issue.…

0cfc7908by Andrew Poelstra+37−349 files
No security note in commit
Informational 15 AI analysisMessage 96 · Strong
RB Rust Bitcoinrust-bitcoin BitcoinCryptographic libraries

Merge rust-bitcoin/rust-bitcoin#6909: build(deps): bump actions/labeler from 6.2.0 to 7.0.0

This commit updates a GitHub Actions automation tool (actions/labeler) used to automatically tag pull requests with labels. It is a routine dependency version bump from 6.2.0 to 7.0.0, with no indication of a security fix or vulnerability.…

4ed7c068by Andrew Poelstra+1−11 file
No security note in commit
Informational 15 AI analysisMessage 96 · Strong
RB Rust Bitcoinrust-bitcoin BitcoinCryptographic libraries

Merge rust-bitcoin/rust-bitcoin#6910: build(deps): bump actions/checkout from 7.0.0 to 7.0.1

This commit is a routine update to the GitHub Actions checkout tool used by the project's automated workflows. It only changes version numbers in configuration files and does not alter the actual Bitcoin library code that users run. There …

328c4ae9by Andrew Poelstra+37−3717 files
No security note in commit
Informational 15 AI analysisMessage 100 · Strong
RB Rust Bitcoinrust-bitcoin BitcoinCryptographic libraries

Merge rust-bitcoin/rust-bitcoin#6911: build(deps): bump astral-sh/setup-uv from 8.3.2 to 9.0.0

This commit updates a GitHub Actions helper used to install a Python tool called uv, which runs the zizmor security scanner. The change only bumps the pinned version of the helper from 8.3.2 to 9.0.0. The new version's release notes mentio…

No security-relevant signals in commit or upstream release notesDependency bump in CI only, not in library codeNo CVE or advisory referenced
67600795by Andrew Poelstra+2−22 files
No security note in commit
Informational 15 AI analysisMessage 96 · Strong
RB Rust Bitcoinrust-bitcoin BitcoinCryptographic libraries

Merge rust-bitcoin/rust-bitcoin#6912: build(deps): bump github/codeql-action/upload-sarif from 4.37.0 to 4.37.3

This is a routine Dependabot update that changes the pinned version of GitHub's official CodeQL upload-sarif action from 4.37.0 to 4.37.3 in a single CI workflow. The action only uploads static analysis results to GitHub; it does not touch…

b51cec63by Andrew Poelstra+1−11 file
No security note in commit
Informational 15 AI analysisMessage 91 · Strong
RB Rust Bitcoinrust-bitcoin BitcoinCryptographic libraries

Merge rust-bitcoin/rust-bitcoin#6913: build(deps): bump dtolnay/rust-toolchain from 6c977a6ca4077a0ceb28ffbe03f59d46e9ac8772 to 02cb101ec7c40f2c49e1d9714d64511d8e1b74de

This is a routine update to a GitHub Actions helper used to install Rust during automated testing. It only changes the pinned version of the dtolnay/rust-toolchain action in workflow files. There is no change to the actual rust-bitcoin lib…

90330d15by Andrew Poelstra+8−84 files
No security note in commit
Informational 20 AI analysisMessage 100 · Strong
RB Rust Bitcoinrust-bitcoin BitcoinCryptographic libraries

Merge rust-bitcoin/rust-bitcoin#6906: consensus_encoding, primitives: expose exact encoding size for block and transaction

This commit adds a way to ask, in advance, exactly how many bytes a Bitcoin block or transaction will take when serialized. It is a feature addition for the library's encoding system, not a fix for a vulnerability. There is no indication i…

No security-relevant signals in commit message or diffFeature addition: expose exact encoded sizeNo mention of vulnerability, CVE, bug bounty, or security report
1a365d53by Andrew Poelstra+129−1068 files
No security note in commit
Informational 15 AI analysisMessage 88 · Strong
RB Rust Bitcoinrust-bitcoin BitcoinCryptographic libraries

build(deps): bump dtolnay/rust-toolchain

This is a routine update by Dependabot that changes which version of a popular GitHub Action (dtolnay/rust-toolchain) is used to install Rust in automated CI workflows. The commit only updates pinned commit hashes in workflow files; it doe…

a31e0b0eby dependabot[bot]+8−84 files
No security note in commit
Informational 15 AI analysisMessage 93 · Strong
RB Rust Bitcoinrust-bitcoin BitcoinCryptographic libraries

build(deps): bump github/codeql-action/upload-sarif

This is a routine patch-version update of a GitHub-maintained action used only to upload static-analysis results (SARIF files) from a scheduled CI job. The change does not touch any project source code, cryptographic logic, or user-facing …

2cac6e38by dependabot[bot]+1−11 file
No security note in commit
Informational 15 AI analysisMessage 93 · Strong
RB Rust Bitcoinrust-bitcoin BitcoinCryptographic libraries

build(deps): bump astral-sh/setup-uv from 8.3.2 to 9.0.0

This is a routine automated update by Dependabot that changes the pinned version of a GitHub Action used to install a Python tool called 'uv' in two workflow files. The new version is a major release of the setup-uv action itself, but the …

7d7e7269by dependabot[bot]+2−22 files
No security note in commit
Informational 21 AI analysisMessage 100 · Strong
RB Rust Bitcoinrust-bitcoin BitcoinCryptographic libraries

Merge rust-bitcoin/rust-bitcoin#6894: Harden `Copy` policy and apply to all pre-1.0 crates

This commit removes the automatic `Copy` trait from several public error types in the rust-bitcoin library and updates the project's written policy to discourage `Copy` on error types. `Copy` is a Rust trait that lets values be duplicated …

API hardening: removes `Copy` from public error types to preserve future flexibilityPolicy update: docs/policy.md now explicitly discourages `Copy` on error typesNo vulnerability fix: change is defensive/preventive, not reactive to a disclosed issue
457cb9b5by Andrew Poelstra+14−146 files
No security note in commit
Informational 18 AI analysisMessage 96 · Strong
RB Rust Bitcoinrust-bitcoin BitcoinCryptographic libraries

Merge rust-bitcoin/rust-bitcoin#6787: Move `from_script` to `Address` and drop `AddressExt`

This change is a routine code cleanup, not a security fix. It moves a method that converts Bitcoin output scripts into human-readable addresses from a temporary 'extension trait' directly onto the main Address type. The actual conversion l…

ed42dabdby Andrew Poelstra+38−414 files
No security note in commit
Low 35 AI analysisMessage 91 · Strong
RB Rust Bitcoinrust-bitcoin BitcoinCryptographic libraries

Merge rust-bitcoin/rust-bitcoin#6061: Units improvements

This is a routine code-quality and API-expansion pull request for the rust-bitcoin library's 'units' crate. It widens some fee-rate constructors from 32-bit to 64-bit inputs, renames the old 32-bit versions, improves serde error messages, …

API surface change: new u64 fee-rate constructors return NumOpResult to prevent silent overflowRenaming of existing u32 constructors to *_u32 may break downstream callers at compile time (breaking API change)Removal of artificial restriction in from_per_vb allows larger valid inputs
f9460859by Andrew Poelstra+266−12211 files
No security note in commit
Low 49 AI analysisMessage 96 · Strong
RB Rust Bitcoinrust-bitcoin BitcoinCryptographic libraries

Merge rust-bitcoin/rust-bitcoin#6862: units: Preserve error in NumOpResult add and sub

This commit fixes a bug in how the library handles math errors. Previously, if you added or subtracted two values and one of them already had an error (for example, dividing by zero), the library would silently replace that original error …

Error-state information loss in arithmetic wrapper typeIncorrect error propagation could mask prior failures such as division by zeroDefensive correctness fix in numeric operation result handling
5324e59aby Andrew Poelstra+26−41 file
No security note in commit
Low 37 AI analysisMessage 91 · Strong
RB Rust Bitcoinrust-bitcoin BitcoinCryptographic libraries

Merge rust-bitcoin/rust-bitcoin#6896: Fix `cargo audit` findings

This is a routine dependency-maintenance merge that swaps out old, unmaintained helper libraries for newer, patched versions in the project's example embedded programs and benchmark harness. The changes are driven by automated security sca…

cargo audit advisory remediationdependency upgrade for known-vulnerable crate (rand 0.7 / jobserver)dependency upgrade for known-vulnerable crate (crossbeam-epoch)
5f5f666dby Andrew Poelstra+51−1849 files
Vendor flagged security relevance
Low 37 AI analysisMessage 91 · Strong
RB Rust Bitcoinrust-bitcoin BitcoinCryptographic libraries

Merge rust-bitcoin/rust-bitcoin#6897: consensus_encoding: fix overcounting bug in the composite encoders exact size len calculation

This commit fixes a counting bug in a Rust Bitcoin library. The library has combined encoders that bundle multiple pieces of data together. A method called len() is supposed to report how many bytes are left to encode, but it was incorrect…

Violation of documented API contract (ExactSizeEncoder::len)Potential incorrect buffer-size or progress decisions by downstream callersComposite encoder state not fully isolated in size reporting before fix
22bbc326by Andrew Poelstra+19−13 files
No security note in commit
Low 37 AI analysisMessage 73 · Adequate
RB Rust Bitcoinrust-bitcoin BitcoinCryptographic libraries

consensus_encoding: fix bug in the composite encoder's exact size

This commit fixes a bookkeeping bug in a Rust Bitcoin library's composite encoder. The encoder is a tool that combines multiple pieces of data into a single byte stream, and it has a method that is supposed to report how many bytes are lef…

Incorrect implementation of a documented size/length contractPotential for callers to over-allocate buffers or miscompute transaction/witness sizesComposite encoder used in consensus-critical serialization paths
914365b4by Nick Johnson+19−13 files
No security note in commit
Repository ledger

Explore captured commits

Expand any commit for its author, full message, clarity score, changed files, triage signals, analysis, and source link.

Lower-priorityprimitives: move a const to the module levelby Boris Nagaev · 3f10970e · May 27, 2026 · 1 fileMessage 78 · AdequateInformational 15Details
Commit message · Boris Nagaev

primitives: move a const to the module level

Make WITNESS_COMMITMENT_MAGIC a module-level const, not a local const in
a function, reuse it in witness_commitment_from_coinbase_simple test.

78/100 · AdequateMessage clarity
✓ Descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context✓ Mentions testing or verification
AI analysis · Informational 15/100

This commit is a minor code cleanup: it moves a fixed byte pattern (the Bitcoin witness commitment marker) from inside a function to the top of the file so the same constant can be reused in a test. There is no change to behavior, no bug fix, and no security impact.

Lower-priorityprimitives: fix witness commitment check (BIP141)by Boris Nagaev · 16f3ad79 · May 27, 2026 · 1 fileMessage 68 · AdequateModerate 59Details
Commit message · Boris Nagaev

primitives: fix witness commitment check (BIP141)

If a block has a witness commitment, it must also contain exactly one
32-byte witness reserved value EVEN IF no transactions use SegWit.

The commit enforces this check by moving the "there are no transactions
using SegWit" check after the coinbase witness commitment and witness
reserved value checks. Now the check is in line with Bitcoin Core and btcd.

Assisted-by: OpenAI GPT-5

68/100 · AdequateMessage clarity
✓ Descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context
AI analysis · Moderate 59/100

This commit fixes a bug in how the rust-bitcoin library validates witness commitments in Bitcoin blocks. Under BIP141 rules, if a block contains a witness commitment, the coinbase transaction must also contain exactly one 32-byte witness reserved value, even when no other transactions use SegWit. The old code skipped this requirement when no SegWit transactions were present, which could let an invalid block appear valid. The fix moves the 'no SegWit transactions' shortcut after the commitment/reserved-value checks, matching Bitcoin Core and btcd behavior.

Lower-priorityAvoid clone in BIP152 decode testby Julio Cesar · a8643b93 · May 26, 2026 · 1 fileMessage 55 · ThinInformational 15Details
Commit message · Julio Cesar

Avoid clone in BIP152 decode test

55/100 · ThinMessage clarity
✓ Descriptive subject✓ Names a concrete action or component✓ Mentions testing or verification! No meaningful explanatory body
AI analysis · Informational 15/100

This is a minor code cleanup inside a single test file. It removes unnecessary cloning of test data and renames a loop variable for clarity. There is no change to production code, no security fix, and no behavior change.

Lower-prioritychore: remove `act` referencesby Luis Schwab · 4903e44a · May 26, 2026 · 4 filesMessage 47 · ThinInformational 15Details
Commit message · Luis Schwab

chore: remove `act` references

47/100 · ThinMessage clarity
✓ Descriptive subject✓ Uses a recognizable type or scope! No meaningful explanatory body
AI analysis · Informational 15/100

This commit removes leftover configuration that skipped certain GitHub Actions jobs when the workflow was run locally using a tool called 'act'. It is a routine cleanup with no effect on the security of the Bitcoin library code users actually run.

Security candidatebip32: validate master key seed lengthby satsfy (Renato Britto) · 284ed9c8 · May 26, 2026 · 3 filesMessage 68 · AdequateLow 35Details
Commit message · satsfy (Renato Britto)

bip32: validate master key seed length

BIP-32 requires the master seed to be between 16 and 64 bytes, but
new_master accepted any length. bitcoinfuzz flagged this as a
inconsistency on seeds out of range.

Introduce a Bip32Seed type that validates on construction.
new_master now takes a ref to Bip32Seed (a transparent newtype of
&[u8]). Fixed-size arrays go through infallible From<[u8; N]>. Slices
go through TryFrom<&[u8]> returning InvalidSeedLengthError.
`Debug` shows first 4 bytes of seed's sha256. `PartialEq` fixed
time equality comparison based on hashes.

68/100 · AdequateMessage clarity
✓ Descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context
Why it was queued
secret or key materialdefensive validationfuzzing or regression evidencecryptography-sensitive path
AI analysis · Low 35/100

This commit tightens input checking for Bitcoin wallet master-key creation. Previously, the library would accept any seed length when creating a BIP-32 master key, even though the standard only allows seeds between 16 and 64 bytes. Now it validates the length and rejects out-of-range seeds. It also changes how seed bytes are printed in debug logs so the full secret is no longer exposed, and compares seeds in constant time to reduce timing side-channel risk.

Lower-priorityFix fuzz cache key target nameby Julio Cesar · 1f2b59c8 · May 26, 2026 · 2 filesMessage 55 · ThinInformational 15Details
Commit message · Julio Cesar

Fix fuzz cache key target name

55/100 · ThinMessage clarity
✓ Descriptive subject✓ Names a concrete action or component✓ Mentions testing or verification! No meaningful explanatory body
Why it was queued
fuzzing or regression evidence
AI analysis · Informational 15/100

This commit fixes a typo in GitHub Actions workflow cache keys. The cache key was referencing a non-existent matrix variable `matrix.target` instead of the correct `matrix.fuzz_target`. This only affects how fuzzing build artifacts are cached in CI and has no security relevance to the Rust Bitcoin library itself or its users.

Lower-priorityMove Miri CI to a daily cron jobby Jamil Lambert, PhD · be46afd9 · May 26, 2026 · 2 filesMessage 78 · AdequateInformational 15Details
Commit message · Jamil Lambert, PhD

Move Miri CI to a daily cron job

Miri takes hours and rarely completes on a PR. Run it instead on a daily
schedule like fuzz and kani.

Use the same tool to produce an issue when it fails.

78/100 · AdequateMessage clarity
✓ Descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context✓ Mentions testing or verification
Why it was queued
fuzzing or regression evidencedocumentation-only discount
AI analysis · Informational 15/100

This change simply moves an existing automated test (Miri, a Rust memory-safety checker) from running on every pull request to running once per day, like other long-running tests. It does not change any code that users run, and it does not fix or introduce a security bug.

Lower-priorityExplicitly don't support ficticious architecturesby Martin Habovstiak · cf21edad · May 26, 2026 · 1 fileMessage 68 · AdequateInformational 18Details
Commit message · Martin Habovstiak

Explicitly don't support ficticious architectures

Currently, no architecture with `usize` exists in stable or unstable
Rust or anywhere in the world that I (or ChatGPT) know of. Notably,
CHERI has 128 bit **pointers**, but **not** `usize`, which is still 64
bits.

Rather then producing garbage on such platforms it is much cleaner to
flat out not support them. This makes reviews easier to reason about and
removes the WTF factor. And while this appears breaking, it really isn't
becuase since no such platforms exist, nobody could've realied on this
behavior.

If such platforms ever arrive, this crate will be most likely EOL for
millenia but even then there exists upgrade path:

1. release 2.0 which has the `new` method behind a feature flag, off by
default
2. semver-trick the entire 2.0 with `*` import and the feature forced on
3. add `try_new` method that returns `Result`

Then downstream crates that want to support crazy-wide architecture will
just upgrade to 2.0 with the feature deactivated and use the new method.

68/100 · AdequateMessage clarity
✓ Descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context
AI analysis · Informational 18/100

This commit removes a fallback for extremely unusual (and currently non-existent) computer architectures where a memory-size value might be larger than 64 bits. On such hypothetical platforms, the old code would quietly cap the value at the maximum 64-bit number. The new code instead refuses to compile/run on those platforms, because none exist today. For every real platform, the behavior is unchanged.

Lower-priorityHard fail semver breaks for 1.0 cratesby 0xjc65eth · d9423799 · May 26, 2026 · 1 fileMessage 45 · ThinInformational 15Details
Commit message · 0xjc65eth

Hard fail semver breaks for 1.0 crates

45/100 · ThinMessage clarity
✓ Descriptive subject✓ Names a concrete action or component! No meaningful explanatory body
AI analysis · Informational 15/100

This commit updates an internal CI script so that any future pull request introducing backward-incompatible API changes to the already-released 1.0 crate 'bitcoin-consensus-encoding' will cause the automated build to fail. It is a process/guardrail change, not a fix for an active security flaw.

Lower-priorityp2p: refactor: use `take()` instead of `replace()`by yancy · 555a3671 · May 26, 2026 · 1 fileMessage 85 · StrongInformational 13Details
Commit message · yancy

p2p: refactor: use `take()` instead of `replace()`

The replacement value is not used due to the next state transition being
`ReadPayload`. That is, the value used in replace is never used in the
future since the header_decoder is "ready".

85/100 · StrongMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context✓ Explains rationale or failure mode
AI analysis · Informational 13/100

This is a small code cleanup in the Bitcoin peer-to-peer message decoder. It replaces a more verbose pattern that swapped out an internal state object with a simpler one that just takes the current value. The behavior is unchanged because the replaced value was immediately overwritten by the next state transition anyway. There is no security issue here.

Lower-priorityCall low-level `ArrayVec` methods from high-levelby Martin Habovstiak · 3d04756b · May 25, 2026 · 1 fileMessage 80 · StrongLow 27Details
Commit message · Martin Habovstiak

Call low-level `ArrayVec` methods from high-level

The high-level methods on `ArrayVec` should call into the low-level
methods instead of directly accessing the fields so that safety can be
better reasoned about. This modifies the existing high-level methods to
make it so. Notably, it does not modify `from_slice` which is
technically high-level but is also `const` and would require a call into
non-`const` `spare_capacity_mut`.

80/100 · StrongMessage clarity
✓ Descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context✓ Explains rationale or failure mode
AI analysis · Low 27/100

This commit refactors internal helper methods in a fixed-size array type so that the safer, lower-level methods are reused instead of directly touching internal fields. It is a code-quality and safety-clarity improvement rather than a fix for a known exploitable bug. No public security advisory or researcher credit is present.

Lower-priorityMove high-level methods out of safety boundaryby Martin Habovstiak · 512a08f2 · May 25, 2026 · 1 fileMessage 68 · AdequateInformational 12Details
Commit message · Martin Habovstiak

Move high-level methods out of safety boundary

`ArrayVec` was defined inside a `safety_boundary` module to make
soundness review easier. However, multiple high-level methods that could
be implemented by calling into low-level ones were defined inside
`safety_boundary`. This moves them out into a separate impl block.

68/100 · AdequateMessage clarity
✓ Descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context
AI analysis · Informational 12/100

This commit is a code cleanup: it moves several helper methods (push, try_push, pop, extend_from_slice) out of a special 'safety_boundary' module into a normal implementation block. The actual behavior of the code does not change, and no security bug is fixed or introduced. The change is meant to make future safety reviews easier by keeping only truly low-level unsafe code inside the safety boundary.

Lower-priorityAvoid len check in `ArrayVec::spare_capacity_mut`by Martin Habovstiak · 0d9307f2 · May 25, 2026 · 1 fileMessage 68 · AdequateLow 26Details
Commit message · Martin Habovstiak

Avoid len check in `ArrayVec::spare_capacity_mut`

The `ArrayVec` type already has an `unsafe` invariant and the module has
a bunch of `unsafe` anyway, so it makes sense to also rely on the
invariant when it comes to the length, potentially improving
performance.

68/100 · AdequateMessage clarity
✓ Descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context
AI analysis · Low 26/100

This commit changes an internal helper function in the rust-bitcoin library to skip a length safety check using Rust's `unsafe` keyword. The author argues this is safe because the type already relies on an internal invariant that the length never exceeds capacity. The change is small and performance-oriented, but it increases reliance on a manually maintained safety invariant.

Lower-priorityAdd `ArrayVec::set_len`by Martin Habovstiak · 7073cc5c · May 25, 2026 · 1 fileMessage 51 · ThinLow 29Details
Commit message · Martin Habovstiak

Add `ArrayVec::set_len`

Just as `Vec` has `set_len`, this adds an analogous function to
`ArrayVec` allowing the state-manipulating methods to be moved out of
safety boundary.

51/100 · ThinMessage clarity
✓ Subject identifies a change✓ Provides detailed explanatory context
AI analysis · Low 29/100

This commit adds a new low-level helper function called `set_len` to an internal array-like data structure (`ArrayVec`). It is marked `unsafe` and is intended to let other internal code manipulate the length of the array directly, similar to how Rust's standard `Vec::set_len` works. The commit itself does not change any public behavior or fix a known bug; it is a small internal API addition.

AI review queuedAdd `#[track_caller]` to `ArrayVec::push`by Martin Habovstiak · 6d8ad233 · May 25, 2026 · 1 fileMessage 80 · StrongInformational 15Details
Commit message · Martin Habovstiak

Add `#[track_caller]` to `ArrayVec::push`

When `push` panics because of capacity being exceeded it's the caller's
fault for not taking care of it, so using `#[track_caller]` provides a
better panic message.

80/100 · StrongMessage clarity
✓ Descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context✓ Explains rationale or failure mode
Why it was queued
second-pass: broader security terminology
AI analysis · Informational 15/100

This commit adds a Rust compiler annotation to a helper function so that if it ever causes a program crash due to being full, the error message points at the code that called it rather than the helper itself. It does not change what the program does, only the quality of the crash diagnostic. There is no security vulnerability here.

Lower-priorityAdd `ArrayVec::spare_capacity_mut`by Martin Habovstiak · ace24982 · May 25, 2026 · 1 fileMessage 58 · ThinInformational 15Details
Commit message · Martin Habovstiak

Add `ArrayVec::spare_capacity_mut`

We'd like to improve tracking of `ArrayVec`'s invariants and, as a first
step, this commit adds `spare_capacity_mut` method which is modeled
after `Vec` and returns the slice pointing to the unused part of the
array vec.

58/100 · ThinMessage clarity
✓ Descriptive subject✓ Provides detailed explanatory context
AI analysis · Informational 15/100

This commit adds a small helper method to an internal array-backed vector type. It simply exposes the unused portion of the underlying array as a mutable slice of uninitialized memory. There is no security issue visible in the change itself.

Lower-prioritySimplify `ArrayVec::push`by Martin Habovstiak · 1d32b2bc · May 25, 2026 · 1 fileMessage 50 · ThinInformational 15Details
Commit message · Martin Habovstiak

Simplify `ArrayVec::push`

Now that `try_push` exists, `push` can just call into it and call
`expect` on the result.

50/100 · ThinMessage clarity
✓ Descriptive subject✓ Provides an explanatory body
AI analysis · Informational 15/100

This is a small internal code cleanup in the rust-bitcoin library. A function called `push` that adds items to a fixed-size array was rewritten to call a newer helper function (`try_push`) instead of doing the work directly. The behavior is unchanged: it still panics if the array is full, just with a slightly different panic message. There is no security issue here.

Security candidatePromote BLOCK_SIZE assertion to hard assertby Jamil Lambert, PhD · 8f2ee2b8 · May 25, 2026 · 1 fileMessage 68 · AdequateModerate 60Details
Commit message · Jamil Lambert, PhD

Promote BLOCK_SIZE assertion to hard assert

The debug_assert only fires in debug builds; a downstream HashEngine
implementation with BLOCK_SIZE > 128 would silently produce wrong
outputs in release builds by indexing into fixed-size 128-byte ipad/opad
buffers beyond their length.

Change to assert! so the check is unconditional.

Assisted-by: claude-sonnet-4.6

68/100 · AdequateMessage clarity
✓ Descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context
Why it was queued
cryptography-sensitive path
AI analysis · Moderate 60/100

This commit fixes a safety check in the HMAC code. Previously, the code only verified in debug builds that a hash engine's block size did not exceed 128 bytes. In release builds, an oversized block size would cause the code to write past the end of fixed 128-byte internal buffers, leading to incorrect HMAC results or memory corruption. The fix makes this check run unconditionally by changing a debug-only assertion into a regular assertion.

Security candidateIntroduce signing functions on sighash typesby Mitchell Bagot · 3edf875b · May 25, 2026 · 3 filesMessage 73 · AdequateInformational 15Details
Commit message · Mitchell Bagot

Introduce signing functions on sighash types

Although the private key types have raw signing functions on them that
allow users to bypass secp, they still present a rough interface for
signing compared to directly signing on the sighash types that result
from the SighashCache.

Introduce signing functions on LegacySighash, SegwitV0Sighash and
TapSighash.

73/100 · AdequateMessage clarity
✓ Descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context✓ Names security-relevant behavior explicitly
Why it was queued
secret or key materialsigning boundarycryptography-sensitive pathsigning or wallet path
AI analysis · Informational 15/100

This commit adds convenience helper methods that let developers sign Bitcoin transaction hash values more directly. It does not change any security-critical behavior; the same cryptographic signing operations were already available through other functions. The change is purely an API usability improvement.

Security candidateChange TapTweak to take self by refby Mitchell Bagot · 0e0146be · May 25, 2026 · 1 fileMessage 68 · AdequateInformational 19Details
Commit message · Mitchell Bagot

Change TapTweak to take self by ref

The TapTweak trait in bitcoin::key currently consumes the untweaked
key to construct the tweaked key. While this is mostly fine for users
who manually call into it, it prevents clean usage in functions that
take Keypair refs.

Change TapTweak::tap_tweak to take self by ref instead of by value.

68/100 · AdequateMessage clarity
✓ Descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context
Why it was queued
cryptography-sensitive path
AI analysis · Informational 19/100

This is a small API ergonomics change in a Rust Bitcoin library. A function called tap_tweak is changed so callers pass a reference to the key instead of giving up ownership of the key. It does not fix a bug or vulnerability; it makes the library easier to use in code that holds key references.

Lower-prioritydocs: Re-run gen-dep-tree scriptby Tobin C. Harding · 201d178a · May 25, 2026 · 1 fileMessage 72 · AdequateInformational 15Details
Commit message · Tobin C. Harding

docs: Re-run gen-dep-tree script

The doc has gotten a bit stale. Re-run the script (using `just
gen-dep-tree`).

72/100 · AdequateMessage clarity
✓ Descriptive subject✓ Names a concrete action or component✓ Uses a recognizable type or scope✓ Provides an explanatory body
Why it was queued
documentation-only discount
AI analysis · Informational 15/100

This commit only regenerates a documentation file that shows the project's internal dependency tree. No program code was changed, so it cannot introduce or fix a security vulnerability on its own.

Security candidatehashes: Bump version to 0.21.0by Tobin C. Harding · 411e4473 · May 25, 2026 · 12 filesMessage 68 · AdequateInformational 15Details
Commit message · Tobin C. Harding

hashes: Bump version to 0.21.0

In preparation for release add a changelog entry, bump the version,
and update the lock files.

One last release before we 1.0 this crate team.

68/100 · AdequateMessage clarity
✓ Descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context
Why it was queued
cryptography-sensitive path
AI analysis · Informational 15/100

This commit is a routine release-preparation change. It bumps the version number of the `bitcoin_hashes` crate from 0.20.0 to 0.21.0, updates the project's lock files, and adds a changelog entry summarizing prior changes. There is no code change that fixes or introduces a security issue in this commit itself.

Security candidate2026-05-24 automated rustfmt nightlyby Fmt Bot · acaec902 · May 24, 2026 · 10 filesMessage 45 · ThinInformational 15Details
Commit message · Fmt Bot

2026-05-24 automated rustfmt nightly

45/100 · ThinMessage clarity
✓ Descriptive subject✓ Names a concrete action or component! No meaningful explanatory body
Why it was queued
cryptography-sensitive pathsigning or wallet path
AI analysis · Informational 15/100

This is a purely cosmetic code-formatting commit. It only reorders imports, rewraps long lines, and collapses or expands function bodies to match the latest rustfmt nightly style. No program logic, behavior, or security properties were changed.

Lower-prioritybip158: reject malformed filter countsby Boris Nagaev · d4e2383a · May 23, 2026 · 1 fileMessage 68 · AdequateLow 48Details
Commit message · Boris Nagaev

bip158: reject malformed filter counts

Propagate CompactSize decode errors when reading the element count in GCS
filter matching instead of treating malformed input as an empty filter.

Assisted-by: OpenAI GPT-5

68/100 · AdequateMessage clarity
✓ Descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context
AI analysis · Low 48/100

This change fixes how a Bitcoin-related Rust library reads compact-size numbers in BIP158 compact block filters. Previously, if the encoded element count was malformed, the code silently treated it as zero, making the filter look empty. Now it returns an error instead. This could have let an attacker or buggy peer make a node believe a filter contained no matches when in fact the data was just corrupt.

Lower-prioritybip158: add invalid compact size errorby Boris Nagaev · 5bf57f3f · May 23, 2026 · 1 fileMessage 68 · AdequateInformational 15Details
Commit message · Boris Nagaev

bip158: add invalid compact size error

Add a dedicated error variant for invalid CompactSize encoded filter counts.
It will be used in subsequent commit.

Assisted-by: OpenAI GPT-5

68/100 · AdequateMessage clarity
✓ Descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context
AI analysis · Informational 15/100

This commit only adds a new error variant to the BIP158 block filter error type. It does not change any parsing logic, fix a bug, or alter behavior. It is a preparatory code change for a future commit and has no security impact on its own.