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

lnpeer: use INVALID_ONION_VERSION for unparsable onions

Public commit record

What the developer wrote

Authored by f321x

73/100 · Adequate
lnpeer: use INVALID_ONION_VERSION for unparsable onions

Use the `OnionFailureCode.INVALID_ONION_VERSION` (BADONION | PERM | 4)
code when sending back `update_fail_malformed_htlc` as just sending a plain
`BADONION` is not explicitly mentioned as correct in the spec.
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context
The short version

What changed, and why it matters

This commit tightens how Electrum's Lightning code reports a failed onion packet. Previously it used a generic 'BADONION' flag; now it uses the more specific 'INVALID_ONION_VERSION' code when telling the peer the onion could not be parsed. The change is mainly about following the Lightning specification more precisely and is unlikely to be a security fix for an exploitable bug.

Recommended action

Treat as a normal protocol-correctness patch. Review related Lightning spec compliance if auditing, but no urgent security response is indicated by this commit alone.

Security signals we found

01

Lightning protocol compliance change for malformed-onion failure codes

02

No buffer overflow, memory corruption, or authentication bypass visible in diff

03

No explicit vulnerability disclosure or CVE referenced in commit or materials

Risk score

Why this scored 29/100

Our methodology →
Potential impact 5/30
Exploitability 3/25
Stealth signal 4/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.