aboutsummaryrefslogtreecommitdiff
path: root/src/rpc/rawtransaction_util.h
diff options
context:
space:
mode:
authorfurszy <matiasfurszyfer@protonmail.com>2023-08-21 17:50:09 -0300
committerfurszy <matiasfurszyfer@protonmail.com>2024-05-03 14:20:45 -0300
commit9d9a91c4ea6b3bb32ef4131bca86f1d6683fc901 (patch)
tree7b2e9342ff9a9ba09b29149354612a1cd4588160 /src/rpc/rawtransaction_util.h
parent0c9fedfc45fa7cbd6801ca5fd756863ec9a6911c (diff)
rpc: bugfix, incorrect segwit redeem script size used in signrawtransactionwithkey
The process currently fails to sign redeem scripts that are longer than 520 bytes. Even when it shouldn't. The 520 bytes redeem scripts limit is a legacy p2sh rule, and not a segwit limitation. Segwit redeem scripts are not restricted by the script item size limit. The reason why this occurs, is the usage of the same keystore used by the legacy spkm. Which contains blockage for any redeem scripts longer than the script item size limit.
Diffstat (limited to 'src/rpc/rawtransaction_util.h')
-rw-r--r--src/rpc/rawtransaction_util.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/rpc/rawtransaction_util.h b/src/rpc/rawtransaction_util.h
index 964d0b095b..40d6bbba87 100644
--- a/src/rpc/rawtransaction_util.h
+++ b/src/rpc/rawtransaction_util.h
@@ -12,7 +12,7 @@
#include <optional>
struct bilingual_str;
-class FillableSigningProvider;
+struct FlatSigningProvider;
class UniValue;
struct CMutableTransaction;
class Coin;
@@ -38,7 +38,7 @@ void SignTransactionResultToJSON(CMutableTransaction& mtx, bool complete, const
* @param keystore A pointer to the temporary keystore if there is one
* @param coins Map of unspent outputs - coins in mempool and current chain UTXO set, may be extended by previous txns outputs after call
*/
-void ParsePrevouts(const UniValue& prevTxsUnival, FillableSigningProvider* keystore, std::map<COutPoint, Coin>& coins);
+void ParsePrevouts(const UniValue& prevTxsUnival, FlatSigningProvider* keystore, std::map<COutPoint, Coin>& coins);
/** Normalize univalue-represented inputs and add them to the transaction */
void AddInputs(CMutableTransaction& rawTx, const UniValue& inputs_in, bool rbf);