mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-12-06 18:53:21 +01:00
rpc: Push down safe mode checks
This contains most of the changes of 10563 "remove safe mode", but doesn't remove the safe mode yet, but put an `ObserveSafeMode()` check in individual calls with okSafeMode=false. This cleans up the ugly "okSafeMode" flag from the dispatch tables, which is not a concern for the RPC server. Extra-author: Wladimir J. van der Laan <laanwj@gmail.com>
This commit is contained in:
committed by
Wladimir J. van der Laan
parent
cee4fe1d53
commit
ec6902d0ea
@@ -649,20 +649,20 @@ UniValue echo(const JSONRPCRequest& request)
|
||||
}
|
||||
|
||||
static const CRPCCommand commands[] =
|
||||
{ // category name actor (function) okSafeMode
|
||||
{ // category name actor (function) argNames
|
||||
// --------------------- ------------------------ ----------------------- ----------
|
||||
{ "control", "getinfo", &getinfo, true, {} }, /* uses wallet if enabled */
|
||||
{ "control", "getmemoryinfo", &getmemoryinfo, true, {"mode"} },
|
||||
{ "util", "validateaddress", &validateaddress, true, {"address"} }, /* uses wallet if enabled */
|
||||
{ "util", "createmultisig", &createmultisig, true, {"nrequired","keys"} },
|
||||
{ "util", "verifymessage", &verifymessage, true, {"address","signature","message"} },
|
||||
{ "util", "signmessagewithprivkey", &signmessagewithprivkey, true, {"privkey","message"} },
|
||||
{ "control", "getinfo", &getinfo, {} }, /* uses wallet if enabled */
|
||||
{ "control", "getmemoryinfo", &getmemoryinfo, {"mode"} },
|
||||
{ "util", "validateaddress", &validateaddress, {"address"} }, /* uses wallet if enabled */
|
||||
{ "util", "createmultisig", &createmultisig, {"nrequired","keys"} },
|
||||
{ "util", "verifymessage", &verifymessage, {"address","signature","message"} },
|
||||
{ "util", "signmessagewithprivkey", &signmessagewithprivkey, {"privkey","message"} },
|
||||
|
||||
/* Not shown in help */
|
||||
{ "hidden", "setmocktime", &setmocktime, true, {"timestamp"}},
|
||||
{ "hidden", "echo", &echo, true, {"arg0","arg1","arg2","arg3","arg4","arg5","arg6","arg7","arg8","arg9"}},
|
||||
{ "hidden", "echojson", &echo, true, {"arg0","arg1","arg2","arg3","arg4","arg5","arg6","arg7","arg8","arg9"}},
|
||||
{ "hidden", "logging", &logging, true, {"include", "exclude"}},
|
||||
{ "hidden", "setmocktime", &setmocktime, {"timestamp"}},
|
||||
{ "hidden", "echo", &echo, {"arg0","arg1","arg2","arg3","arg4","arg5","arg6","arg7","arg8","arg9"}},
|
||||
{ "hidden", "echojson", &echo, {"arg0","arg1","arg2","arg3","arg4","arg5","arg6","arg7","arg8","arg9"}},
|
||||
{ "hidden", "logging", &logging, {"include", "exclude"}},
|
||||
};
|
||||
|
||||
void RegisterMiscRPCCommands(CRPCTable &t)
|
||||
|
||||
Reference in New Issue
Block a user