Commit Graph

680 Commits

Author SHA1 Message Date
Slyghtning
86f1bc7db0 lncli: chan_point option for updatechanstatus 2022-07-06 10:19:12 -04:00
Slyghtning
abcd1dc4ed lncli: Fix batchopenchannel help text [skip ci] 2022-07-04 11:10:31 -04:00
Olaoluwa Osuntokun
3759b0f1ee
Merge pull request #6577 from ziggie1984/hop-hints-opt-in-addholdinvoice
Hop hints opt in addholdinvoice
2022-06-28 15:38:48 -07:00
priyanshiiit
3befeadaf3 lnrpc+lncli: adds required reserve rpc & cli 2022-06-28 23:31:51 +05:30
Olaoluwa Osuntokun
a121f305b6
Merge pull request #6576 from ellemouton/paymentAddrBuildRouteFlag
lncli: add payment-addr flag to buildroute
2022-06-24 15:44:35 -07:00
Peter Todd
eef2f1caf7
Add p2tr to supported address help message 2022-06-11 00:53:36 -04:00
ziggie
2ae5c9cef2
cmd/lncli: make hop hint inclusion opt-in for addholdinvoice 2022-05-25 14:49:32 +02:00
Elle Mouton
5b0f2c4798
cmd/lncli: add payment_addr flag to buildroute 2022-05-25 11:45:18 +02:00
Oliver Gugger
968393975b
cmd/lncli: add constrainmacaroon command 2022-05-13 13:41:10 +02:00
Oliver Gugger
f4e1f60e4d
cmd/lncli: extract macaroon caveat flags
As a preparation for re-using the macaroon caveat/constraints CLI flags,
we extract the parsing and adding of those constraints into its own
function.
2022-05-13 13:38:53 +02:00
Oliver Gugger
cb3cb4c8ab
cmd/lncli: add pk script and value to JSON 2022-05-12 10:24:42 +02:00
Olaoluwa Osuntokun
5e4d349ea6
cmd/lncli: make hop hint inclusion opt-in for addinvoice
Fixes #6484.
2022-05-10 17:56:57 -07:00
Olaoluwa Osuntokun
12b82d0156
Merge pull request #5652 from ErikEk/neutrino-sub-server
Neutrino sub-server
2022-05-03 16:01:24 -07:00
Oliver Gugger
ab6e1012e4
cmd/lncli: add --count_total_payments flag 2022-05-02 12:32:07 +02:00
ErikEk
57036d0f63 neutrinorpc: command interface 2022-04-30 08:55:55 +02:00
hieblmi
b1f6bc977e #4939 Add socks proxy support to lncli 2022-04-16 20:30:42 +02:00
Joost Jager
ba5abdc090
routing: add time_pref parameter to queryroutes and sendpayment 2022-04-13 20:26:46 +02:00
Olaoluwa Osuntokun
2fd900b172
Merge pull request #5587 from positiveblue/5466-update-node-announcement-data
lnrpc: Add UpdateNodeAnnouncement endpoint
2022-04-11 22:32:12 -04:00
Oliver Gugger
e13e5f874f
cmd/lncli: fix linter issues after contributor PR [skip ci] 2022-04-11 18:02:42 +02:00
Oliver Gugger
65dc3ef8a6
Merge pull request #6349 from gabbyprecious/unlock-error-message#2529
change changepassword and unlock error message
2022-04-11 17:05:33 +02:00
positiveblue
f3fdf8d28e
lncli: add peers updatenodeannouncement 2022-04-02 19:10:27 -07:00
gabbyprecious
a0b7680424 cmd/lncli: changepassworderror message [skip ci] 2022-04-01 15:52:59 +02:00
Oliver Gugger
c73cf03a55
multi: add p2tr keyspend wallet support 2022-03-24 18:02:38 +01:00
Oliver Gugger
7dfe4018ce
multi: use btcd's btcec/v2 and btcutil modules
This commit was previously split into the following parts to ease
review:
 - 2d746f68: replace imports
 - 4008f0fd: use ecdsa.Signature
 - 849e33d1: remove btcec.S256()
 - b8f6ebbd: use v2 library correctly
 - fa80bca9: bump go modules
2022-03-09 19:02:37 +01:00
Olaoluwa Osuntokun
791411cdb8
Merge pull request #6237 from sangaman/lncli-state-desc
lncli: update `lncli state` description
2022-03-02 17:08:22 -08:00
Olaoluwa Osuntokun
4a15de05aa
build: update go-pretty v6 [skip ci]
In this commit we update go-pretty to use the latest v6 version of the
library. The existing version we used had a reported vulnerability.
Updating to this newest version also helped to shrink our set of
indirect dependencies.

In the future we can use
https://github.com/lightningnetwork/lnd/pull/5870 to detect/flag these
issues automatically.

Fixes #6293
2022-03-01 15:02:23 -08:00
Oliver Gugger
895a2e497b
multi: formatting and comment fixes 2022-02-10 11:02:02 +01:00
Oliver Gugger
ffee7d1bcf
multi: fix newly detected linter issues 2022-02-10 11:02:02 +01:00
Oliver Gugger
dfdc2bff8b
multi: run gosimports 2022-02-10 11:02:01 +01:00
Rafe
62dc1b5323 multi: Update Licenses to 2022 [skip ci] 2022-02-09 00:25:20 +02:00
Daniel McNally
2b1bb3bce0
lncli: update lncli state description
This updates the description that is provided for `lncli state` to match
the states that are currently returned by lnd. `RPC_READY` no longer
exists and is replaced by `RPC_ACTIVE` with a revised description, and
`SERVER_ACTIVE` is added as the status that indicates lnd is fully
ready to accept RPC calls.

See `enum WalletState` in `stateservice.proto`.
2022-02-04 08:42:06 -05:00
Oliver Gugger
d252653624
lncli: use amount based default routing fee 2022-02-02 17:29:52 +01:00
Oliver Gugger
b77c1fb200
Merge pull request #6149 from bhandras/graph_import_rpc
lnd: add `devrpc` sub server and `devrpc.ImportGraph` to import graph dumps
2022-01-28 10:24:59 +01:00
ErikEk
ef1eff1058 lnrpc: fix the existing routing fee inaccuracy
When updating the channel routing policy, we encounter an inaccurate
precision error when calculating the routing fee. The issue stems from
the way the IEEE 754 standard works.

The solution here is to add a uint64 parameter (as mentioned in the
issue) and keep the float64 fee_rate parameter but rounding the product
of the base and fee rate.
2022-01-25 15:42:57 -08:00
Andras Banki-Horvath
eeea141e01
lnd: allow large GRPC messages 2022-01-24 17:43:00 +01:00
Andras Banki-Horvath
996be217b9
lncli: add (dev only) importgraph 2022-01-24 17:43:00 +01:00
Dimitris Apostolou
530a2059e5
multi: Fix typos [skip ci] 2022-01-24 12:19:02 +02:00
Andras Banki-Horvath
ec046aec1b
lncli: add force flag to 2022-01-19 17:18:06 +01:00
mads krogh
3821bd2202 lncli: add test for parseChanPoint 2022-01-13 14:35:04 +01:00
mads krogh
807bc0628c lncli: add chan_point flag to closechannel command 2022-01-13 14:35:00 +01:00
Joost Jager
f99b472bbb
lncli: add lockid parameter to releaseoutput 2022-01-03 18:21:12 +01:00
Joost Jager
0b2388bd4b
lncli: add leaseoutput command 2022-01-03 18:21:10 +01:00
Torkel Rogstad
55617f153f lncli: add fish-completion
This is a new, hidden command that generates completions for Fish shell.
This can be piped into `source` or saved in a file to activate (almost)
perfect tab completion.
2021-12-13 11:07:49 +01:00
Torkel Rogstad
c64e9c5286 Bump urfave/cli version
urfave/cli added functionality for generating Fish shell tab-completions
a few releases ago. We bump the dependency version to get access to
this functionality.
2021-12-13 11:07:49 +01:00
Matthew Bajorek
6ebc896f6f lncli: Add json flag to trackpayment [skip ci] 2021-12-07 14:04:27 -05:00
Olaoluwa Osuntokun
7d46836e9a
cmd/lncli: remove --amp-reuse flag from lncli payinvoice
In this commit, we remove the `--amp-reuse` flag as with the latest
version of lnd that implements properly re-useable AMP invoices, this
flag is no longer needed.
2021-11-16 18:19:03 -08:00
Oliver Gugger
f65c259f06
cmd/lncli: fix nil map in payment req [skip ci]
Fixes #5989.
Fixes a panic in lncli if a payment request and the --data flag is used
at the same time.
2021-11-16 13:51:05 +01:00
Olaoluwa Osuntokun
e6c65f1cbd
Merge pull request #5346 from joostjager/custom-messages
lnrpc+peer: custom peer messages
2021-10-18 19:07:39 -07:00
Joost Jager
ade50d0b2c
lnrpc: receive custom message 2021-10-15 17:08:55 +02:00
Joost Jager
ae959b16ae
lnrpc: send custom message 2021-10-15 17:08:53 +02:00
Oliver Gugger
78b700387c
cmd/lncli+walletrpc: add createwatchonly command 2021-10-14 15:42:58 +02:00
Oliver Gugger
e1da1f8941
multi: extract wallet initialization
With this commit we extract the wallet creation/unlocking and
initialization completely out of the main function. This will allow us
to use custom implementations in the future.
2021-10-08 12:13:15 +02:00
Oliver Gugger
0e279eb15a
multi: refactor external subserver config
As a preparation for making more and more implementation details
configurable, we add a new ImplementationCfg struct that houses all the
interfaces that can be defined externally.
2021-10-08 12:08:23 +02:00
Torkel Rogstad
4d96f31f59 lncli: take chan_id as uint64 in getchaninfo
When taking in chan_id as a int64, there are some channels that cannot
be givn to lncli because they are out of range for an int64.
2021-10-07 14:57:32 +02:00
Olaoluwa Osuntokun
91edfaed85
Merge pull request #5802 from yyforyongyu/5318-fix-addr-format
lndcfg: give verbose err when failed to load config
2021-09-30 20:14:08 -07:00
Oliver Gugger
0b4e03f5fc
multi: add golang 1.17 compatible build tags
With go 1.17 a change to the build flags was implemented:
https://go.googlesource.com/proposal/+/master/design/draft-gobuild.md

The formatter now automatically adds the forward-compatible build tag
format and the linter checks for them, so we need to include them in our
code.
2021-09-29 17:31:37 -07:00
yyforyongyu
98ca821085
lndcfg: give verbose err when failed to load config 2021-09-29 04:37:05 +08:00
Oliver Gugger
f60a1ba0ce
Merge pull request #5699 from guggero/lncli-deletepayment
lncli: add deletepayments command
2021-09-27 13:41:41 +02:00
Oliver Gugger
348405994c
cmd/lncli: add deletepayments command
To give the CLI user the option to delete a single or multiple payments
in one command, we expose the DeletePayment and DeleteAllPayments
RPCs to the command line as well. Due to the similarity of the two RPCs
we combine them into a single command with multiple flags.

To make the command a bit more safe to run without arguments, we
consciously switch the logic of the RPC flag "failed_payments_only"
which is false by default into a "--include_non_failed" in the CLI which
is false by thefault. So a user running the command without knowing what
they are doing are only deleting failed payments by default, not all of
the payments.
2021-09-27 12:34:53 +02:00
Oliver Gugger
765d043cc0
mod+lncli: remove deprecated package [skip ci]
The use of golang.org/x/crypto/ssh/terminal was marked as deprecated
since that code was moved to its own repo golang.org/x/term.
With this commit we use the new package name directly, which was already
pulled in under its new name anyway.
2021-09-24 09:22:47 +02:00
Oliver Gugger
1d103f1f55
cmd/lncli: group all Mission Control cmds into own file
Having one file per sub command seems a bit too excessive and isn't
really implemented for any of the other commands. So we just group the
Mission Control commands into their own file for now.
2021-09-23 16:59:41 +02:00
Oliver Gugger
28c25d7e9c
cmd/lncli: group Mission Control cmds into own category
To make the "Payments" category a bit less overloaded and to move the
Mission Control configuration commands away from the "root" category, we
create the new "Mission Control" category that we move the commands
into. We do this in a single commit so the next one where we move them
into the same file can be a pure code move without any additional
changes.
2021-09-23 16:59:41 +02:00
Oliver Gugger
da418ef46b
cmd/lncli: move all payment related cmds to single file
With this commit we move all commands that can be found within the
"Payments" category into its own file called cmd_payments.go. The only
exception are the Mission Control related commands which we are going to
move to their own category and file in the next commit.
2021-09-23 16:59:40 +02:00
Oliver Gugger
7b822f41df
lncli: add custom caveats to bakemacaroon
With the new condition and checker in place, we can give the end user
the ability to add such a custom caveat to a baked macaroon.
There won't be an RPC counterpart for this operation since all first party
caveats currently are only added on the client side.
2021-09-20 13:05:47 +02:00
Oliver Gugger
045765111a
multi: use safe copy for macaroons
Fixes #4383 by adding a new SafeCopyMacaroon function that correctly
clones all caveats and prevents modifications on the copy from affecting
the original.
2021-09-20 13:05:46 +02:00
ErikEk
46e9481e6c routing: invalid channels updatechanpolicy call 2021-09-15 10:20:49 +02:00
Turtle
38c47e86f7
lncli: Add allow external permissions option to bakemacaroons cli call 2021-09-14 16:27:02 -05:00
Oliver Gugger
bb079f746b
lncli: add batchopenchannel command 2021-09-03 18:39:44 +02:00
Wilmer Paulino
3299af7919
lncli: add channel type flag to openchannel command 2021-08-30 19:17:45 -07:00
Oliver Gugger
bbd5980d42
lncli: add extended master root key to create command
To allow users to restore a wallet from an existing extended master root
key, we accept one of three answers when asking for an existing seed.
2021-08-24 10:37:33 +02:00
Oliver Gugger
370d056863
lncli: extract printCipherSeedWords 2021-08-24 10:37:33 +02:00
Oliver Gugger
bdae6711af
lncli: extract askRecoveryWindow 2021-08-24 10:37:32 +02:00
Joost Jager
925229f9df
walletrpc+lncli: allow zero output psbt funding
To support the cpfp fee bump use case where no external outputs are
required.
2021-08-16 08:41:50 +02:00
Stevie Zollo
00f7534e06
docs: fix inconsistent naming of channel.backup [skip ci] 2021-08-12 00:26:53 +02:00
Olaoluwa Osuntokun
90db8de6fe
Merge pull request #5460 from ErikEk/lncli-add-command-for-publishtransaction
lncli: add command for publishtransaction
2021-08-06 14:42:49 -07:00
Olaoluwa Osuntokun
c235b46e66
cmd/lncli: add new option for easy AMP invoice re-use
In this commit, we add a new option (`--amp-reuse`) that allows for easy
AMP invoice re-use when using either the `sendpayment` command.
2021-08-04 19:17:48 -07:00
Olaoluwa Osuntokun
6e3b33629c
cmd/lncli: always parse the pay_addr field for sendpayment
In this commit, we fix a bug that would cause attempts to re-use an AMP
invoice to fail. Without this commit, we would only attempt to parse the
payment addr if no invoice was specified, so a user manually specifying the
pubkey of the detonation. The fix is straight forward: always parse the
`pay_addr` field as the user may be attempting to re-use an AMP invoice w/o
open coding each of the sections.
2021-08-04 19:17:45 -07:00
ErikEk
ace615b6e8 lncli: add lncli command for publishtransaction 2021-08-03 04:45:28 +02:00
ErikEk
c8fc9b0a85 trivial: missing dots 2021-08-01 02:35:14 +02:00
Olaoluwa Osuntokun
30a0e6c745
Merge pull request #5533 from ErikEk/invoices-return-payment-address-addholdinvoice
invoices: return payment address and add index from addholdinvoice
2021-07-21 16:54:20 -07:00
ErikEk
850dee37ee invoices: return payment address from addholdinvoice 2021-07-19 17:05:03 +02:00
ErikEk
5282b54ad3 invoice: unused error check 2021-07-19 14:24:52 +02:00
ErikEk
fec18f4e16 trivial-typo-walletrpc 2021-07-02 01:36:16 +02:00
Olaoluwa Osuntokun
3dc375603f
Merge pull request #5441 from joostjager/cli-fix-fund-psbt
lncli: fix psbt fund parameter parsing
2021-06-30 17:56:34 -07:00
Olaoluwa Osuntokun
1910e263a8
lncli: check for existence of tls file (#5416) 2021-06-28 16:06:55 -07:00
Joost Jager
9b1b92bf98
lncli: fix psbt fund parameter parsing
The sat_per_vbyte parameter was ignored because of a default value for
conf_target.
2021-06-28 11:23:13 +02:00
Olaoluwa Osuntokun
1287328678
Merge pull request #5335 from guggero/abandonchannel-no-dev
RPC/CLI: Allow abandonchannel to be used in regular build
2021-06-23 16:05:34 -07:00
ErikEk
a6c32df31a lncli: check for existence of tls file 2021-06-22 01:32:54 +02:00
Olaoluwa Osuntokun
ad0ecc4d58
Merge pull request #5333 from wpaulino/incompatible-account-addr-type
lnwallet: check if requested address type is compatible with account
2021-05-27 19:06:13 -07:00
Oliver Gugger
3b712bf722
lncli: add i_know_what_i_am_doing flag to abandonchannel 2021-05-26 22:51:41 +02:00
Wilmer Paulino
f195f21c8c
lncli: remove RPC name from list wallet accounts command description 2021-05-26 11:20:31 -07:00
Oliver Gugger
4460903399
multi: add signet parameters
With this commit we make lnd compatible with the public signet test
network.
2021-05-18 13:06:03 +02:00
Olaoluwa Osuntokun
dc73a23e81
Merge pull request #5253 from cfromknecht/amp-invoice
Support paying AMP invoices via SendPaymentV2
2021-05-12 13:38:42 -07:00
Olaoluwa Osuntokun
d2c25124ed
cmd/lncli: add basic AMP support for CLI 2021-05-10 22:02:15 -07:00
Conner Fromknecht
620e426bc3
lncli: add --amp flag to invoice command 2021-05-10 16:55:17 -07:00
Wilmer Paulino
e079a9583c
walletrpc: use bytes to represent master key fingerprint
The integer representation is not common and using bytes allows users to
easily confirm whether their master key fingerprint is correct.
2021-05-07 13:07:10 -07:00
Wilmer Paulino
f7b130b5ca
lncli: add dry run flag for wallet account import command 2021-05-07 13:07:10 -07:00
Andras Banki-Horvath
dd14947154
lint: silence depreciation warnings 2021-05-04 17:33:14 +02:00
Wilmer Paulino
4964801c6f
lncli: add wallet import related commands 2021-04-05 15:41:11 -07:00
Wilmer Paulino
c7bed34bca
lncli: add account flag to wallet related commands 2021-04-05 15:41:08 -07:00
yyforyongyu
9d0d88ac21
lnrpc+lncli: deprecate sat_per_byte and add sat_per_vbyte
This commit deprecates/replaces the old field `sat_per_byte` with
`sat_per_vbyte`. While the old field suggests sat per byte, it’s
actually using sat per virtual byte. We use the Hidden param to hide all
the deprecated flags. These flags won't show up in help menu onwards,
while stay valid that can be passed from cli. Thus bash scripts
referencing these fields won't be broken.
2021-03-26 17:16:40 +08:00
yyforyongyu
2466758acd
lncli+lnrpc: update docs for sat_per_byte
Update the documentation for the field `sat_per_byte`. While the name
suggests it’s sat per byte, the value is actually in sat per virtual
byte.
2021-03-26 17:09:14 +08:00
Olaoluwa Osuntokun
fcc0dec741
cmd/lncli: add missing context import 2021-03-25 17:49:13 -07:00
Olaoluwa Osuntokun
24d1d9cb14
Merge pull request #5095 from bottlepay/wtxmgr-parameterized-lock
lnwallet+walletrpc: list leases and parameterize duration
2021-03-25 17:31:13 -07:00
Olaoluwa Osuntokun
b4b7f29724
Merge pull request #5102 from yyforyongyu/fix-send-cli
lncli+lnrpc: add payment address to sendpayment
2021-03-24 18:02:53 -07:00
Olaoluwa Osuntokun
6f3e14a545
Merge pull request #5061 from carlaKC/4483-importmissioncontrol
routing: add mission control import rpc
2021-03-23 15:22:27 -07:00
Hampus Sjöberg
ada1bc701c signal: handle shutdown properly
This addresses issues related to the mobile lnd builds, where
calling `stopDaemon` and subsequently calling LndMobile's `Start`
results in crash.
2021-03-18 12:54:25 +01:00
carla
cb977622c6
lncli: add mission control import command 2021-03-18 10:52:23 +02:00
Johan T. Halseth
6046c5cf86
Merge pull request #5119 from ellemouton/lncli-start-signal-interceptor
lncli: start signal interceptor in getContext
2021-03-18 09:30:11 +01:00
Johan T. Halseth
d53633eab5
Merge pull request #5005 from halseth/walletunlocker-unify-staterpc
[RPC] SubscribeState RPC for getting unlocking state of wallet and RPC
2021-03-18 08:41:07 +01:00
Elle Mouton
000516ec4d lncli: start signal interceptor in getContext
signal Intercept function needs to be called if the signal shutdown
channel will be listened on.
2021-03-17 22:44:45 +02:00
Conner Fromknecht
e2690918a0
Merge pull request #5002 from akovalenko/master
lncli addinvoice: allow specifying msat with --amt_msat
2021-03-17 10:03:56 -07:00
yyforyongyu
2dac77200b
lncli+lnrpc: add payment address to sendpayment 2021-03-17 21:16:17 +08:00
Johan T. Halseth
b4bc6f918e
lncli: add state command 2021-03-17 12:09:38 +01:00
Oliver Gugger
05342f25b8
Merge pull request #5097 from ellemouton/lncli-interrupt-handler
lncli: cancel RPC context on OS interrupts
2021-03-17 10:31:08 +01:00
Conner Fromknecht
b4aa661d16
Merge pull request #5064 from ellemouton/set-coop-close-target-confs
multi: allow setting target confs for co-op close
2021-03-16 11:14:15 -07:00
Joost Jager
9398220568 walletrpc: add ListLeases 2021-03-13 08:45:52 +01:00
whythat
54c93b1b86 lncli: cancel RPC context on OS interrupts 2021-03-12 10:07:49 +02:00
Oliver Gugger
c623d21bd2
Merge pull request #5083 from guggero/psbt-size-fix
lncli: allow PSBT to be read from file
2021-03-10 23:02:02 +01:00
Oliver Gugger
b3dfe5d1af
lncli: allow PSBT to be read from file
Fixes #5080.

The N_TTY_BUF_SIZE kernel parameter dictates how many characters can be
pasted into a terminal window. This cannot be circumvented by reading
the input in a different manner.
To avoid the problem fully, we instead allso allow the user to type in a
path to a text file that is read if it exists. That way the PSBT can be
as long as needed.
2021-03-10 12:46:33 +01:00
Elle Mouton
9e9c48fcdd rpc: use default if conf-target is not set
This commit uses the new coop-close-target-confs value as the default to
use for a nodes self initiated channel closures if the conf-target flag
for the channel closure is not set. The defaults for both these options
is 6 so this shouldnt change current behaviour.
2021-03-04 13:07:30 +02:00
Elliott Jin
19e9ed5cdf lncli: add updatechanstatus command
The updatechanstatus command calls into the UpdateChanStatus RPC
in the router server.
2021-02-24 07:13:28 -08:00
Olaoluwa Osuntokun
db69331db9
cmd/lncli: add max shard size parsing for payment commands 2021-02-15 19:31:58 -08:00
Olaoluwa Osuntokun
7b0ea3c029
Merge pull request #4909 from carlaKC/mc-paramsapi
routing: allow runtime updates to mission control config
2021-02-10 18:51:53 -08:00
Anton Kovalenko
7758fd1438
lncli addinvoice: allow specifying msat with --amt_msat
* pass amt and amt_msat to rpc, letting server give an error if both
are present

* take amt from an extra argument if neither amt nor amt_ms are
present

implementation analogous to 298f35cdfb,
which is for addholdinvoice.
2021-02-10 00:20:11 +03:00
Umar Bolatov
4dc5cb5a3a
Fix typo in restorechanbackup command description 2021-01-31 17:37:27 -08:00
carla
63775756e0
lncli: add mission control getter and setter 2021-01-19 10:57:16 +02:00
Conner Fromknecht
f3c8311b28
lncli: add policy type flags to wtclient policy 2020-11-25 16:16:49 -08:00
Oliver Gugger
10673b9dfa
lncli: add flags for stateless init to wallet unlocker commands 2020-11-07 11:18:52 +01:00
carla
f1aa3d2071
lncli: allow setting max local csv for open channel requests 2020-11-04 13:57:21 +02:00
Eugene
bebe258e2d chainregistry+lnd: moving chainregistry+chainparams to new package 2020-10-29 15:24:14 -04:00
carla
0a76f87bd0
lncli: allow configurable timeout in send payment 2020-10-12 13:27:06 +02:00
Oliver Gugger
8e9f37b0fc
lncli+docs: fix outpoint serialization in JSON output
This commit fixes the JSON output of the outpoint field of locked UTXOs
in the response of the PSBT fund command.
2020-10-06 10:59:50 +02:00
Oliver Gugger
c206d062d5
lncli: add new PSBT wallet commands 2020-10-03 10:34:55 +02:00
Tom Kirkpatrick
73a5f325b6
lnrpc: ability to spend unconfirmed coins 2020-10-01 13:27:03 +01:00
Oliver Gugger
b28bf29c5f
lncli: don't read macaroons when not using them
When we either don't use macaroons (because the global --no-macaroons
flag is set) or don't need them (for the wallet unlocker commands), we
don't try to read the file at all to avoid running into an error if the
file doesn't exist (which it doesn't in those two cases).
2020-09-25 15:54:10 +02:00
Oliver Gugger
44524fd2e5
lncli: fix go vet recommendations 2020-09-25 15:18:45 +02:00
Oliver Gugger
ca679e0f0e
lncli: move wallet unlocker commands into own file
This is a pure code move, we extract all wallet unlocker operations
(create, unlock, changepassword) into its own file.
2020-09-25 15:16:56 +02:00
yyforyongyu
469aba9282
lnd+rpcserver: allow customized timeout in ConnectPeer 2020-09-16 11:50:04 +08:00
Joost Jager
cf6eee80db
Merge pull request #2428 from joostjager/letsencrypt
lnrpc: let's encrypt certificates
2020-09-15 13:08:15 +02:00
Joost Jager
403d72b468
lnrpc: lets encrypt
This commit enables lnd to request and renew a Let's Encrypt
certificate. This certificate is used both for the grpc as well as the
rest listeners. It allows clients to connect without having a copy of
the (public) server certificate.

Co-authored-by: Vegard Engen <vegard@engen.priv.no>
2020-09-15 09:59:09 +02:00
Oliver Gugger
154dc1af66
lncli: allow final transaction as raw hex in PSBT funding flow 2020-09-15 08:30:21 +02:00
András Bánki-Horváth
dea6d91431
Merge pull request #4603 from bhandras/fix_help
config: prevent displaying usage twice if --help was requested
2020-09-14 18:58:21 +02:00
Andras Banki-Horvath
b778b25866
config: prevent displaying usage twice if --help was requested 2020-09-14 15:18:41 +02:00
Oliver Gugger
9ea836c237
Merge pull request #4614 from guggero/printmacaroon-fix
lncli: print all permission actions
2020-09-14 13:41:05 +02:00
Andras Banki-Horvath
4ffe744364
lncli: add outgoing_chanid to queryroutes 2020-09-14 11:36:06 +02:00
Oliver Gugger
384ab9f616
lncli: print all permission actions
Due to a misunderstanding about how the entities/actions are encoded
inside the macaroon, only the first action was printed per entity.
Even though we add them as separate pairs in the macaroon service (for
example "offchain:read" and "offchain:write"), they are grouped in the
serialized macaroon ("offchain:read,write").
2020-09-14 10:55:19 +02:00
Oliver Gugger
d792a8ef61
lncli: use readPassword function everywhere 2020-09-07 15:55:05 +02:00
Oliver Gugger
070cfb804f
lncli: use profiles 2020-09-07 15:55:04 +02:00
Oliver Gugger
a2721a15a8
lncli: use CleanAndExpandPath from lncfg 2020-09-07 15:55:04 +02:00
Oliver Gugger
10f73b3b91
lncli: add new profile commands
We add a new 'profile' sub command to lncli to manage pre-defined
configuration profiles for all of lncli's CLI flags.
2020-09-07 15:55:04 +02:00
Oliver Gugger
e2c14edd7b
lncli: add struct to hold profile configuration
A profile file can contain multiple profile entries. Each
entry has a name, a set of default options to use and an optional list
of macaroons in a jar. The profile file can be
serialized/deserialized to and from JSON.
2020-09-07 15:23:17 +02:00
Oliver Gugger
c34732af3d
lncli: add encrypted macaroon jar
With this commit we add a simple macaroon jar that can encrypt its
content with a user-provided password when being serialized to JSON.
2020-09-07 15:23:12 +02:00
Oliver Gugger
4996b28dab
lnrpc+lncli: add command to print macaroon 2020-09-04 09:50:42 +02:00
Oliver Gugger
3ce7f72cd4
lncli: add new listpermissions command 2020-09-04 09:50:41 +02:00
Oliver Gugger
830ce163c6
lncli: add new URI permissions to bakemacaroon 2020-09-04 09:50:41 +02:00
carla
daae8a9944
multi: wrap logger to request shutdown from signal on critical error
This commit adds a shutdown logger which will send a request for
shutdown on critical errors. It uses the signal package to request safe
shutdown of the daemon. Since we init our logs in config validation,
we add a started channel to the signal package to prevent the case where
we have a critical log after the ShutdownLogger has started but before
the daemon has started listening for intercepts. In this case, we just
ignore the shutdown request.
2020-08-24 08:54:34 +02:00
Olaoluwa Osuntokun
bd18f9acf5
Merge pull request #4427 from yyforyongyu/customize-root-key-id
macaroons: customize root key ID
2020-08-21 19:34:15 -07:00
Dominik Spicher
b5fc3a0b03 cmd/lncli: fix sendcoins usage message 2020-08-20 09:44:38 +02:00
yyforyongyu
c8a2916d91
lncli: support list/delete on marcaroon IDs 2020-08-14 12:36:21 +08:00
Candle
c8ad071011 lncli: remove new line from password confirmation
The password instruction in the same function and many other related
outputs use Printf except of Println.
2020-07-22 22:48:44 +02:00
Oliver Gugger
563e56987b
lncli: add --no_publish to PSBT channel opening 2020-07-08 22:19:17 -07:00
vctt94
6845763aa5 lncli: Add max_value_in_flight flag to openchannel 2020-07-03 11:09:34 -03:00
yyforyongyu
f11da830b9 lnrpc: expose all local and remote channel constraints 2020-06-30 06:59:18 +08:00
yyforyongyu
987edc9d81 multi: add a rpc endpoint to track the recovery process 2020-06-25 15:49:54 +08:00
Jasper Rädisch
20b42ce261 cmd/lncli: add fwdinghistory support for relative times
- introduces new parser in `cmd/lncli/arg_parse.go`
- converts start_time and end_time flags to strings
- adds default value for end_time
2020-06-23 15:58:23 -07:00
Conner Fromknecht
32b04b7ac3
Merge pull request #4228 from carlaKC/txdetails-labeltxrpc
walletrpc: add LabelTransaction endpoint to retrospectively label txns
2020-05-26 18:37:27 -07:00
Gabriel Comte
7a4b783fc8
lncli: Fix typos in closechannel help dialog 2020-05-25 16:32:49 +02:00
carla
210a0f428b
lncli: add label transaction command to walletkit cli
Two additional errors are added to the itest error whitelist because we
are specifically trigerring these errors.
2020-05-25 11:33:41 +02:00
carla
52137459e4
lncli: add label flag to send many and send coins 2020-05-19 13:31:51 +02:00
Oliver Gugger
620eaa3199
lnd+cmd: move interrupt into cmd
If the main package is used as a library, we don't want it to
register interrupt signals itself. Rather we want to pass in the
shutdown channel manually. We do this in the cmd now.
2020-05-14 14:37:51 +02:00
Oliver Gugger
7158103d4d
lnd+config: move config parsing to cmd
Now that we have access to the configuration parsing outside of the
main package, we can move the actual parsing to the command line
package.
2020-05-14 14:37:51 +02:00
Joost Jager
0f6eacb4fa
lncli: switch to routerrpc.SendToRouteV2 2020-05-12 19:56:56 +02:00
Joost Jager
c33d94ff27
routing+routerrpc: add multiple outgoing channel restriction 2020-05-12 07:17:24 +02:00
Olaoluwa Osuntokun
db7eac35d0
Merge pull request #4253 from Roasbeef/fix-go12-duration
cmd/lncli: remove usage of Millisecond() for Go 1.12
2020-05-08 16:20:39 -07:00
Olaoluwa Osuntokun
352d45a11e
cmd/lncli: remove usage of Millisecond() for Go 1.12
The new table format for the pay command started to use the
`Millisecond()` method on `time.Duration`. However, this method was only
added in Go 1.13, so this breaks the build for Go 1.12. We replace this
by manual division. `time.Duration` "natively" is in nanoseconds, so we
covert to milli seconds by dividing my `time.Millisecond`, which is
1,000,000.
2020-05-06 16:22:47 -07:00
carla
f3212057dd
walletrpc: add list sweeps to rpc and cli 2020-05-06 09:25:44 +02:00
carla
537dac3c62
multi: specify start and end height for ListTransactionDetails
Add start and end height parameters to the rpc and cli GetTransactions
endpoints. Default to returning all transactions from genesis to tip,
including unconfirmed transactions to maintain backwards compatibility.
2020-05-05 21:10:06 +02:00
Oliver Gugger
d765e73e57
lncli: add PSBT publish warning 2020-04-26 21:05:13 +02:00
Joost Jager
f6b2410011
routing+routerrpc: rename max_shards to max_parts
Don't introduce a new term and align with the P in MPP.
2020-04-22 14:49:19 +02:00
Joost Jager
8d7e07d96b
lncli: live table-based payment updates 2020-04-22 14:49:17 +02:00
Olaoluwa Osuntokun
cd9c1c7746 Revert "lncli: live table-based payment updates"
This reverts commit 6ffdf7ef1f.
2020-04-21 18:03:57 -07:00
Joost Jager
6ffdf7ef1f
lncli: live table-based payment updates 2020-04-21 17:02:15 -07:00
Joost Jager
d51bb65536
routerrpc+lncli: add flag to suppress in-flight updates
This is a preparation for enabling the REST interface on routerrpc.
It provides REST clients that don't support server-side streaming
via keep-alive connections to use the streaming endpoint in the
typical request/response pattern. The url just needs to contain
?no_inflight_updates=true and only the terminal response is sent
back before the connection is closed.
2020-04-21 17:02:09 -07:00
Joost Jager
d451ef4ee1
routerrpc: rename rpcs to SendPaymentV2 and TrackPaymentV2
The message in the response stream changed. Rename the calls themselves,
to prevent older applications from getting decode errors. Especially
troublesome is the case where the request is executed (send payment),
but the application can't read the outcome (payment sent or not?)
2020-04-21 20:36:58 +02:00
Olaoluwa Osuntokun
7b066ad91e
Merge pull request #4190 from guggero/fix-windows-build
make+lnd+config: fix Windows build and version string
2020-04-14 19:57:26 -07:00
Oliver Gugger
1e3b0672d7
config+lnd+lncli: add commit back to version string 2020-04-14 15:51:44 +02:00
Joost Jager
969eecc7d2
routing+routerrpc+lncli: rename MaxHtlcs to MaxShards 2020-04-14 10:31:59 +02:00
Conner Fromknecht
f93a8ab7d0
cmd/lncli: add version command that reads verrpc.GetVersion 2020-04-10 16:39:31 -07:00
Joost Jager
f5c3f930c4
lncli: expose max payment htlcs 2020-04-09 08:20:50 +02:00
Joost Jager
3ed3c90efe
lncli: add show_inflight flag 2020-04-08 09:26:35 +02:00
Joost Jager
af4abe7d58
routing+routerrpc: notify full payment structures
This commit fixes the inconsistency between the payment state as
reported by routerrpc.SendPayment/routerrpc.TrackPayment and the main
rpc ListPayments call.

In addition to that, payment state changes are now sent out for every
state change. This opens the door to user interfaces giving more
feedback to the user about the payment process. This is especially
interesting for multi-part payments.
2020-04-08 09:26:33 +02:00
Olaoluwa Osuntokun
7e6f3ece23
Merge pull request #3960 from bitromortac/listpayments-pagination
channeldb+lnrpc+lncli: listpayments pagination support
2020-04-07 17:06:37 -07:00
bitromortac
4593cfa6c6 lncli: modify listpayments to use queried payments and update cli docs 2020-04-07 07:03:51 +02:00
Conner Fromknecht
3233388750
cmd/lncli: move invoice-related cmds to Invoices category
The Payments category is getting quite large, so this commit breaks out
the invoice-related commands into their own category.
2020-04-06 14:24:08 -07:00
Conner Fromknecht
4aceaba1be
cmd/lncli: move invoice commands to cmd_invoice.go 2020-04-06 14:23:21 -07:00
Joost Jager
6b649eeb10
lncli: remove unused type chain 2020-03-31 22:05:00 +02:00
Joost Jager
37849194f4
lncli: add trackpayment command 2020-03-31 21:41:32 +02:00
Joost Jager
dead6a772a
lncli: use routerrpc for payments 2020-03-31 21:41:28 +02:00
Joost Jager
f060da3971
lncli: move payment commands to separate file 2020-03-31 21:41:26 +02:00