mirror of
https://github.com/lightningnetwork/lnd.git
synced 2025-12-05 18:31:37 +01:00
server: use nodeKeyECDH everywhere
This commit is contained in:
@@ -670,7 +670,7 @@ func newServer(cfg *Config, listenAddrs []net.Addr,
|
|||||||
// With the announcement generated, we'll sign it to properly
|
// With the announcement generated, we'll sign it to properly
|
||||||
// authenticate the message on the network.
|
// authenticate the message on the network.
|
||||||
authSig, err := netann.SignAnnouncement(
|
authSig, err := netann.SignAnnouncement(
|
||||||
s.nodeSigner, s.identityECDH.PubKey(), nodeAnn,
|
s.nodeSigner, nodeKeyECDH.PubKey(), nodeAnn,
|
||||||
)
|
)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, fmt.Errorf("unable to generate signature for "+
|
return nil, fmt.Errorf("unable to generate signature for "+
|
||||||
@@ -824,7 +824,7 @@ func newServer(cfg *Config, listenAddrs []net.Addr,
|
|||||||
IgnoreHistoricalFilters: cfg.IgnoreHistoricalGossipFilters,
|
IgnoreHistoricalFilters: cfg.IgnoreHistoricalGossipFilters,
|
||||||
PinnedSyncers: cfg.Gossip.PinnedSyncers,
|
PinnedSyncers: cfg.Gossip.PinnedSyncers,
|
||||||
},
|
},
|
||||||
s.identityECDH.PubKey(),
|
nodeKeyECDH.PubKey(),
|
||||||
)
|
)
|
||||||
|
|
||||||
s.localChanMgr = &localchans.Manager{
|
s.localChanMgr = &localchans.Manager{
|
||||||
@@ -1415,7 +1415,7 @@ func newServer(cfg *Config, listenAddrs []net.Addr,
|
|||||||
RetryDuration: time.Second * 5,
|
RetryDuration: time.Second * 5,
|
||||||
TargetOutbound: 100,
|
TargetOutbound: 100,
|
||||||
Dial: noiseDial(
|
Dial: noiseDial(
|
||||||
s.identityECDH, s.cfg.net, s.cfg.ConnectionTimeout,
|
nodeKeyECDH, s.cfg.net, s.cfg.ConnectionTimeout,
|
||||||
),
|
),
|
||||||
OnConnection: s.OutboundPeerConnected,
|
OnConnection: s.OutboundPeerConnected,
|
||||||
})
|
})
|
||||||
|
|||||||
Reference in New Issue
Block a user