Merge pull request #10541

dae0f4c wallet_rpc_server: add missing trusted daemon check (selsta)
This commit is contained in:
tobtoht
2026-05-13 11:04:46 +00:00
+6
View File
@@ -3464,6 +3464,12 @@ namespace tools
bool wallet_rpc_server::on_rescan_spent(const wallet_rpc::COMMAND_RPC_RESCAN_SPENT::request& req, wallet_rpc::COMMAND_RPC_RESCAN_SPENT::response& res, epee::json_rpc::error& er, const connection_context *ctx)
{
CHECK_IF_RESTRICTED_BACKGROUND_SYNCING();
if (!m_wallet->is_trusted_daemon())
{
er.code = WALLET_RPC_ERROR_CODE_UNKNOWN_ERROR;
er.message = "This command requires a trusted daemon.";
return false;
}
try
{
m_wallet->rescan_spent();