LDK Fix Blocks Probe Linking Hidden Lightning Channels to Bitcoin

A fix in Bitcoin’s Lightning Development Kit blocks a probe that could link an unannounced channel to its on-chain funding output. Valid channel aliases remain usable.

The Lightning Development Kit, or LDK, has a privacy fix that blocks a probe linking an unannounced Lightning channel to the Bitcoin output that funds it. The fix rejects onion-message lookups using the channel’s real short-channel ID, while valid aliases remain usable.

The probe exploited LDK’s handling of onion messages, which route data through the Lightning Network. An attacker could identify a suspected funding output on the Bitcoin blockchain, calculate a possible channel identifier and use a message route through two suspected channel endpoints to test the link.

The attacker had to connect to both nodes believed to operate the channel. The attacker also needed a candidate short-channel ID and an onion-message route that passed through both nodes before returning to the attacker.

A short-channel ID, or SCID, identifies a Lightning channel by its funding transaction’s block, the transaction’s position in that block and the output’s position within the transaction. These details allow an attacker to calculate a possible SCID for a Bitcoin output without knowing whether it funds a channel between two specific nodes.

Before the fix, LDK could resolve the real SCID of an unannounced channel after its funding transaction had confirmed. If the onion message returned successfully, the attacker could confirm that the suspected output funded a channel connecting the two nodes.

LDK now prevents onion-message forwarding from resolving the real SCID of an unannounced channel. A local alias can still identify the channel for message delivery without revealing its blockchain coordinates.

The change follows the Lightning specification’s rules for onion messages. Those rules require the SCID in a message to refer to an announced identifier or an accepted local alias.

It has not been confirmed which LDK releases contain the fix or which wallets have deployed it. Users should check with their wallet providers before assuming that their installed software includes the protection.

Articles by this author