AI-generated analysisPublished automatically and not human-verified. Validated context appears in community notes below.
← Watch feed
Moderate 60 Bitcoin

psbt: set locktime on the transaction, not the PSBT

Public commit record

What the developer wrote

Authored by Sjors Provoost

73/100 · Adequate
psbt: set locktime on the transaction, not the PSBT

get_unsigned_tx() assigned the computed locktime to a stray
attribute on the PSBT, so the constructed transaction kept
locktime 0.
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context
The short version

What changed, and why it matters

This commit fixes a bug where a transaction's locktime (a time-based or block-height-based restriction on when a Bitcoin transaction can be mined) was being set on the wrong object. Instead of assigning it to the actual transaction, the code accidentally assigned it to the PSBT wrapper object, so the transaction kept a locktime of 0. This could cause transactions with intended time locks to become immediately spendable, potentially breaking security assumptions in wallets or contracts that rely on locktime.

Recommended action

Review any transactions created through HWI's PSBT conversion path that were intended to use nLockTime, as they may have been produced with locktime 0 and could be mined earlier than intended. Update to the patched version and verify locktime values in signed transactions.

Security signals we found

01

Incorrect assignment of locktime to PSBT object instead of transaction

02

Locktime bypass: intended time/block-height restrictions silently ignored

03

PSBTv2 to PSBTv0 conversion path affected

04

Test vector updated to cover locktime fields

Risk score

Why this scored 60/100

Our methodology →
Potential impact 18/30
Exploitability 12/25
Stealth signal 10/15
Affected reach 8/15
Confidence 8/10
Evidence quality 4/5
Human-validated context

Community notes

Notes can correct, qualify, or add evidence to the AI analysis. Every note shown here has been validated by a human moderator.

No validated notes yet.

The AI analysis stands alone for now. Submit a note if you can add evidence or important context.