lnwallet: remove need for lnwallet to have access to the private key

This paves the way for lnd to work with hardware wallets, in which case it will not have access to the private key.
This commit is contained in:
CirroStorm authored and Olaoluwa Osuntokun committed 2018-09-27 20:58:46 -07:00
1 parent 6afee3d099
commit f594a57c94
4 files changed
+9 -19

No files matched your search

+1 -4
View File
@@ -658,10 +658,7 @@ func newServer(listenAddrs []net.Addr, chanDB *channeldb.DB, cc *chainControl,
s.htlcSwitch.RemoveLink(chanID)
return nil
},
IsOurAddress: func(addr btcutil.Address) bool {
_, err := cc.wallet.GetPrivKey(addr)
return err == nil
},
IsOurAddress: cc.wallet.IsOurAddress,
ContractBreach: func(chanPoint wire.OutPoint,
breachRet *lnwallet.BreachRetribution) error {
event := &ContractBreachEvent{