multi: make MsgRouter available in the ImplementationCfg

With this commit, we allow the `MsgRouter` to be available in the `ImplementationCfg`. With this, programs outside of lnd itself are able to now hook into the message processing flow to direct handle custom messages, and even normal wire messages.
This commit is contained in:
Olaoluwa Osuntokun
2024-04-04 16:13:30 -07:00
committed by Oliver Gugger
parent 371e0148dc
commit 5866287aae
3 changed files with 18 additions and 3 deletions

View File

@@ -3924,6 +3924,7 @@ func (s *server) peerConnected(conn net.Conn, connReq *connmgr.ConnReq,
DisallowRouteBlinding: s.cfg.ProtocolOptions.NoRouteBlinding(),
Quit: s.quit,
AuxLeafStore: s.implCfg.AuxLeafStore,
MsgRouter: s.implCfg.MsgRouter,
}
copy(pCfg.PubKeyBytes[:], peerAddr.IdentityKey.SerializeCompressed())