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

bolt12: inject feature-bit catalogues into Offer and InvoiceRequest validators

Public commit record

What the developer wrote

Authored by bitromortac

73/100 · Adequate
bolt12: inject feature-bit catalogues into Offer and InvoiceRequest validators

Inject known feature-bit catalogues into the read-side validators to enable
correct must-understand capability checks, and remove write-side feature
enforcement entirely.

Whether a feature bit is "unknown" is a runtime property of the reading node,
not of the wire format or pure codec.
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context
The short version

What changed, and why it matters

This change updates how the LND code checks feature bits in BOLT 12 offers and invoice requests. Previously, the read-side validator treated every even feature bit as unknown and would reject it, because it had no list of known features. Now the caller passes in a catalogue of known feature bits, so legitimate new features are accepted. The write-side validator is also relaxed: it no longer enforces feature rules when creating messages, because whether a feature is 'unknown' depends on the reader, not the writer. The change is a correctness fix for protocol feature negotiation, not a direct patch for an active exploit.

Recommended action

Review callers of ValidateOfferRead and ValidateInvoiceRequestRead to ensure they pass an accurate, up-to-date feature catalogue; otherwise the validators may still reject valid BOLT 12 messages or, conversely, accept unknown even bits if the catalogue is empty. No immediate emergency action is indicated by the diff alone.

Security signals we found

01

Feature-bit validation logic changed from hard-coded nil catalogue to caller-supplied catalogue

02

Write-side feature enforcement removed entirely

03

Read-side now accepts even feature bits that the local node knows, rejects only unknown even bits

04

Test coverage added for accepted known even feature bit and rejected unknown even feature bit

Risk score

Why this scored 44/100

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