195 Commits
Author SHA1 Message Date
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 a25d5255fb walletrpc: add pkScript and value to UTXO lease 2022-05-12 10:24:39 +02:00
positiveblue d4021c5aca lnrpc: fix log.go files
The `log.go` file of each subserver is a copy and paste of the others.
All of them have the same typo, an extra space in a comment, and the
the definition of a function not used anywhere.
2022-04-01 18:12:59 -07:00
Oliver Gugger c73cf03a55 multi: add p2tr keyspend wallet support 2022-03-24 18:02:38 +01:00
Oliver Gugger 1670000fd8 walletrpc: add debug log statement for invalid PSBT
To help debug remote signing issues, it's helpful to get the raw PSBT
that failed to be parsed. This is necessary since serializing an invalid
PSBT is allowed and the checks only fail when trying to de-serialize
such an invalid packet.
2022-03-24 09:28:27 +01:00
Bjarne Magnussen 188b39268d lnrpc: add DestOutput to the protobuf 2022-03-23 11:29:09 +01:00
Olaoluwa Osuntokun f13399bc49 Merge pull request #6190 from ErikEk/listunspent-deafult-values
walletrpc: add default values to listunspent
2022-03-16 16:16:45 -07:00
Oliver Gugger 95c270d1f8 Merge pull request #6217 from liviu-ln/psbt-finalize-check
walletrpc: return an error when finalizing an already complete PSBT
2022-03-14 10:45:24 +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
ErikEk 74db83bbfb walletrpc: add default values to listunspent 2022-02-17 10:05:16 +01:00
Oliver Gugger 13f187046b multi: fix issues reported by whitespace linter 2022-02-15 16:26:08 +01:00
Oliver Gugger 895a2e497b multi: formatting and comment fixes 2022-02-10 11:02:02 +01:00
Liviu e11c41ba8f walletrpc: return an error when finalizing an already complete PSBT
Return an error to the client if attempting to finalize a PSBS with no missing signatures.
2022-01-30 21:37:32 -08:00
Dimitris Apostolou 530a2059e5 multi: Fix typos [skip ci] 2022-01-24 12:19:02 +02:00
Oliver Gugger 8994d86a1d walletrpc+itest: add SignPsbt RPC 2022-01-06 14:35:07 +01:00
Michael Rhee 7c18fb64ae lnrpc: add public key detail to signrpc KeyDescriptor [skip ci]
Clarification that KeyDescriptor describes the public key in
raw_key_bytes and the key_loc identifies the private key. Helps
clarify responses from calls like DeriveKey and DeriveNextKey from
WalletKit.

Fixes #5899
2021-11-02 07:57:12 -05:00
Oliver Gugger 78b700387c cmd/lncli+walletrpc: add createwatchonly command 2021-10-14 15:42:58 +02:00
Oliver Gugger 1541b2ef1b multi: create and list all default internal accounts 2021-10-14 15:42:56 +02:00
Oliver Gugger a3addcc927 multi: forward SendCoins call over RPC 2021-10-14 15:42:52 +02:00
Oliver Gugger 19db382e24 multi: forward address and import calls over RPC
In order to support the full range of on-chain functionality, including
importing watch-only accounts in the watch-only instance, we need to
forward some calls like creating new addresses or importing accounts to
the remote signing instance.
2021-10-14 15:42:51 +02: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
Oliver Gugger ae2e9541a4 walletrpc: export wallet kit sub server name
We'll want to re-use the PSBT funding functionality from the wallet kit
sub server in the main RPC server. To be able to dynamically obtain an
instance of the wallet kit server we need to know its name under which
it registers itself in the list of sub server. We export the name so we
don't have to hard code it in the main server.
2021-09-02 12:13:46 +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
Oliver Gugger 702f0d7ced lnrpc: generate JSON/WASM client stubs 2021-08-03 13:44:36 +02:00
Oliver Gugger dd749fe580 lnrpc: update grpc-gateway library to v2 2021-07-27 13:09:59 +02:00
Oliver Gugger 235efc04e4 docs+lnrpc: rename rpc.proto to lightning.proto
To avoid a naming conflict with etcd, we rename our very generic
rpc.proto to lightning.proto to match the service name that's declared
within. This will break many external tutorials and possibly also our
API docs but the change needs to be done eventually.
2021-07-27 12:59:56 +02:00
Oliver Gugger 62888894d2 walletrpc: add missing REST body annotation
The missing body annotation caused the library to ignore any parameters
sent to this RPC endpoint when using the REST proxy.
2021-07-27 12:59:55 +02:00
Oliver Gugger 4a0025c1b7 lnrpc: split REST annotations into service files
As a preparation for the migration to the grpc-gateway/v2 library we
declare each service's REST annotations in its own file. This is
optional in the v1 library but mandatory in v2.
2021-07-27 12:59:52 +02:00
Evan Kaloudis 8d5a3d6bb9 Fix typo on FundPsbt fee definition error 2021-05-30 14:28:59 -04: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 e180023843 walletrpc: expose dry run support for ImportAccount 2021-05-07 13:06:27 -07:00
Andras Banki-Horvath e5f249ad51 mod: integrate latest btcwallet and bump protobuf and grpc 2021-05-04 17:33:09 +02:00
Tom Kirkpatrick 76706c7473 walletrpc: minConfs and spendUnconfirmed for FundPtsb 2021-04-22 20:35:00 +02:00
Wilmer Paulino 5301c7e83f walletrpc: expose wallet import related RPCs 2021-04-05 15:41:10 -07:00
Wilmer Paulino a7211b34c3 rpc: expose account parameter for several wallet RPCs 2021-04-05 15:41:07 -07:00
Wilmer Paulino f91e7cde59 lnwallet: expose optional account filter for several WalletController methods 2021-04-05 15:41:06 -07:00
Wilmer Paulino f38bf4d7fa lnwallet: expose required account parameter for WalletController methods 2021-04-05 15:41:05 -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
Joost Jager 9398220568 walletrpc: add ListLeases 2021-03-13 08:45:52 +01:00
Joost Jager b8e54fffbf walletrpc: extract leases marshall function 2021-03-13 08:45:52 +01:00
Joost Jager 37331a5ab2 walletrpc: use locked utxo struct from wtxmgr 2021-03-13 08:45:52 +01:00
Joost Jager 927f17be32 walletrpc: parameterize output lease duration 2021-03-13 08:45:52 +01:00
Joost Jager 5ba0f8e355 lnwallet: bump btcwallet 2021-03-13 08:45:52 +01:00
Johan T. Halseth 4ea494e8c5 lnrpc: wrap subservers in GrpcHandler
In order to be able to register the subservers with the root grpc server
before we have all dependencies available, we wrap them in an
GrpcHandler struct. This struct will initially hold an empty reference
to the subservers, which allows us to register with the GRPC server, and
later populate and create the subserver instance.
2021-03-11 13:05:23 +01:00
carla 887ff442db multi: fix verbose output for listsweeps and check all against wallet
Previously, the verbose output of listsweeps would fail if we did not
find some sweeps in our wallet's listtransactions output. This could be
the case for sweeps that were rbf-ed, so the endpoint would fail. This
commit also updates the listsweeps endpoint to always check against the
wallet, so that we do not return these discarded sweeps that never
confirmed.
2020-11-13 13:59:52 +02:00
Graham Krizek 5aa0d26251 lnrpc+macaroon: skip subserver macaroons on stateless_init
This will prevent the subservers from writing macaroons to disk
when the stateless_init flag is set to true. It accomplishes
this by storing the StatelessInit value in the Macaroon Service.
2020-11-07 11:24:35 +01:00
yyforyongyu 2cb42594a9 trivial: fix make rpc-format 2020-10-25 18:51:42 +08:00
Oliver Gugger 843efc324b walletrpc: serialize TXID not outpoint
The txid_str field of a locked UTXO's outpoint shouldn't contain the
output index but only the reverse order hex serialized transaction ID.
2020-10-06 10:59:51 +02:00
Oliver Gugger 9a063355e2 walletrpc: disallow locking with internal ID
The internal lock ID that the wallet kit subserver uses to lock inputs
for itself shouldn't be allowed to be used when locking inputs manually
over the RPC.
2020-10-03 10:34:55 +02:00