Commit Graph
838 Commits
Author SHA1 Message Date
Oliver Gugger 989648b7ec itest: fix timeout in sign_psbt test 2022-07-08 16:08:21 +02:00
Oliver Gugger 6980a18ab1 Merge pull request #6712 from Roasbeef/itest-keep-failed-payments
lntest: keep all failed payments by default for HarnessNode
2022-07-08 14:31:37 +02:00
Olaoluwa Osuntokun 2a18263336 lntest: keep all failed payments by default for HarnessNode
In this commit, we fix a detected flake: we go to make a payment, and
then want to assert that 2 attempts we required. The existing logic
assumes that the success and the payment will still be on disk. With a
recent PR, we now delete failed payments by default, but after the fact,
in a non-atomic fashion.

We fix this issue simply by having all the nodes keep around failed
payments for the sake of all the old itests that assumed this
information would always be on disk.

Introduced in: https://github.com/lightningnetwork/lnd/pull/6438.

Fixes https://github.com/lightningnetwork/lnd/issues/6711.
2022-07-07 19:28:30 -07:00
eugene 5e0a2d3f92 itest: zero-conf, scid-alias channel-type integration tests 2022-07-07 17:10:30 -04:00
eugene 49dd4b9e34 multi: add zero-conf, scid-alias channel-types to rpc
This allows the open channel rpcs to use the zero-conf or scid-alias
channel types.
2022-07-07 17:10:30 -04:00
Oliver Gugger 3af42eede9 Merge pull request #6687 from guggero/sign-psbt-np2wkh
walletrpc: Fix SignPsbt for NP2WKH inputs
2022-06-30 12:18:12 +02:00
Oliver Gugger bb3cec6b12 itest: add test for FundPsbt->SignPsbt|FinalizePsbt flow 2022-06-30 10:27:39 +02:00
Oliver Gugger 9d339f0fe2 Merge pull request #6680 from guggero/compute-input-script
Taproot: Fix p2tr support in `ComputeInputScript`
2022-06-30 10:11:11 +02:00
eugene a7f5b89cf3 itest: update switch delivery tests with more robust reconnect logic 2022-06-29 13:50:03 -04:00
Oliver Gugger 825ff22eec itest: add itest for p2tr via ComputeInputScript 2022-06-29 18:29:00 +02:00
Oliver Gugger 6ee4c533f4 itest: fix incorrect naming 2022-06-29 18:29:00 +02:00
Oliver Gugger 21f69192be itest: rename too specific variables 2022-06-29 18:29:00 +02:00
priyanshiiit ec9cebea34 lntest: adds check for reserve 2022-06-28 23:31:51 +05:30
priyanshiiit 150c0b5de8 lnwallet: adds RequiredReserve method 2022-06-28 23:31:51 +05:30
priyanshiiit f6d21d9b1b lntest: adds test for previous outpoints 2022-06-27 16:00:40 +05:30
yyforyongyu 6b34ebbe44 rpcserver: fix wrong unit used in PushAmountSat 2022-05-16 05:49:05 +08:00
Oliver Gugger 70103a1838 multi: return more information in list of leased outputs
With this commit we return the additional information the wallet now
provides about locked/leased outputs.
2022-05-12 10:24:40 +02:00
Oliver Gugger 6c495c1bbe itest: add Taproot PSBT signing tests 2022-05-11 10:07:51 +02:00
Oliver Gugger fe30b9e987 itest: refactor PSBT signing itest 2022-05-11 10:07:51 +02:00
Oliver Gugger d1a151010a lntest+rpcwallet: support remote p2tr script spend signing 2022-05-11 10:07:51 +02:00
Oliver Gugger 7f4e977073 lntest+rpcwallet: support remote p2tr key spend signing 2022-05-11 10:07:50 +02:00
Olaoluwa Osuntokun 630fc36dcf multi: introduce and use new TapTweak and SignMethod fields
In this commit, we add a new field `TapTweak` to be used for key path
spends. Before this commit, we'd overload the existing `WitnessScript`
field to pass this information to the signing context. This was
confusing as for tapscript spends, this was the leaf script, which
mirrors the other script based spending types.

With this new filed, users need to set this to the script root for
keypath spends where the output key commits to a real merkle root, and
nothing when bip 86 spending is being used.

To make the signing even more explicit, we also add a new field called
sign_method with an enum type that differentiates between the different
segwit v0 and v1 signing methods.

Fixes https://github.com/lightningnetwork/lnd/issues/6446.
2022-05-11 10:07:49 +02:00
Elle Mouton e789107e1f multi: new bitcoind rpcpolling backend for itests 2022-05-11 09:02:13 +02:00
Oliver Gugger 4fd43b4afe itest: add new funding test with all input types 2022-05-10 20:35:28 +02:00
Oliver Gugger fd7fe2ae5a itest: use SendCoinsUnconfirmed in funding test 2022-05-10 18:39:45 +02:00
Oliver Gugger e27a9fec66 lntest: rename sendCoins to SendCoinsOfType 2022-05-10 18:31:18 +02:00
Oliver Gugger 5d8fba6810 Merge pull request #6502 from bhandras/musig-fix
signer: fix crash in `MuSig2Combine` when the final signature isn't ready
2022-05-06 13:24:27 +02:00
Andras Banki-Horvath ddf0571031 itest: cover musig2 combine without all signatures ready 2022-05-06 12:29:32 +02:00
Olaoluwa Osuntokun 0ec88b5346 Merge pull request #6347 from yyforyongyu/5388-rm-revc-log
lnwallet+channeldb: store minimal info in revocation log bucket
2022-05-05 15:52:59 -07:00
Oliver Gugger 52e42fc107 lnrpc+itest: implement MuSig2Cleanup RPC 2022-05-04 19:23:58 +02:00
Oliver Gugger 95ff670c0e multi: add MuSig2Cleanup method to MuSig2 signer 2022-05-04 19:23:58 +02:00
eugene f7b3da4bb2 htlcswitch+lntest: modify Switch to persist resolution messages
Include unit tests for the Switch, and integration tests that
exercise the persistence logic.
2022-04-29 16:40:19 -04:00
Oliver Gugger 63e93ae572 itest: add taproot SignOutputRaw Bip86 signing test 2022-04-29 11:42:46 +02:00
Oliver Gugger 3ba6421d5c itest: add MuSig2 end-to-end tests 2022-04-29 11:42:43 +02:00
Oliver Gugger e31aab5af6 multi: fix inclusion proof size
The inclusion proof field in the TapscriptPartialReveal function was
incorrect. An inclusion proof can be zero or more elements of 32-byte
slices. So an empty inclusion proof can be valid too for a tree that
only consists of a single leaf.
2022-04-29 11:41:09 +02:00
Oliver Gugger f7275c7fc4 multi: implement MuSig2 RPCs and remote signing 2022-04-29 11:41:09 +02:00
Oliver Gugger fee2b28d1b itest: refactor taproot test 2022-04-29 11:41:05 +02:00
Turtle 8d11a90d72 itest: test config option for picking particular peers 2022-04-19 12:37:44 -05:00
yyforyongyu f42d1f2d62 multi: remove function BalancesAtHeight
This commit deletes the function `BalancesAtHeight` since its only
usague is to find the push amount, which can be achieved by saving the
initial balances.
Another reason to remove it is to pave the way to incooperate our new
revocation log. If we ever need this function again, we can add it back
by visiting all the revocation logs to calculate the balances at a given
height.
2022-04-20 01:18:13 +08:00
Oliver Gugger 1e72d6737d lnrpc+itest: fix panic with missing UTXO info
Fixes #6396.
This commit fixes a panic that occurred when trying to sign for a
Taproot output without specifying the full UTXO information for each
input. Instead of panicking an error is now returned.
2022-04-12 19:30:12 +02:00
positiveblue ae2aa5671f lnrpc/peers: handle feature bit changes in updateNodeAnnouncement 2022-04-02 19:10:25 -07:00
positiveblue 76196db70e lnrpc/peers: handle net address changes in updateNodeAnnouncement 2022-04-02 19:09:10 -07:00
positiveblue aacb2565f5 lnrpc/peers: handle color changes in updateNodeAnnouncement 2022-04-01 18:36:26 -07:00
positiveblue ce4813940d lnrpc/peers: handle alias changes in updateNodeAnnouncement 2022-04-01 18:36:26 -07:00
positiveblue e4e0935816 lnrpc/peers: skeleton logic for updateNodeAnnouncement
Basic logic for the endpoint:

- Get the current nodeAnn information
- Calculate modifications
- Apply modifications
- Return changes
2022-04-01 18:36:21 -07:00
Oliver Gugger 3b5585c12b multi: fix and test v1 output spend ntfns
Because Taproot key spend only spends don't allow us to re-construct the
spent pkScript from the witness alone, we cannot support registering
spend notifications for v1 pkScripts only. We instead require the
outpoint to be specified. This commit makes it possible to only match by
outpoint and also adds an itest for it.
2022-03-24 18:02:40 +01:00
Oliver Gugger ef98f2df8a multi: add p2tr tapscript key path signing capabilities 2022-03-24 18:02:39 +01:00
Oliver Gugger 78db46be7e multi: add p2tr tapscript signing capabilities 2022-03-24 18:02:39 +01:00
Oliver Gugger 5109c55721 itest: assert P2TR on-chain fund recovery 2022-03-24 18:02:38 +01:00
Oliver Gugger c73cf03a55 multi: add p2tr keyspend wallet support 2022-03-24 18:02:38 +01:00