mirror of
https://github.com/monero-project/monero.git
synced 2026-07-30 23:50:24 -07:00
Merge pull request #10480
04eeb3b wallet2: ensure daemon returns correct tx for spend proof (selsta)
This commit is contained in:
@@ -12604,6 +12604,7 @@ std::string wallet2::get_spend_proof(const crypto::hash &txid, const std::string
|
||||
cryptonote::transaction tx;
|
||||
crypto::hash tx_hash;
|
||||
THROW_WALLET_EXCEPTION_IF(!get_pruned_tx(res.txs[0], tx, tx_hash), error::wallet_internal_error, "Failed to get tx from daemon");
|
||||
THROW_WALLET_EXCEPTION_IF(tx_hash != txid, error::wallet_internal_error, "Failed to get the right transaction from daemon");
|
||||
|
||||
std::vector<std::vector<crypto::signature>> signatures;
|
||||
|
||||
@@ -12725,6 +12726,7 @@ bool wallet2::check_spend_proof(const crypto::hash &txid, const std::string &mes
|
||||
cryptonote::transaction tx;
|
||||
crypto::hash tx_hash;
|
||||
THROW_WALLET_EXCEPTION_IF(!get_pruned_tx(res.txs[0], tx, tx_hash), error::wallet_internal_error, "failed to get tx from daemon");
|
||||
THROW_WALLET_EXCEPTION_IF(tx_hash != txid, error::wallet_internal_error, "Failed to get the right transaction from daemon");
|
||||
|
||||
// check signature size
|
||||
size_t num_sigs = 0;
|
||||
|
||||
Reference in New Issue
Block a user