LD
← All projectsLedger

Ledger Bitcoin app

Open-source Bitcoin application running on Ledger devices; the device OS is outside this repository.

BitcoinHardware walletsNormal
Repository coverage

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

75security candidates126second-pass queue48AI analyses
59commits · 30 days
82commits · 60 days
231commits · 180 days
301commits · 365 days
Backfill bands
Aug 5 → Feb 670 seen8 candidatesComplete
Feb 6 → Jun 6149 seen21 candidatesComplete
Jun 6 → Jul 623 seen0 candidatesComplete
Jul 6 → Aug 555 seen5 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.

51/100 average clarity
13Strong · 80–100
76Adequate · 60–79
157Thin · 40–59
55Opaque · 0–39
6security 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.
Salvatore Ingala1674827155
Ilya Artemov952620145
github-actions[bot]1711046
Mathias BROUSSET1400040
José Luis Landabaso Díaz400067
iartemov-ledger100043
Cerberus Merlin100062
Charles-Edouard de la Vergne100045
Michael Evans100073
Analysis record

Published AI watches

Last scanned 54 minutes ago

Moderate 59 AI analysisMessage 73 · Adequate
LD LedgerLedger Bitcoin app BitcoinHardware wallets

Type consistency in psbt_parse_rawtx, and some other hardenings

This commit hardens a Bitcoin transaction parser in Ledger's app. It changes some numeric fields to safer types, adds bounds checks on transaction counts and sizes, rejects extra trailing bytes after a transaction, checks a previously-igno…

Integer type narrowing and sentinel change from -1 to SIZE_MAXBounds checks before uint64_t to unsigned int castsReturn value of parser_consolidate_buffers now checked
1af86279by Salvatore Ingala+66−173 files
No security note in commit
Informational 21 AI analysisMessage 78 · Adequate
LD LedgerLedger Bitcoin app BitcoinHardware wallets

Display total amount of external inputs when reliable

This commit changes what information the Ledger Bitcoin app shows on its screen when signing a transaction that includes 'external inputs'—coins the user did not provide and whose amounts the device cannot independently verify. Previously …

UI/UX hardening: additional contextual data shown for transactions with unverified external inputsNo change to cryptographic checks, sighash validation, or input verificationExternal inputs warning is preserved; new data is displayed only when the input set is closed (no ANYONECANPAY)
26f631c5by Salvatore Ingala+126−174 files
No security note in commit
Informational 15 AI analysisMessage 50 · Thin
LD LedgerLedger Bitcoin app BitcoinHardware wallets

Trustworthy sign_psbt amount/fee display for non-default sighash: snapshots

This commit only updates test screenshot snapshots for the Ledger Bitcoin app. It does not change any application source code, so it cannot directly fix or introduce a security vulnerability in the shipped app. The snapshots reflect new ex…

No source-code changes in the commitOnly test snapshot images (PNG) are modified or addedCommit title references trustworthy amount/fee display for non-default sighash, suggesting a prior functional change exists elsewhere
086967aeby github-actions[bot]+0−0840 files
No security note in commit
Informational 12 AI analysisMessage 60 · Adequate
LD LedgerLedger Bitcoin app BitcoinHardware wallets

Trustworthy sign_psbt amount/fee display for non-default sighash: integration tests

This commit only adds and updates automated integration tests for the Ledger Bitcoin app. It does not change the app's actual signing code. The tests verify that the device now shows clearer, more trustworthy on-screen amount and fee infor…

No C/device firmware code changesTest-only commit adjusting UI navigation expectationsNew tests assert that negative fees are rejected for default sighash but allowed/relabeled for ANYONECANPAY sighash
bb6a6aadby Ilya Artemov+175−325 files
No security note in commit
Informational 12 AI analysisMessage 60 · Adequate
LD LedgerLedger Bitcoin app BitcoinHardware wallets

Trustworthy sign_psbt amount/fee display for non-default sighash: unit-tests

This commit only adds new automated unit tests for functions that decide how transaction amounts and fees are displayed on a Ledger device when signing a Bitcoin transaction with non-standard signature hash (sighash) modes. It does not cha…

Commit title references trustworthy amount/fee display for non-default sighash, a historically sensitive area in hardware-wallet signing UITests cover sighash commitment semantics (SIGHASH_NONE, SIGHASH_SINGLE, SIGHASH_ANYONECANPAY combinations) that directly affect what outputs a signature commits toNo functional code changes in this commit; only unit-test additions
d44e34ddby Ilya Artemov+102−01 file
No security note in commit
Moderate 59 AI analysisMessage 50 · Thin
LD LedgerLedger Bitcoin app BitcoinHardware wallets

Trustworthy sign_psbt amount/fee display for non-default sighash: implementation

This commit changes how the Ledger Bitcoin app shows transaction amounts and fees on the device screen when a user signs a transaction that does not use the normal 'sign everything' rule (a so-called non-default sighash). Previously the ap…

UI trust reduction for non-default sighash prevents misleading fee/amount displaySighash classification helpers centralize ANYONECANPAY/NONE/SINGLE semanticsMixed-sighash detection disables coherent amount display
d4525576by Ilya Artemov+451−6612 files
No security note in commit
Informational 11 AI analysisMessage 68 · Adequate
LD LedgerLedger Bitcoin app BitcoinHardware wallets

Remove initial search for sentinel

This commit is a small code cleanup in the Ledger Bitcoin app. It removes an initial loop that counted commands and instead checks for the end marker directly while processing. The author says the old loop was unnecessary and caused a harm…

Commit message explicitly frames the change as removing a redundant scan and a static-analysis false positive, not as a security fix.No change to parsing, cryptography, authorization, or transaction semantics.Functional behavior for valid command lists is equivalent before and after the patch.
0ae87d9cby Salvatore Ingala+99−1051 file
No security note in commit
Informational 19 AI analysisMessage 65 · Adequate
LD LedgerLedger Bitcoin app BitcoinHardware wallets

Add support for generating PSBTs for MuSig2 in txmaker

This commit adds test-only helper code for creating Bitcoin transaction fixtures that support newer wallet types (MuSig2 multi-signature and several legacy/wrapped SegWit descriptor forms). It is not a change to the Ledger app firmware its…

No security-relevant signal: change is in test utilities onlyAdds cryptographic helper for MuSig2 key aggregation in test fixturesAdds P2SH/P2SH-P2WPKH/P2SH-P2WSH script generation in test fixtures
13d84acaby Salvatore Ingala+211−112 files
No security note in commit
Informational 15 AI analysisMessage 75 · Adequate
LD LedgerLedger Bitcoin app BitcoinHardware wallets

Link unit tests with speculos implementations of crypto syscalls

This commit is purely about improving the project's automated test setup. It links unit tests to a software simulator (Speculos) so cryptographic code can be tested on a regular computer without a physical Ledger device. It adds tests for …

53a997c6by Salvatore Ingala+747−296 files
No security note in commit
Informational 15 AI analysisMessage 60 · Adequate
LD LedgerLedger Bitcoin app BitcoinHardware wallets

Get rid of SKIP_FOR_CMOCKA; compile tests with the speculos bridge

This commit is purely a testing infrastructure cleanup. It removes a workaround called SKIP_FOR_CMOCKA that previously hid parts of the code from unit tests, and instead compiles those parts using a more realistic emulator bridge (speculos…

c098c659by Salvatore Ingala+37−8210 files
No security note in commit
Informational 15 AI analysisMessage 70 · Adequate
LD LedgerLedger Bitcoin app BitcoinHardware wallets

Move some duplicated mocking code to headers

This commit is a routine cleanup of the project's unit-test code. It removes duplicate mock implementations of a small helper function called `pic()` from 14 test files and places a single shared version in a mock header. The change only a…

3ac25325by Salvatore Ingala+4−9415 files
No security note in commit
Informational 14 AI analysisMessage 60 · Adequate
LD LedgerLedger Bitcoin app BitcoinHardware wallets

Add utilities to parse serialized PSBTs and mock its maps; added unit tests for extract_bip32_derivation

This commit only adds new unit-test helper code and test cases. It does not change the actual Ledger Bitcoin app that runs on the device, nor does it fix or alter any production security logic. The new files parse PSBT data and mock dispat…

No production code changesNo device-side code changesNo cryptographic or parsing logic changes in the shipped app
e7453297by Salvatore Ingala+890−07 files
No security note in commit
Informational 13 AI analysisMessage 73 · Adequate
LD LedgerLedger Bitcoin app BitcoinHardware wallets

Improve signing performance in case of several internal keys

This commit is a performance optimization for the Ledger Bitcoin app. It reorders nested loops in two signing-related functions so that the app reads each transaction input's data once and then processes all relevant internal keys, rather …

No security-relevant behavior change identified in commit message or diffRefactoring only: loop reordering with identical helper invocationsPer-input taptree hash now computed once instead of once per key, reducing redundant computation
1d2a4341by Salvatore Ingala+128−891 file
No security note in commit
Informational 15 AI analysisMessage 83 · Strong
LD LedgerLedger Bitcoin app BitcoinHardware wallets

Ensure the version of the transaction is 2 for all e2e tests

This commit only changes automated test files. It forces the test transactions to use Bitcoin transaction version 2 so that a test helper called combinepsbt works correctly. There is no change to the actual Ledger app code that users run, …

0dd48467by Salvatore Ingala+8−04 files
No security note in commit
Informational 15 AI analysisMessage 60 · Adequate
LD LedgerLedger Bitcoin app BitcoinHardware wallets

Partition sign_psbt.c into smaller submodules

This commit is a large but purely structural code cleanup: it splits the single large sign_psbt.c file into many smaller, focused source files under src/handler/sign_psbt/. The actual logic, function bodies, validation checks, and security…

Large-scale code movement only; no new security checks or relaxed validationsFunctions moved verbatim; logic preservedCopyright year updated from 2025 to 2025, 2026
64c53b1aby Salvatore Ingala+2912−214228 files
No security note in commit
Informational 15 AI analysisMessage 73 · Adequate
LD LedgerLedger Bitcoin app BitcoinHardware wallets

Partition init_global_state into smaller functions

This commit is a straightforward internal code cleanup: it splits one large function into three smaller, well-documented helper functions and moves one data field into a shared state structure. There is no change to what the code checks, a…

b0b6a1adby Salvatore Ingala+145−922 files
No security note in commit
Informational 15 AI analysisMessage 45 · Thin
LD LedgerLedger Bitcoin app BitcoinHardware wallets

Add account context struct in sign_psbt

This commit is a straightforward internal code cleanup in Ledger's Bitcoin app. It groups several pieces of wallet-policy data into a new 'account context' structure and updates all references accordingly. There is no change to how transac…

b7061e13by Salvatore Ingala+104−823 files
No security note in commit
Informational 18 AI analysisMessage 85 · Strong
LD LedgerLedger Bitcoin app BitcoinHardware wallets

Generalize return value of sign_psbt in the Rust client

This commit is a routine API update for the Ledger Bitcoin app's Rust client library. It changes what kind of data the library returns when a user signs a Bitcoin transaction (PSBT), so it can also return MuSig2 multi-signature material (p…

dd9e3409by Salvatore Ingala+469−708 files
No security note in commit
Informational 15 AI analysisMessage 55 · Thin
LD LedgerLedger Bitcoin app BitcoinHardware wallets

Add sign_psbt test for MuSig round 1 and 2

This commit only adds new test cases for an existing feature (MuSig multi-signature signing) in the Rust client test suite. It does not change any production code, cryptographic logic, or application behavior. The changes are purely in tes…

a3120ecaby Salvatore Ingala+1103−492 files
No security note in commit
Low 26 AI analysisMessage 80 · Strong
LD LedgerLedger Bitcoin app BitcoinHardware wallets

Add support for "musig()" in the rust client

This commit adds code to the Ledger Bitcoin app's Rust client that pre-processes wallet descriptors containing 'musig(...)' key groups before computing addresses. It implements a small BIP-327/BIP-328 key aggregation so the existing minisc…

New cryptographic key aggregation implementation (BIP-327 KeyAgg)Parsing of untrusted descriptor strings with manual `musig(...)` extractionUse of a hardcoded BIP-328 chain code constant
244d6027by Salvatore Ingala+212−04 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.

Security candidateAdd utilities to parse serialized PSBTs and mock its maps; added unit tests for extract_bip32_derivationby Salvatore Ingala · e7453297 · May 19, 2026 · 7 filesMessage 60 · AdequateInformational 14Details
Commit message · Salvatore Ingala

Add utilities to parse serialized PSBTs and mock its maps; added unit tests for extract_bip32_derivation

60/100 · AdequateMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Mentions testing or verification! No meaningful explanatory body
Why it was queued
secret or key materialsigning boundarycryptography-sensitive pathsigning or wallet path
AI analysis · Informational 14/100

This commit only adds new unit-test helper code and test cases. It does not change the actual Ledger Bitcoin app that runs on the device, nor does it fix or alter any production security logic. The new files parse PSBT data and mock dispatcher responses so developers can test the existing `extract_bip32_derivation` function in isolation. Nothing here is shipped to users or reachable by an attacker.

Security candidateMove some duplicated mocking code to headersby Salvatore Ingala · 3ac25325 · May 19, 2026 · 15 filesMessage 70 · AdequateInformational 15Details
Commit message · Salvatore Ingala

Move some duplicated mocking code to headers

These lines where was also confusing gcov coverage measurements;
this should address it.

70/100 · AdequateMessage clarity
✓ Descriptive subject✓ Names a concrete action or component✓ Provides an explanatory body✓ Mentions testing or verification
Why it was queued
cryptography-sensitive pathsigning or wallet path
AI analysis · Informational 15/100

This commit is a routine cleanup of the project's unit-test code. It removes duplicate mock implementations of a small helper function called `pic()` from 14 test files and places a single shared version in a mock header. The change only affects test code, not the actual Ledger Bitcoin app that runs on devices. The commit message says the cleanup was done to fix confusing code-coverage measurements. There is no indication this fixes a security vulnerability or changes how the app behaves.

Security candidateAdd initial mock for the dispatcher, and tests for get_preimageby Salvatore Ingala · 5ac1ec68 · May 19, 2026 · 8 filesMessage 60 · AdequateTriage 15Details
Commit message · Salvatore Ingala

Add initial mock for the dispatcher, and tests for get_preimage

60/100 · AdequateMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Mentions testing or verification! No meaningful explanatory body
Why it was queued
cryptography-sensitive path
Security candidateImprove signing performance in case of several internal keysby Salvatore Ingala · 1d2a4341 · May 11, 2026 · 1 fileMessage 73 · AdequateInformational 13Details
Commit message · Salvatore Ingala

Improve signing performance in case of several internal keys

Instead of structuring the sign_transaction and (musig2 pubnonces)
functions as iterating:

for all internal keys:
for all inputs:
<do stuff>

we reverse the nested loop to:

for all inputs
for all internal keys:
<do stuff>

This avoids processing all the psbt keys for the inputs once for
every key placeholder (running it instead once per input), with
no functional change.

73/100 · AdequateMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context
Why it was queued
signing boundarysigning or wallet path
AI analysis · Informational 13/100

This commit is a performance optimization for the Ledger Bitcoin app. It reorders nested loops in two signing-related functions so that the app reads each transaction input's data once and then processes all relevant internal keys, rather than re-reading the input data once per key. The commit message and diff show no functional change—only a reduction in redundant work.

Security candidateEnsure the version of the transaction is 2 for all e2e testsby Salvatore Ingala · 0dd48467 · May 7, 2026 · 4 filesMessage 83 · StrongInformational 15Details
Commit message · Salvatore Ingala

Ensure the version of the transaction is 2 for all e2e tests

Some of the psbts generated in the test suite had nVersion = 1,
which made combinepsbt fail (since changing the nVersion results
in a different sighash).

83/100 · StrongMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context✓ Mentions testing or verification
Why it was queued
signing boundary
AI analysis · Informational 15/100

This commit only changes automated test files. It forces the test transactions to use Bitcoin transaction version 2 so that a test helper called combinepsbt works correctly. There is no change to the actual Ledger app code that users run, and no security fix or vulnerability is present in the diff.

Security candidatePartition init_global_state into smaller functionsby Salvatore Ingala · b0b6a1ad · Apr 24, 2026 · 2 filesMessage 73 · AdequateInformational 15Details
Commit message · Salvatore Ingala

Partition init_global_state into smaller functions

Parsing the APDU, loading and verifying the wallet policy, and
parsing the global psbt map can be separated into independent
functions for simplicity.

73/100 · AdequateMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context
Why it was queued
signing boundarysigning or wallet path
AI analysis · Informational 15/100

This commit is a straightforward internal code cleanup: it splits one large function into three smaller, well-documented helper functions and moves one data field into a shared state structure. There is no change to what the code checks, accepts, or rejects. It does not fix a bug or add a security feature.

Security candidateAdd account context struct in sign_psbtby Salvatore Ingala · b7061e13 · Apr 24, 2026 · 3 filesMessage 45 · ThinInformational 15Details
Commit message · Salvatore Ingala

Add account context struct in sign_psbt

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

This commit is a straightforward internal code cleanup in Ledger's Bitcoin app. It groups several pieces of wallet-policy data into a new 'account context' structure and updates all references accordingly. There is no change to how transactions are validated, signed, or shown to the user, and no security bug is fixed or introduced in the visible diff.

Security candidatePartition sign_psbt.c into smaller submodulesby Salvatore Ingala · 64c53b1a · Apr 24, 2026 · 28 filesMessage 60 · AdequateInformational 15Details
Commit message · Salvatore Ingala

Partition sign_psbt.c into smaller submodules

Also, updated the copyright notices, or added where missing.

60/100 · AdequateMessage clarity
✓ Descriptive subject✓ Names a concrete action or component✓ Provides an explanatory body
Why it was queued
signing boundarycryptography-sensitive pathsigning or wallet path
AI analysis · Informational 15/100

This commit is a large but purely structural code cleanup: it splits the single large sign_psbt.c file into many smaller, focused source files under src/handler/sign_psbt/. The actual logic, function bodies, validation checks, and security-sensitive operations appear to be moved verbatim into the new modules, with only minor header/include adjustments and copyright-notice updates. There is no indication of a behavior change, bug fix, or security patch.

Security candidateParse unknown yielded tags in python client for sign_psbtby Salvatore Ingala · 027541a4 · Apr 23, 2026 · 3 filesMessage 73 · AdequateTriage 18Details
Commit message · Salvatore Ingala

Parse unknown yielded tags in python client for sign_psbt

This allows future-proofing the client by returning an explicit
unknown yielded value (that can safely be logged/ignored) instead
of returning an incorrect enormous 'input index'.

The Rust client uses the same approach.

73/100 · AdequateMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context
Why it was queued
signing boundary
Security candidateGeneralize return value of sign_psbt in the Rust clientby Salvatore Ingala · dd9e3409 · Apr 23, 2026 · 8 filesMessage 85 · StrongInformational 18Details
Commit message · Salvatore Ingala

Generalize return value of sign_psbt in the Rust client

In order to support returning pubnonces and partial signatures for
Musig2 support, the objrects returned in sign_psbt are generalized
from PartialSignature to a SignPsbtYieldedObject enum.
This is a breaking change, therefore it requires a major release.

85/100 · StrongMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context✓ Explains rationale or failure mode
Why it was queued
signing boundarysigning or wallet pathparser or protocol path
AI analysis · Informational 18/100

This commit is a routine API update for the Ledger Bitcoin app's Rust client library. It changes what kind of data the library returns when a user signs a Bitcoin transaction (PSBT), so it can also return MuSig2 multi-signature material (public nonces and partial signatures) in addition to ordinary signatures. The commit message explicitly calls this a breaking change that requires a major release. There is no indication of a security bug being fixed or introduced.

Security candidateAdd sign_psbt test for MuSig round 1 and 2by Salvatore Ingala · a3120eca · Apr 23, 2026 · 2 filesMessage 55 · ThinInformational 15Details
Commit message · Salvatore Ingala

Add sign_psbt test for MuSig round 1 and 2

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

This commit only adds new test cases for an existing feature (MuSig multi-signature signing) in the Rust client test suite. It does not change any production code, cryptographic logic, or application behavior. The changes are purely in test files: extending the test harness to check two new kinds of returned data (public nonces and partial signatures) and adding recorded device communication data for two MuSig signing scenarios. There is no indication of a security fix or vulnerability.

Security candidateAdd support for "musig()" in the rust clientby Salvatore Ingala · 244d6027 · Apr 21, 2026 · 4 filesMessage 80 · StrongLow 26Details
Commit message · Salvatore Ingala

Add support for "musig()" in the rust client

Since rust-miniscript currently doesn't support musig() key
expressions, it cannot be used for the calculation of addresses
for such wallet policies in the client.

Similarly to the python client, this implements the minimal code
for BIP327- and BIP328-complient key aggregation, in order to
replace musig() with the corresponding synthetic xpub, before
computing the address using rust-miniscript.

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
secret or key materialcryptography-sensitive path
AI analysis · Low 26/100

This commit adds code to the Ledger Bitcoin app's Rust client that pre-processes wallet descriptors containing 'musig(...)' key groups before computing addresses. It implements a small BIP-327/BIP-328 key aggregation so the existing miniscript library can still parse the descriptor. It is a feature addition, not a reported vulnerability fix, but any new cryptographic code can introduce bugs that could cause wrong addresses or, in the worst case, weaken security if implemented incorrectly.

Security candidateImprove tests for replace_musigsby Salvatore Ingala · 25e77a99 · Apr 21, 2026 · 1 fileMessage 68 · AdequateTriage 15Details
Commit message · Salvatore Ingala

Improve tests for replace_musigs

- use the canonical /<0;1>/* derivation steps
- add a test with empty musig
- add a test with two separate musig() expressions

68/100 · AdequateMessage clarity
✓ Descriptive subject✓ Provides detailed explanatory context✓ Mentions testing or verification
Why it was queued
cryptography-sensitive path
Security candidateFail immediately on overflow before converting from uint64_t to uint32_tby Salvatore Ingala · cd8d3178 · Apr 13, 2026 · 2 filesMessage 55 · ThinModerate 61Details
Commit message · Salvatore Ingala

Fail immediately on overflow before converting from uint64_t to uint32_t

55/100 · ThinMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Names security-relevant behavior explicitly! No meaningful explanatory body
Why it was queued
memory safety
AI analysis · Moderate 61/100

This commit fixes two spots in Ledger's Bitcoin app where a very large 64-bit number could be silently truncated to a smaller 32-bit number. After the truncation, the app would treat a huge requested data length as a small one, which could let an attacker read memory beyond what was intended or behave in unexpected ways. The fix now checks for overflow and fails immediately before the conversion happens.

Security candidateGuard against sizes that do not fit in an intby Salvatore Ingala · e4012c72 · Apr 13, 2026 · 1 fileMessage 45 · ThinModerate 58Details
Commit message · Salvatore Ingala

Guard against sizes that do not fit in an int

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 · Moderate 58/100

This commit adds a safety check in the Ledger Bitcoin app's code that handles BIP32 derivation paths extracted from a PSBT (Partially Signed Bitcoin Transaction). The change prevents a very large, attacker-chosen data length from being silently truncated when converted from a large unsigned integer (size_t) to a signed integer (int). Such truncation could theoretically cause the app to allocate or read/write the wrong amount of memory, potentially leading to crashes or memory corruption. The patch is narrow and defensive, but it does not show a complete exploit path.

Security candidateZero output buffer for signatures on errorsby Salvatore Ingala · 1509119c · Mar 27, 2026 · 1 fileMessage 45 · ThinModerate 58Details
Commit message · Salvatore Ingala

Zero output buffer for signatures on errors

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

This commit fixes a security-sensitive cleanup bug in the Ledger Bitcoin app's signing code. When a cryptographic signing operation failed, the output buffer that would normally hold the signature was not being cleared. That means a partially computed or leftover value could be returned to the caller instead of a valid signature. The fix wipes the buffer to zero whenever an error occurs, ensuring no misleading or exploitable signature-like data is produced.

Security candidateAdd missing bound check in fpt_der_data_callbackby Salvatore Ingala · e92bc067 · Mar 27, 2026 · 1 fileMessage 45 · ThinModerate 60Details
Commit message · Salvatore Ingala

Add missing bound check in fpt_der_data_callback

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 · Moderate 60/100

This commit fixes a missing safety check in the Ledger Bitcoin app when reading BIP32 derivation data from a PSBT (Partially Signed Bitcoin Transaction). For non-Taproot transactions, the app was not verifying that the derivation data was not longer than the maximum supported size before copying it into a fixed-size internal buffer. This could allow a malicious or malformed PSBT to overflow that buffer, potentially corrupting memory and affecting the device's behavior during transaction signing.

Security candidateValidate output index (if given) in psbt_parse_rawtxby Salvatore Ingala · 2330334b · Mar 27, 2026 · 1 fileMessage 50 · ThinModerate 58Details
Commit message · Salvatore Ingala

Validate output index (if given) in psbt_parse_rawtx

50/100 · ThinMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component! No meaningful explanatory body
Why it was queued
signing boundarydefensive validationsigning or wallet path
AI analysis · Moderate 58/100

This commit adds a safety check in the Ledger Bitcoin app's code that parses raw transactions from PSBT data. Before finalizing, it now verifies that if the caller asked for a specific transaction output by index, that output actually exists. Without this check, the code could have proceeded using data from a non-existent or uninitialized output, potentially leading to incorrect transaction details being shown or signed.

Security candidateWrong function mentioned in commentby Salvatore Ingala · f8689a27 · Mar 27, 2026 · 1 fileMessage 45 · ThinTriage 15Details
Commit message · Salvatore Ingala

Wrong function mentioned in comment

45/100 · ThinMessage clarity
✓ Descriptive subject✓ Names a concrete action or component! No meaningful explanatory body
Why it was queued
cryptography-sensitive path
Security candidateBuild-time check to protect global variables from stack overflowby Ilya Artemov · 9771747d · Mar 26, 2026 · 1 fileMessage 55 · ThinLow 32Details
Commit message · Ilya Artemov

Build-time check to protect global variables from stack overflow

55/100 · ThinMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Names security-relevant behavior explicitly! No meaningful explanatory body
Why it was queued
memory safety
AI analysis · Low 32/100

This commit adds a build-time safety check in the Ledger Bitcoin app's Makefile. It sets a minimum required stack size depending on the device (Nano X or other), which helps catch cases where too much memory is used globally and could overflow into the stack. It is a defensive hardening change, not a fix for a known active bug or attack.

Security candidateAvoid leaving secrets in memory on error pathsby Salvatore Ingala · 2b869289 · Mar 24, 2026 · 1 fileMessage 45 · ThinTriage 15Details
Commit message · Salvatore Ingala

Avoid leaving secrets in memory on error paths

45/100 · ThinMessage clarity
✓ Descriptive subject✓ Names a concrete action or component! No meaningful explanatory body
Why it was queued
cryptography-sensitive path
Security candidateFix overflow check in parse_unsigned_decimalby Salvatore Ingala · e9925b44 · Mar 24, 2026 · 2 filesMessage 83 · StrongModerate 62Details
Commit message · Salvatore Ingala

Fix overflow check in parse_unsigned_decimal

Not all overflows were detected by the overflow check.
Fixed and added a regression test.

Also fixed the type discrepancy between uint32_t and size_t.

83/100 · StrongMessage clarity
✓ Descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context✓ Mentions testing or verification✓ Names security-relevant behavior explicitly
Why it was queued
memory safetyfuzzing or regression evidencesigning or wallet path
AI analysis · Moderate 62/100

This commit fixes a bug in how the Ledger Bitcoin app reads large numbers from wallet policy strings. The old overflow check could miss some values that are too large to fit in a 32-bit unsigned integer, causing the app to silently accept and truncate an oversized number. This could let an attacker craft a wallet policy that passes validation when it should have been rejected, potentially changing the meaning of a spending condition such as a time lock. The fix corrects the math used to detect overflow and adds a regression test.

Security candidateValidate boundaries before assigningby Salvatore Ingala · 4f93090e · Mar 24, 2026 · 1 fileMessage 35 · OpaqueModerate 59Details
Commit message · Salvatore Ingala

Validate boundaries before assigning

35/100 · OpaqueMessage clarity
✓ Descriptive subject! No meaningful explanatory body! Opaque security-relevant change
Why it was queued
signing boundarydefensive validationsigning or wallet path
AI analysis · Moderate 59/100

This commit fixes a boundary-check ordering bug in the Ledger Bitcoin app's wallet policy parser. Previously, the code stored an untrusted length value into a data structure before checking whether that length was too large. The fix moves the storage to after the validation check. This prevents a malformed wallet policy from causing the app to record an oversized length that could later lead to memory corruption or incorrect parsing.

Security candidateAbort if input/output amounts are absurdby Salvatore Ingala · 22eb42da · Mar 18, 2026 · 1 fileMessage 68 · AdequateModerate 59Details
Commit message · Salvatore Ingala

Abort if input/output amounts are absurd

While the transaction would be invalid anyway, no reason to
proceed with the signing flow with values that could cause
integer overflows.

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

This commit adds safety checks in the Ledger Bitcoin app's transaction signing code. Before this change, the app would continue processing Bitcoin transaction inputs and outputs even if their amounts were larger than all the Bitcoin that will ever exist. Such absurdly large values could potentially cause arithmetic overflows in later calculations. The fix makes the app immediately reject these transactions with an error instead of continuing.

Security candidateProperly exclude SWAP-related code if ENABLE_SWAP != 1by Ilya Artemov · 74907bc2 · Mar 5, 2026 · 13 filesMessage 50 · ThinLow 26Details
Commit message · Ilya Artemov

Properly exclude SWAP-related code if ENABLE_SWAP != 1

50/100 · ThinMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component! No meaningful explanatory body
Why it was queued
cryptography-sensitive pathsigning or wallet path
AI analysis · Low 26/100

This commit is a build-system cleanup for Ledger's Bitcoin app. It wraps all code related to the optional 'SWAP' feature inside #ifdef HAVE_SWAP guards so that, when the app is compiled without SWAP support, none of that code is compiled or linked. The change removes unconditional references to swap-specific global variables and functions from non-swap source files. On its own this is a hardening/compilation-fix change rather than a fix for an active, exploitable vulnerability in already-shipped code.