RB
← All projectsRust Bitcoin

rust-bitcoin

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

BitcoinCryptographic librariesNormal
Repository coverage

2289 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.

524security candidates506second-pass queue2193AI analyses
140commits · 30 days
284commits · 60 days
1150commits · 180 days
2046commits · 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
489Strong · 80–100
1083Adequate · 60–79
566Thin · 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 Poelstra21072145089
Tobin C. Harding41566410063
jrakibi944994068
Nick Johnson19121190060
Jamil Lambert, PhD11919116061
satsfy (Renato Britto)381527066
Fmt Bot331431045
Trevor Arjeski111111069
Shing Him Ng31731056
Ismail Daif22622050
Martin Habovstiak28527069
Analysis record

Published AI watches

Last scanned 40 minutes ago

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
Informational 18 AI analysisMessage 91 · Strong
RB Rust Bitcoinrust-bitcoin BitcoinCryptographic libraries

Merge rust-bitcoin/rust-bitcoin#6809: addresses: Add `AddressParams` type and remove most uses of network types

This is a routine API refactoring in the rust-bitcoin library. It introduces a new AddressParams type and replaces most public uses of the older Network/NetworkKind types when creating or validating Bitcoin addresses. There is no security …

No memory-safety issues, cryptographic errors, or input-validation changes observedNo new unsafe blocks, no new dependencies, no new parsing of untrusted dataAPI surface change only: parameter types replaced with semantically equivalent AddressParams
81032b1aby Andrew Poelstra+208−16414 files
No security note in commit
Low 38 AI analysisMessage 100 · Strong
RB Rust Bitcoinrust-bitcoin BitcoinCryptographic libraries

Merge rust-bitcoin/rust-bitcoin#6886: units: preserve original err summing `NumOpResult`

This patch fixes a bug in how rust-bitcoin adds up a list of numeric operation results. Previously, if any item in the list already carried an error (for example, dividing by zero), the summing code would overwrite that error and falsely r…

Error-type confusion / misattribution in arithmetic result aggregationLoss of original failure context across iterator foldPotential for downstream logic to act on wrong `MathOp`/`MathErrorKind`
4af1ee1dby Andrew Poelstra+23−191 file
No security note in commit
Informational 15 AI analysisMessage 100 · Strong
RB Rust Bitcoinrust-bitcoin BitcoinCryptographic libraries

Merge rust-bitcoin/rust-bitcoin#6618: ci: disable fail-fast in weekly rustc update crons

This commit changes two GitHub Actions workflow files used for weekly automated Rust toolchain updates. It adds `fail-fast: false` so that if one branch's update job fails, the other branch jobs continue running instead of all being cancel…

c0a70548by Andrew Poelstra+2−02 files
No security note in commit
Moderate 62 AI analysisMessage 91 · Strong
RB Rust Bitcoinrust-bitcoin BitcoinCryptographic libraries

Merge rust-bitcoin/rust-bitcoin#6884: units: Fix div_by_fee_rate_floor precision

This commit fixes a precision bug in a Rust Bitcoin library function that calculates how much transaction weight a given amount of money can afford at a given fee rate. The old code rounded the fee rate up to a coarser unit (satoshis per k…

Incorrect fee-rate-to-weight conversion leading to understated affordable weightInteger rounding direction (ceil) used as divisor in floor division causing off-by-one or larger precision lossAddition of overflow handling for Weight::MAX
9caad2c1by Andrew Poelstra+23−52 files
Vendor flagged security relevance
Repository ledger

Explore captured commits

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

Security candidatebitcoin: preserve parity for XOnlyPublicKeyby jrakibi · f4e9fcae · Feb 22, 2026 · 1 fileMessage 80 · StrongLow 49Details
Commit message · jrakibi

bitcoin: preserve parity for XOnlyPublicKey

both From impls for XOnlyPublicKey lose parity because they call `from_secp(`,
which defaults to Parity::Even. we now preserve parity by extracting it from
x_only_public_key() instead

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
cryptography-sensitive path
AI analysis · Low 49/100

This commit fixes a bug in how X-only public keys were created from full public keys. An X-only key is just the X coordinate of a point, but a point can have an even or odd Y coordinate (parity). The old code always assumed even parity, which could silently produce the wrong key for odd-parity inputs. The fix preserves the actual parity from the source key.

Security candidateEncapsulate PublicKey and PrivateKeyby Mitchell Bagot · 118b8987 · Feb 20, 2026 · 1 fileMessage 58 · ThinInformational 17Details
Commit message · Mitchell Bagot

Encapsulate PublicKey and PrivateKey

With the previous changes to the PublicKey and PrivateKey types, both
can now be encapsulated to control the scope of access to the inner
fields.

Move PublicKey and PrivateKey to encapsulated module and add them to
the pub use.

58/100 · ThinMessage clarity
✓ Descriptive subject✓ Provides detailed explanatory context
Why it was queued
cryptography-sensitive path
AI analysis · Informational 17/100

This commit is a routine internal code reorganization. It moves the PublicKey and PrivateKey type definitions into a private 'encapsulate' module and re-exports them publicly. The fields were already private before this change, so no new access restrictions are introduced. There is no indication this fixes a security bug or changes behavior visible to users of the library.

Security candidateRemove public access to all fields of PublicKey and PrivateKeyby Mitchell Bagot · 41d946ff · Feb 20, 2026 · 3 filesMessage 73 · AdequateInformational 18Details
Commit message · Mitchell Bagot

Remove public access to all fields of PublicKey and PrivateKey

As with the inner fields, the compressed and network fields of PublicKey
and PrivateKey allows public access for read/write. To allow for
encapsulation, read access should be limited to an accessor function.

Introduce compressed() accessor function for PublicKey and compressed()
and network() accessor functions for PrivateKey. Replace all direct
access to inner fields with use of the accessor functions.

73/100 · AdequateMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context
Why it was queued
cryptography-sensitive pathsigning or wallet path
AI analysis · Informational 18/100

This commit hides the internal fields of two key types (PublicKey and PrivateKey) so outside code can no longer read or change them directly. Instead, it provides read-only accessor methods. This is a normal defensive-coding change that improves encapsulation and makes future misuse less likely, but the commit itself does not fix a known active bug or vulnerability.

Security candidateRemove public access to inner field of PublicKey and PrivateKeyby Mitchell Bagot · 9506d45c · Feb 20, 2026 · 6 filesMessage 73 · AdequateLow 35Details
Commit message · Mitchell Bagot

Remove public access to inner field of PublicKey and PrivateKey

While all construction of PublicKey and PublicKey now goes through the
from_secp constructors, read access to the inner fields are still
commonplace.

Introduce as_inner function for PrivateKey and to_inner for PublicKey
and remove all direct access to the inner fields.

73/100 · AdequateMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context
Why it was queued
cryptography-sensitive pathsigning or wallet path
AI analysis · Low 35/100

This commit hides the internal cryptographic key fields of PublicKey and PrivateKey from outside code, replacing direct access with controlled getter methods. It is a defensive hardening change that reduces the chance future callers will accidentally misuse or mutate the raw secp256k1 keys, but the commit itself does not fix a known exploitable bug.

Security candidateIntroduce from_secp constructors for PublicKey and PrivateKeyby Mitchell Bagot · 2f74f3ea · Feb 20, 2026 · 8 filesMessage 73 · AdequateInformational 18Details
Commit message · Mitchell Bagot

Introduce from_secp constructors for PublicKey and PrivateKey

The PublicKey and PrivateKey types rely on public access to the inner
fields in many places to instantiate the type. Since we wish to
encapsulate the type, this inner access should instead be wrapped
through constructors.

Introduce from_secp, and from_secp_uncompressed constructors and
replace all instantiation of PublicKey and PrivateKey with calls to
these.

73/100 · AdequateMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context
Why it was queued
cryptography-sensitive pathsigning or wallet path
AI analysis · Informational 18/100

This is a routine code cleanup in the rust-bitcoin library. It introduces new constructor functions named from_secp for creating public and private keys, and replaces direct internal field access with calls to those constructors. The old constructors are kept but marked as deprecated. There is no security bug being fixed here; the change is about improving code structure and preparing to hide internal details in the future.

Security candidatehashes: add non_secure_erase for HMAC and HKDFby jrakibi · 5c844315 · Feb 19, 2026 · 3 filesMessage 68 · AdequateLow 30Details
Commit message · jrakibi

hashes: add non_secure_erase for HMAC and HKDF

HKDF and HMAC hold secret data (prk, ipad/opad). we add
non_secure_erase to overwrite it with zeros (same approach as
rust-secp256k1 non_secure_erase)

this is a best-effort to erase secret data, it does not guarantee
that material never remains in memory. the compiler may still copy or move
data to other places in memory.

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 · Low 30/100

This commit adds a best-effort memory-clearing helper for two cryptographic building blocks (HMAC and HKDF) in the rust-bitcoin library. It tries to overwrite secret intermediate data with zeros when those objects are destroyed, but the authors explicitly note this is not a guaranteed security fix because the Rust compiler may still leave copies of the data elsewhere in memory. The change is defensive hardening rather than a fix for a known exploitable bug.

Security candidateSwitch update lock files to cargo-rbmtby Nick Johnson · 77a8454f · Feb 18, 2026 · 2 filesMessage 45 · ThinInformational 15Details
Commit message · Nick Johnson

Switch update lock files to cargo-rbmt

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

This commit is a routine build-maintenance change. It removes an old shell script used to update dependency lock files and switches the project to using a new internal tool called cargo-rbmt for the same task. There is no change to the actual Bitcoin library code, no security fix, and no vulnerability introduced.

Security candidatep2p: Implement `encoding` traits for `HeaderAndShortIds`by rustaceanrob · db23a0aa · Feb 17, 2026 · 1 fileMessage 90 · StrongInformational 24Details
Commit message · rustaceanrob

p2p: Implement `encoding` traits for `HeaderAndShortIds`

The overflow check is preserved in the decoding, which I see was added
recently. Although, I don't claim to fully understand why this implies the
individual differences between indexes also overflow.

Clippy complained about a complex type so I introduced an alias.

90/100 · StrongMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context✓ Explains rationale or failure mode✓ Names security-relevant behavior explicitly
Why it was queued
memory safety
AI analysis · Informational 24/100

This commit adds new encoding and decoding machinery for a Bitcoin compact-block-relay data structure called HeaderAndShortIds. It preserves an existing safety check that prevents the combined number of short transaction IDs and prefilled transactions from overflowing a 16-bit limit. The change is mostly a refactor to use newer generic encoder traits; it does not appear to introduce a new vulnerability, but the author notes they do not fully understand why the overflow check guarantees safety of individual index differences.

Security candidatebitcoin: Replace gated no_std with blanket no_stdby Mitchell Bagot · 3492b305 · Feb 17, 2026 · 18 filesMessage 68 · AdequateInformational 15Details
Commit message · Mitchell Bagot

bitcoin: Replace gated no_std with blanket no_std

Most crates in the repo use no_std with an explicit extern crate std
gated behind a std feature. bitcoin and io do not, instead gating the
no_std behind the absence of a std feature. These should be made
uniform.

Replaced gated no_std with blanket no_std and gated extern std.
Fix imports for std types no longer implicitly available in no_std.

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

This is a routine code cleanup that makes the crate's no_std setup consistent with other crates in the same repository. It does not fix a security bug and does not change behavior for users.

Security candidateRemove parity argument and return on add_tweak and tweak_add_checkby Mitchell Bagot · 7370bd7d · Feb 16, 2026 · 4 filesMessage 73 · AdequateInformational 17Details
Commit message · Mitchell Bagot

Remove parity argument and return on add_tweak and tweak_add_check

The tweak_add_check function currently takes a tweaked_parity argument
for the parity of the tweaked key to be checked. With the introduction
of the parity on XOnlyPublicKey, this parity can be derived directly
and doesn't need to be provided.

Similarly, the parity return from add_tweak can now be incorporated
into the XOnlyPublicKey return value, rather than as a second field
in a 2-tuple.

Remove tweaked_parity argument from tweak_add_check and return only
an XOnlyPublicKey from add_tweak.

73/100 · AdequateMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context
Why it was queued
cryptography-sensitive path
AI analysis · Informational 17/100

This commit is a routine API cleanup in the rust-bitcoin library. It removes an extra 'parity' argument and return value from functions that tweak public keys for Taproot, because the parity information can now be stored directly inside the XOnlyPublicKey type. There is no indication this fixes a security bug; it is a design simplification that may require downstream code to update how it calls these functions.

Security candidateRemove parity argument and rename public_keyby Mitchell Bagot · 5724d3ec · Feb 16, 2026 · 2 filesMessage 68 · AdequateInformational 17Details
Commit message · Mitchell Bagot

Remove parity argument and rename public_key

The public_key function on XOnlyPublicKey doesn't follow the standard
API naming conventions for conversions. Further, with the introduction
of the parity field on the XOnlyPublicKey, it's no longer necessary
to provide the parity when calling.

Remove the parity argument in public_key function and rename to
to_public_key.

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

This commit is a routine API cleanup, not a security fix. It renames a method from `public_key` to `to_public_key` and removes a now-redundant `parity` argument because the parity information is already stored inside the x-only public key object. The code still produces the same public keys; callers just provide the parity in a different way. There is no indication this change fixes a vulnerability.

Security candidateReturn only XOnlyPublicKey from from_keypairby Mitchell Bagot · 7d11f9ba · Feb 16, 2026 · 5 filesMessage 68 · AdequateInformational 18Details
Commit message · Mitchell Bagot

Return only XOnlyPublicKey from from_keypair

The from_keypair function currently returns the XOnlyPublicKey and
associated parity as a 2-tuple. Since parity is now stored on the
XOnlyPublicKey, this can be simplified to an XOnlyPublicKey return
type.

Replace from_keypair return type with a plain XOnlyPublicKey.

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

This commit is a routine API cleanup in the rust-bitcoin library. It changes a function so it returns only the x-only public key, instead of a pair of the key plus its parity bit. The parity information is now stored inside the key object itself, so callers no longer need to handle it separately. There is no security vulnerability here.

Security candidateReturn parity from serialize in XOnlyPublicKeyby Mitchell Bagot · b23e5517 · Feb 16, 2026 · 7 filesMessage 80 · StrongInformational 17Details
Commit message · Mitchell Bagot

Return parity from serialize in XOnlyPublicKey

In order to have sufficient information to completely reconstruct an
XOnlyPublicKey, users now need to know the parity of the key. As such,
we should now return it alongside the raw key bytes from serialize.

Add parity return from serialize in XOnlyPublicKey.

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
cryptography-sensitive pathsigning or wallet path
AI analysis · Informational 17/100

This commit changes the public API of XOnlyPublicKey::serialize() so it now returns both the 32-byte x-only key and its parity bit, instead of just the bytes. All existing callers inside the crate are updated to take only the first element (the bytes) and ignore the parity where it isn't needed. This is a routine API design change to expose extra information for users who need to fully reconstruct a key; it does not fix a bug or close a security hole.

Security candidateIntroduce parity field on XOnlyPublicKeyby Mitchell Bagot · dcd361c4 · Feb 16, 2026 · 1 fileMessage 78 · AdequateInformational 15Details
Commit message · Mitchell Bagot

Introduce parity field on XOnlyPublicKey

As part of the overhaul of XOnlyPublicKey, the parity of the key will
need to be stored on the type. Since we want to retain the
encapsulation on the type, we also need a getter/setter for this new
field.

Introduce a parity field on the XOnlyPublicKey alongside getter and
setter functions. Adjust BIP-341 test json parsing to suit new
XOnlyPublicKey structure.

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

This is a routine internal code refactor in a Bitcoin cryptography library. It adds a 'parity' field (a mathematical property of cryptographic keys) to the XOnlyPublicKey type, along with getter and setter functions. There is no indication this change fixes or introduces a security vulnerability.

Security candidateReplace serde derive with call-through implby Mitchell Bagot · 731cbacd · Feb 16, 2026 · 1 fileMessage 68 · AdequateLow 29Details
Commit message · Mitchell Bagot

Replace serde derive with call-through impl

The existing serde implementation for XOnlyPublicKey derives from the
implementation on the inner type. Once additional data is introduced,
like the parity, XOnlyPublicKey will no longer serialise or
deserialise correctly.

Replace serde derived implementations with manual implementations that
call through to inner type's serde implementations.

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 · Low 29/100

This commit changes how a Bitcoin public-key type is serialized and deserialized when the optional serde feature is enabled. The old code automatically used the inner key type's format, which would break if extra data (such as key parity) is added later. The new code explicitly forwards to the inner type, keeping the wire format stable even as the wrapper type evolves. It is a hardening/preventive change rather than a fix for an active vulnerability.

Security candidateChange new constructor to from_secpby Mitchell Bagot · 34744dae · Feb 16, 2026 · 1 fileMessage 68 · AdequateInformational 20Details
Commit message · Mitchell Bagot

Change new constructor to from_secp

The new constructor on XOnlyPublicKey is poorly named, as it merely
constructs an XOnlyPublic key by wrapping an inner type.

Rename XOnlyPublicKey::new to XOnlyPublicKey::from_secp

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 20/100

This commit simply renames a function from XOnlyPublicKey::new to XOnlyPublicKey::from_secp because the old name was misleading. The underlying behavior is unchanged. There is no security vulnerability or fix here.

Security candidateIntroduce as_inner on XOnlyPublicKeyby Mitchell Bagot · 583c168d · Feb 16, 2026 · 1 fileMessage 58 · ThinInformational 15Details
Commit message · Mitchell Bagot

Introduce as_inner on XOnlyPublicKey

In many cases, we only need a reference to the inner key on an
XOnlyPublicKey. Since XOnlyPublicKey is Copy, fn(self) has a copy
overhead on each use. as_inner, taking &self doesn't have this
overhead.

Introduce an as_inner() function to take &self and return a ref to the
inner secp256k1::XOnlyPublicKey value.

58/100 · ThinMessage clarity
✓ Descriptive subject✓ Provides detailed explanatory context
Why it was queued
cryptography-sensitive path
AI analysis · Informational 15/100

This commit adds a small performance helper method called as_inner() to the XOnlyPublicKey type and switches existing internal code to use it instead of a method that copies the key. There is no security issue here; it is a routine optimization to avoid unnecessary copying.

Security candidate2026-02-15 automated rustfmt nightlyby Fmt Bot · 0a92d080 · Feb 15, 2026 · 24 filesMessage 45 · ThinInformational 15Details
Commit message · Fmt Bot

2026-02-15 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 commit is a routine automated code-formatting run using the nightly version of rustfmt. It only changes whitespace, line breaks, import ordering, and other stylistic details across 24 files. No program logic, security behavior, or public API was changed.

Security candidateaddresses,bip158,crypto: migrate lint settingsby Nick Johnson · 9fedc40b · Feb 13, 2026 · 6 filesMessage 45 · ThinInformational 15Details
Commit message · Nick Johnson

addresses,bip158,crypto: migrate lint settings

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

This commit is a routine housekeeping change that moves lint (code style warning) settings from individual crates to a shared workspace configuration. It does not change any program logic, fix bugs, or alter security behavior.

Security candidateChange hex re-export in bitcoin to stable hexby Mitchell Bagot · 9e5136d6 · Feb 13, 2026 · 24 filesMessage 68 · AdequateInformational 18Details
Commit message · Mitchell Bagot

Change hex re-export in bitcoin to stable hex

As per the repo policy, all exports from bitcoin must be a superset of
those from primitives. This includes crate re-exports. In bitcoin, the
hex re-export exports the unstable v0.3.0 crate, whilst primitives
exports the stable 1.0 crate. Since bitcoin makes extensive use of
unstable hex features, the export should be updated, but both included
as dependencies, like with primitives.

Introduce both hex unstable and hex stable as dependencies for bitcoin
and change re-export to stable hex to match primitives.

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

This commit is a routine internal dependency cleanup. The project had been re-exporting an unstable version of a hex-encoding helper crate, but its policy says the main crate must only re-export stable versions. The change swaps the public re-export to the stable version while keeping the unstable version as a private internal dependency for code that still needs it. There is no security bug being fixed here.

Security candidatehashes: Add cpufeatures for no_std SIMD detectionby jrakibi · 5074a7d1 · Feb 13, 2026 · 4 filesMessage 88 · StrongInformational 19Details
Commit message · jrakibi

hashes: Add cpufeatures for no_std SIMD detection

Currently SIMD requires `std` because we use `is_x86_feature_detected!`
and `is_aarch64_feature_detected!` macros for runtime CPU feature detection.
This means `no_std` users cannot benefit from the performance boost
provided by hardware SHA extensions.

This adds `cpufeatures` crate as an optional dependency.
When enabled, it provides runtime CPU feature detection in `no_std`
environments for both x86/x86_64 and aarch64.

Discussed in https://github.com/rust-bitcoin/rust-bitcoin/issues/5568#issuecomment-3816450830

Update lock files

88/100 · StrongMessage clarity
✓ Descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context✓ Explains rationale or failure mode✓ Links an issue, advisory, or supporting reference
Why it was queued
cryptography-sensitive path
AI analysis · Informational 19/100

This change lets users of the library who don't use the standard Rust library ('no_std' environments, common in embedded or blockchain hardware) benefit from faster SHA-256 hashing via CPU-specific instructions. It adds an optional helper crate that detects CPU features in 'no_std' mode, similar to how the standard library already does it. There is no direct evidence in the commit that this fixes a security vulnerability; it is a performance and portability improvement.

Security candidatebenches: add sha256d benchby jrakibi · 5e813e3f · Feb 11, 2026 · 2 filesMessage 66 · AdequateInformational 15Details
Commit message · jrakibi

benches: add sha256d bench

Add sha256d benchmark and a 64 byte input target to help measure the
optimized-double-sha256 performance for 64 bytes if we implement it
in the future (see https://github.com/rust-bitcoin/rust-bitcoin/issues/5540)

66/100 · AdequateMessage clarity
✓ Descriptive subject✓ Provides detailed explanatory context✓ Links an issue, advisory, or supporting reference
Why it was queued
cryptography-sensitive path
AI analysis · Informational 15/100

This commit only adds a new performance benchmark for the SHA256d hashing function. It does not change any production code, cryptographic logic, or user-facing behavior. There is no security issue.

Security candidatebenches: fix hash benches to measure full hashby jrakibi · 2e12407c · Feb 11, 2026 · 10 filesMessage 76 · AdequateInformational 15Details
Commit message · jrakibi

benches: fix hash benches to measure full hash

The current hash benchmarks create the engine once and then repeatedly call
`engine.input()` on the same engine. This does not measure a full hash
operation per iteration (create engine -> `input()` -> `finalize()`).

The previous benchmark numbers are optimistic, especially for small
inputs, and does not reflect real cost of hashing.

I ran a before/after comparison for sha256:
On master:
- 10 bytes: 9.5514 ns
- 1024 bytes: 532.90 ns
- 65536 bytes: 34.533 us
This PR:
- 10 bytes: 51.360 ns
- 1024 bytes: 553.34 ns
- 65536 bytes: 33.796 us

On small inputs the old benchmark was around 5x too optimistic.
(for larger inputs the difference is small)

Discussed in https://github.com/rust-bitcoin/rust-bitcoin/pull/5604#issuecomment-3866577775

76/100 · AdequateMessage clarity
✓ Descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context✓ Links an issue, advisory, or supporting reference
Why it was queued
cryptography-sensitive path
AI analysis · Informational 15/100

This change only fixes how hash performance is measured in benchmark tests. It does not change any real hashing code that users or applications rely on, so it has no security impact on the library itself.

Security candidateFix PSBT key deserialisation byte sizeby Mitchell Bagot · 65229278 · Feb 9, 2026 · 1 fileMessage 68 · AdequateModerate 50Details
Commit message · Mitchell Bagot

Fix PSBT key deserialisation byte size

The PSBT Key decoding makes an assumption that the key type will always
encoding in a single byte in it's compact form. While this is often
correct, this is not correct according to the spec and may fail in
cases where key type values are large.

Fix the encode and decode implementations on Key to correctly calculate
the type value size to add to the key length size.

68/100 · AdequateMessage clarity
✓ Descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context
Why it was queued
signing boundarysigning or wallet path
AI analysis · Moderate 50/100

This commit fixes a bug in how Partially Signed Bitcoin Transactions (PSBTs) read and write their internal 'key' fields. The old code assumed the key's type number always fits in one byte when encoded as a compact size. That assumption is wrong for large type numbers, so the code could misread the key's length and either reject valid PSBTs or, in the worst case, allocate too much memory. The fix makes the encoder and decoder correctly account for the actual number of bytes the type number occupies.

Security candidatehashes: Test hmac incremental inputby Liam Aharon · 5b713745 · Feb 6, 2026 · 1 fileMessage 86 · StrongInformational 15Details
Commit message · Liam Aharon

hashes: Test hmac incremental input

Issue https://github.com/rust-bitcoin/rust-bitcoin/issues/5601 flagged
sha3-256 did not test or handle incremental input correctly.

While correcting sha3-256 behavior in PR #5604, an audit of all hashing
algorithms was undertaken to check they handle and test incremental
input correctly.

All algorithms passed, except hmac which handled incremental input
correctly but did not test it.

Extends the hmac hashing test suite with incremental input cases.

86/100 · StrongMessage clarity
✓ Descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context✓ Mentions testing or verification✓ Links an issue, advisory, or supporting reference
Why it was queued
cryptography-sensitive path
AI analysis · Informational 15/100

This commit only adds a new test to verify that HMAC hashing still produces the correct result when data is fed in one byte at a time. It does not change any production code, fix a bug, or alter behavior. The existing code already handled incremental input correctly; the change simply adds missing test coverage.