What changed, and why it matters
This commit is a straightforward internal code cleanup: it swaps a specific database type for a narrower interface in one part of the Lightning Network Daemon (LND). It does not change user-facing behavior, fix a bug, or alter security logic. There is no indication this is a security patch.
No security action needed. Treat as normal refactoring.
Security signals we found
No strong security signals were identified.
Evidence from the diff
The change replaces the concrete *channeldb.ChannelStateDB dependency in peer.Config with the chanstate.Store interface. The comment is updated accordingly. This is an interface-abstraction refactor that limits the peer/brontide package’s required surface from the channel-state store to lookups and forwarding-policy access. No functional or security-relevant logic is modified.
Changed components
peer/brontide.gopeer.Config.ChannelDBInspect captured patch +3 / −2
diff --git a/peer/brontide.go b/peer/brontide.go
index 01d948b..f7a01cd 100644
--- a/peer/brontide.go
+++ b/peer/brontide.go
@@ -26,6 +26,7 @@ import (
"github.com/lightningnetwork/lnd/chainntnfs"
"github.com/lightningnetwork/lnd/channeldb"
"github.com/lightningnetwork/lnd/channelnotifier"
+ "github.com/lightningnetwork/lnd/chanstate"
"github.com/lightningnetwork/lnd/contractcourt"
"github.com/lightningnetwork/lnd/discovery"
"github.com/lightningnetwork/lnd/feature"
@@ -259,8 +260,8 @@ type Config struct {
// ChannelLinkConfig.
InterceptSwitch *htlcswitch.InterceptableSwitch
- // ChannelDB is used to fetch opened channels, and closed channels.
- ChannelDB *channeldb.ChannelStateDB
+ // ChannelDB is used to fetch channel state needed by the peer.
+ ChannelDB chanstate.Store
// ChannelGraph is a pointer to the channel graph which is used to
// query information about the set of known active channels.
Why this scored 15/100
Community notes
Notes can correct, qualify, or add evidence to the AI analysis. Every note shown here has been validated by a human moderator.
The AI analysis stands alone for now. Submit a note if you can add evidence or important context.