2
0
mirror of https://github.com/lightninglabs/loop synced 2024-11-04 06:00:21 +00:00
Commit Graph

75 Commits

Author SHA1 Message Date
Boris Nagaev
0e7927ac96
multi: replace LSAT with L402
git mv ./cmd/loop/lsat.go ./cmd/loop/l402.go
sed 's@lsat@l402@g' -i `git grep -l lsat`
sed 's@Lsat@L402@g' -i `git grep -l Lsat`
sed 's@LSAT@L402@g' -i `git grep -l LSAT`
make rpc

Updated release_notes.md.
2024-04-24 13:28:28 -03:00
Boris Nagaev
bfc3f44aa1
update aperture to include lsat to l402 renaming
Fix the build:
go mod tidy
sed 's@\<lsat\>@l402@g' -i `git grep -l -w aperture/lsat`
make rpc
2024-04-24 13:28:04 -03:00
George Tsagkarelis
0914074b10
loop: integrate sweepbatcher to loopout flow 2024-01-23 20:38:10 +02:00
George Tsagkarelis
b43fa11cc1
utils: add htlc & swap related helpers 2024-01-23 20:38:08 +02:00
sputn1ck
4d558b1418
loop: expose server grpc connection 2024-01-17 15:59:07 +01:00
Slyghtning
caa646367f
loopin: finalize swap if unsifficient confirmed funds 2023-11-27 13:46:53 +01:00
Slyghtning
c0b419346c
loopin: restore abandon chan on restart 2023-11-27 11:14:14 +01:00
Slyghtning
5e91c446b8
loopd: abandon loop-ins 2023-11-27 11:14:13 +01:00
Oliver Gugger
08026dab93
multi: update linter, fix issues 2023-10-03 19:36:40 +02:00
Slyghtning
20316042d9
trivial: clean up typos and comments 2023-08-10 15:43:33 +02:00
George Tsagkarelis
921f4d06e7
multi: integrate initiator string to various calls 2023-07-28 14:43:18 +03:00
sputn1ck
270bc3104e
multi: add sql stores to loopd
This commit adds the ability to choose between different sql stores
for loopd. The default is sqlite, but it can be changed to postgres.
2023-06-20 18:59:32 +02:00
sputn1ck
becc8a38d8
multi: use context in loopdb call
This commit adds a context to our loopdb interface, which we should use
in the sqlite migration.
2023-06-19 12:28:32 +02:00
sputn1ck
4baf88c414
multi: fix linter issues
This commit fixes outstanding linter issues, that we're not found by
running `make lint` locally. The linter issues were found by running
`docker run -v $(pwd):/build loop-tools golangci-lint run --whole-files`

I added the `revive` to the excludes as it would be to much of a
refactor and IMO seems unneccesary. E.g.
`interface.go:222:6: exported: type name will be used as
loop.LoopInTerms by other packages, and that stutters; consider
 calling this InTerms (revive)`. I think `loop.LoopInTerms` is fine.
2022-12-15 18:08:38 +01:00
Andras Banki-Horvath
bdb4b773ed
swap: refactor htlc construction to allow passing of internal keys
This commit is a refactor of how we construct htlcs to make it possible
to pass in internal keys for the sender and receiver when creating P2TR
htlcs. Furthermore the commit also cleans up constructors to not pass in
script versions and output types to make the code more readable.
2022-11-30 18:16:44 +01:00
Andras Banki-Horvath
88956455b4
multi: completely remove support for NP2WSH htlcs
This commit removes all code related to NP2WSH htlcs. These were
historically used when segwit adoption was very sporadic and are not
used anywhere anymore. Some historical swaps stored in the DB may be
listed with incorrect htlc adresses from here on.
2022-11-04 17:14:53 +01:00
Andras Banki-Horvath
5d7b0abdf5
loopout: add unit test for the MuSig2 sweep case 2022-06-30 16:59:59 +02:00
Andras Banki-Horvath
ce3026daa9
client: LoopInQuote to support v3 htlc for fee estimate 2022-06-30 16:59:56 +02:00
Andras Banki-Horvath
bf59159ddb
client: LoopOutQuote to support estimate using v3 htlc 2022-06-30 16:59:56 +02:00
Andras Banki-Horvath
391ef57ea3
loopout: enable p2tr without keyspend 2022-06-30 16:59:55 +02:00
Andras Banki-Horvath
901a935514
loopin: enable p2tr htlcs without keyspend 2022-06-30 16:59:55 +02:00
Andras Banki-Horvath
9610becebd
multi: add the aggregate internal pubkey to the v3 htlc 2022-06-09 10:20:16 +02:00
Harsha Goli
dec6dd7e70
swap: HTLCV3 added
In this commit we add the version 3 htlc, which is implemented with
taproot script spending the two payment paths: the claim path case, and
the timeout case.
2022-04-22 11:36:09 -04:00
Harsha Goli
7a16e3b25d
multi: bump btcec/v2 and btcutil to new versions 2022-03-25 11:00:16 +01:00
Andras Banki-Horvath
1d1354d2cb
config: make total payment timeout and retries configurable 2022-02-14 10:14:47 +01:00
Andras Banki-Horvath
b3d8f5f096
loopd: close dbs when the daemon stops 2021-12-22 10:32:11 +01:00
Harsha Goli
f1a7d8fb49
multi: pass private, routehints from loopcli - loopd - loop server
This commit passes routehints all the way from when/if the user passes
them from the cli all the way to the backend loop server. If private is
used, this commit passes that boolean down to different stages, where it
is then converted into routehints.

main: add --private and --route_hints to quote

Adds --private and --route_hints flags to quote cli
2021-12-07 21:04:07 -05:00
Andras Banki-Horvath
0e7ed91d5d
loop: integrate the probe api with loop-in quote
In this commit we add a call to the new probe endpoint directly into the
loop-in quote call. Furthermore we add an option to include private
channels in the loopin swap payment request. This is also useful for when
users quote/probe directly using the client API and specify hop hints.
2021-07-30 13:22:12 +02:00
Andras Banki-Horvath
f786aaa016
loop: add support for the probe API 2021-07-30 13:22:12 +02:00
carla
d1c26a20da
multi: surface server swap initiation grpc error codes
Formatting our error was stifling any grpc error returned by the
server. Instead, we bubble up our grpc error, setting an unknown
code if the server did not specifically return an error code.
2021-07-19 10:28:34 +02:00
carla
16111352a8
multi: add cancel swap function to execute config 2021-05-24 08:40:14 +02:00
Oliver Gugger
fdbf7e95e1
client: fix double hex encoding of node pubkey 2021-05-19 14:25:28 +02:00
Oliver Gugger
27fd6b3304
multi: use aperture instead of local lsat library
Since the lsat code was copied over to aperture a while ago for other
projects to use as well, we should migrate over to that shared code
also. This will give us the recently added "remove token if payment
failed and try again" feature for free along with some other small
updates to the lsat package.
2021-04-29 10:01:15 +02:00
Elle Mouton
65fe06cec2 loopd: verify loop out amount
This commit adds validation that checks if the loop out amount specified can
be satisfied given the nodes current channel balances.
2021-03-17 10:12:30 +02:00
Andras Banki-Horvath
133f3cac5f multi: integrate the new htlc v2 scripts to loop in/out
This commit bumps the current protocol version and integrates htlc v2
with loop in/out for new swaps, while keeping htlc v1 for any pending
swaps with previous protocol versions.
2020-09-09 19:54:01 +02:00
Andras Banki-Horvath
9fdd531130
swap: add HTLC script version 2020-08-27 16:21:47 +02:00
Joost Jager
43323ffbe2
loopout: extend htlc expiry based on conf target 2020-07-16 21:30:16 +02:00
carla
cd2b08aec6
multi: consume and log sever state updates 2020-07-16 21:02:06 +02:00
Joost Jager
1869ad670f
looprpc: expose server message to clients 2020-06-30 16:59:10 +02:00
Joost Jager
8b215edaa2
multi: create init result structs 2020-06-30 16:59:08 +02:00
Joost Jager
68012f051a
loopout: create LoopOutSwapInfo struct 2020-06-30 16:59:06 +02:00
Joost Jager
0c9fcd790e
lndclient: move to github.com/lightninglabs/lndclient 2020-06-18 14:27:52 +02:00
Joost Jager
b61b886c16
loopd: group and clarify swap server parameters 2020-06-15 16:18:34 +02:00
carla
2ebbc78131
swap: add constructor for swap config 2020-06-08 12:53:07 +02:00
Joost Jager
8c544bf2ba
loopdb: store outgoing channel set
Upgrade the database schema to allow for multiple outgoing channels.
This is implemented as an on-the-fly migration leaving the old key in
place.
2020-05-21 11:22:04 +02:00
Andras Banki-Horvath
f0aff9b7bd looprpc+loopin: support for native segwit htlcs
This commit extends SwapResponse and SwapStatus with np2wsh and p2wsh
htlc output addresses to support both nested and native segwit htlcs
in loop-in.

Furthermore the commit adds support for native segwith loop-in htlcs.
When the htlc is paid internally, as of this commit we'll use NP2WSH,
otherwise users are free to select whether to pay the NP2WSH or the
P2WSH htlc.
2020-05-05 15:49:05 +02:00
Andras Banki-Horvath
7a44eec36f loopin: refactor LoopIn to return struct instead of tuple 2020-05-04 18:19:20 +02:00
Joost Jager
12ae3d6a40
loopd: make maximum number of payment parts configurable 2020-04-27 16:32:12 +02:00
Joost Jager
5588876b48
loopd: extract client configuration 2020-04-27 16:30:44 +02:00
Oliver Gugger
3da09aac0e
client: use cached info to log connected node 2020-04-24 10:04:42 +02:00