mirror of
https://github.com/bitcoin/bitcoin.git
synced 2026-04-18 11:37:40 +02:00
Merge #14454: Add SegWit support to importmulti
c11875c590Add segwit address tests for importmulti (MeshCollider)201451b1caMake getaddressinfo return solvability (MeshCollider)1753d217eaAdd release notes for importmulti segwit change (MeshCollider)353c064596Fix typo in test_framework/blocktools (MeshCollider)f6ed748cf0Add SegWit support to importmulti with some ProcessImport cleanup (MeshCollider) Pull request description: Add support for segwit to importmulti, supports P2WSH, P2WPKH, P2SH-P2WPKH, P2SH-P2WSH. Adds a new `witnessscript` parameter which must be used for the witness scripts in the relevant situations. Also includes some tests for the various import types. ~Also makes the change in #14019 redundant, but cherry-picks the test from that PR to test the behavior (@achow101).~ Fixes #12253, also addresses the second point in #12703, and fixes #14407 Tree-SHA512: 775a755c524d1c387a99acddd772f677d2073876b72403dcfb92c59f9b405ae13ceedcf4dbd2ee1d7a8db91c494f67ca137161032ee3a2071282eeb411be090a
This commit is contained in:
@@ -3455,6 +3455,7 @@ UniValue getaddressinfo(const JSONRPCRequest& request)
|
||||
" \"address\" : \"address\", (string) The bitcoin address validated\n"
|
||||
" \"scriptPubKey\" : \"hex\", (string) The hex-encoded scriptPubKey generated by the address\n"
|
||||
" \"ismine\" : true|false, (boolean) If the address is yours or not\n"
|
||||
" \"solvable\" : true|false, (boolean) If the address is solvable by the wallet\n"
|
||||
" \"iswatchonly\" : true|false, (boolean) If the address is watchonly\n"
|
||||
" \"isscript\" : true|false, (boolean) If the key is a script\n"
|
||||
" \"iswitness\" : true|false, (boolean) If the address is a witness address\n"
|
||||
@@ -3509,6 +3510,7 @@ UniValue getaddressinfo(const JSONRPCRequest& request)
|
||||
isminetype mine = IsMine(*pwallet, dest);
|
||||
ret.pushKV("ismine", bool(mine & ISMINE_SPENDABLE));
|
||||
ret.pushKV("iswatchonly", bool(mine & ISMINE_WATCH_ONLY));
|
||||
ret.pushKV("solvable", IsSolvable(*pwallet, scriptPubKey));
|
||||
UniValue detail = DescribeWalletAddress(pwallet, dest);
|
||||
ret.pushKVs(detail);
|
||||
if (pwallet->mapAddressBook.count(dest)) {
|
||||
|
||||
Reference in New Issue
Block a user