peer: decorate delivery addr w/ internal key

In this commit, we move to add the internal key to the delivery addr. This way, we give the aux chan closer the extra information it may need to properly augment the normal co-op close process.
This commit is contained in:
Olaoluwa Osuntokun authored and Oliver Gugger committed 2024-09-19 10:18:41 +02:00
1 parent 44ab7e6b10
commit 8dee76a1b8
4 files changed
+131 -17

No files matched your search

+2 -3
View File
@@ -78,9 +78,8 @@ func (w *WalletController) ConfirmedBalance(int32, string) (btcutil.Amount,
func (w *WalletController) NewAddress(lnwallet.AddressType, bool,
string) (btcutil.Address, error) {
addr, _ := btcutil.NewAddressPubKey(
w.RootKey.PubKey().SerializeCompressed(), &chaincfg.MainNetParams,
)
pkh := btcutil.Hash160(w.RootKey.PubKey().SerializeCompressed())
addr, _ := btcutil.NewAddressPubKeyHash(pkh, &chaincfg.MainNetParams)
return addr, nil
}