aboutsummaryrefslogtreecommitdiff
path: root/src/rpc
diff options
context:
space:
mode:
authorKarl-Johan Alm <karljohan-alm@garage.co.jp>2021-08-20 15:09:03 +0900
committerKarl-Johan Alm <karljohan-alm@garage.co.jp>2022-08-05 09:48:09 +0900
commitdb10cf8ae36693cb4d3ed1b47b84709cf9c0d849 (patch)
tree30416f1b8bc1e2a6efcc60c5dab7b8dabd1e0c88 /src/rpc
parent701a64f548662e01821765b2934b6e4b321fda6d (diff)
rpc/wallet: add simulaterawtransaction RPC
This command iterates over the inputs and outputs of the given transactions, and tallies up the balance change for the given wallet. This can be useful e.g. when verifying that a coin join like transaction doesn't contain unexpected inputs that the wallet will then sign for unintentionally.
Diffstat (limited to 'src/rpc')
-rw-r--r--src/rpc/client.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/rpc/client.cpp b/src/rpc/client.cpp
index 9be3ab7df0..ee287656b6 100644
--- a/src/rpc/client.cpp
+++ b/src/rpc/client.cpp
@@ -147,6 +147,8 @@ static const CRPCConvertParam vRPCConvertParams[] =
{ "sendall", 1, "conf_target" },
{ "sendall", 3, "fee_rate"},
{ "sendall", 4, "options" },
+ { "simulaterawtransaction", 0, "rawtxs" },
+ { "simulaterawtransaction", 1, "options" },
{ "importprivkey", 2, "rescan" },
{ "importaddress", 2, "rescan" },
{ "importaddress", 3, "p2sh" },