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

Account for shared input EMPTY_SCRIPT_SIG_WEIGHT

Public commit record

What the developer wrote

Authored by Jeffrey Czyz

68/100 · Adequate
Account for shared input EMPTY_SCRIPT_SIG_WEIGHT

When splicing a channel, the previous funding output is spent and fees
for it are paid by the splice initiator. However, the witness weight was
not including EMPTY_SCRIPT_SIG_WEIGHT. Fix this and update the variable
name to make clear the weight needed is the input satisfaction.
✓ 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 fee-calculation bug in an experimental Lightning channel-splicing feature. When two parties splice a channel, the initiator pays the on-chain Bitcoin transaction fee. The code previously forgot to count a small but mandatory 8-weight-unit 'empty script signature' cost for the old funding input it re-spends. That made the initiator's fee estimate slightly too low. The fix adds that missing weight, so the initiator contributes enough fee and the splice transaction is more likely to confirm at the intended fee rate. It is a correctness/economic bug, not a direct theft-of-funds vulnerability, but a low fee could cause a transaction to stall or be dropped from mempools.

Recommended action

Review whether any deployed splicing code path could have produced under-fee splice transactions and, if so, monitor for stuck transactions or consider bumping. Otherwise, treat as a normal correctness fix and ensure splicing tests cover fee edge cases.

Security signals we found

01

Fee underestimation in transaction building

02

Splicing feature gated by #[cfg(splicing)] experimental flag

03

Initiator-pays fee model creates economic imbalance if estimate is wrong

04

No input validation bypass or memory-safety issue present

05

Constants-only change with test expectation updates

Risk score

Why this scored 44/100

Our methodology →
Potential impact 12/30
Exploitability 8/25
Stealth signal 7/15
Affected reach 6/15
Confidence 7/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.