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

common: don't abort() if wally_psbt_output_taproot_keypath_add() fails.

Public commit record

What the developer wrote

Authored by Rusty Russell

81/100 · Strong
common: don't abort() if wally_psbt_output_taproot_keypath_add() fails.

It fails on duplicates. It would ideally succeed, but bug reported:

https://github.com/ElementsProject/libwally-core/issues/509

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Changelog-Fixed: JSON-RPC: `signpsbt` no longer crashes if asked to sign an already-signed PSBT with taproot paths.
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context✓ Links an issue, advisory, or supporting reference
The short version

What changed, and why it matters

This update fixes a crash in Core Lightning's wallet command `signpsbt`. When asked to sign a PSBT (a Bitcoin transaction format) that already contains taproot signatures, the underlying library would fail and the program would call `abort()`, killing the node. The patch turns that fatal crash into a normal error message. It also removes a test marker that expected the crash, confirming the bug is now fixed.

Recommended action

Apply the patch. It is a targeted fix with low regression risk. Consider also updating libwally-core once ElementsProject/libwally-core#509 is resolved, since the current behavior still rejects duplicate keypaths and the patch only handles that failure gracefully.

Security signals we found

01

Denial-of-service vector: JSON-RPC `signpsbt` on an already-signed taproot PSBT caused node abort()

02

Crash-to-error conversion: fatal abort() replaced with boolean return and graceful failure

03

Library bug dependency: failure caused by libwally-core rejecting duplicate taproot keypaths

04

Test re-enabled: `test_sign_signed_psbt` no longer marked as expected failure

Risk score

Why this scored 60/100

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