merge beta->master

This commit is contained in:
jl777
2018-08-08 23:12:38 -11:00
222 changed files with 16174 additions and 2993 deletions

View File

@@ -238,9 +238,11 @@ UniValue help(const UniValue& params, bool fHelp)
return tableRPC.help(strCommand);
}
extern char ASSETCHAINS_SYMBOL[KOMODO_ASSETCHAIN_MAXLEN];
UniValue stop(const UniValue& params, bool fHelp)
{
char buf[64];
// Accept the deprecated and ignored 'detach' boolean argument
if (fHelp || params.size() > 1)
throw runtime_error(
@@ -248,7 +250,8 @@ UniValue stop(const UniValue& params, bool fHelp)
"\nStop Komodo server.");
// Shutdown will take long enough that the response should get back
StartShutdown();
return "Komodo server stopping";
sprintf(buf,"%s Komodo server stopping",ASSETCHAINS_SYMBOL);
return buf;
}
/**
@@ -277,10 +280,13 @@ static const CRPCCommand vRPCCommands[] =
{ "network", "clearbanned", &clearbanned, true },
/* Block chain and UTXO */
{ "blockchain", "coinsupply", &coinsupply, true },
{ "blockchain", "getblockchaininfo", &getblockchaininfo, true },
{ "blockchain", "getbestblockhash", &getbestblockhash, true },
{ "blockchain", "getblockcount", &getblockcount, true },
{ "blockchain", "getblock", &getblock, true },
{ "blockchain", "getblockdeltas", &getblockdeltas, false },
{ "blockchain", "getblockhashes", &getblockhashes, true },
{ "blockchain", "getblockhash", &getblockhash, true },
{ "blockchain", "getblockheader", &getblockheader, true },
{ "blockchain", "getchaintips", &getchaintips, true },
@@ -292,6 +298,7 @@ static const CRPCCommand vRPCCommands[] =
{ "blockchain", "verifytxoutproof", &verifytxoutproof, true },
{ "blockchain", "gettxoutsetinfo", &gettxoutsetinfo, true },
{ "blockchain", "verifychain", &verifychain, true },
{ "blockchain", "getspentinfo", &getspentinfo, false },
{ "blockchain", "paxprice", &paxprice, true },
{ "blockchain", "paxpending", &paxpending, true },
{ "blockchain", "paxprices", &paxprices, true },
@@ -302,6 +309,16 @@ static const CRPCCommand vRPCCommands[] =
{ "blockchain", "kvsearch", &kvsearch, true },
{ "blockchain", "kvupdate", &kvupdate, true },
/* Cross chain utilities */
{ "crosschain", "MoMoMdata", &MoMoMdata, true },
{ "crosschain", "calc_MoM", &calc_MoM, true },
{ "crosschain", "height_MoM", &height_MoM, true },
{ "crosschain", "assetchainproof", &assetchainproof, true },
{ "crosschain", "crosschainproof", &crosschainproof, true },
{ "crosschain", "migrate_converttoexport", &migrate_converttoexport, true },
{ "crosschain", "migrate_createimporttransaction", &migrate_createimporttransaction, true },
{ "crosschain", "migrate_completeimporttransaction", &migrate_completeimporttransaction, true },
/* Mining */
{ "mining", "getblocktemplate", &getblocktemplate, true },
{ "mining", "getmininginfo", &getmininginfo, true },
@@ -329,6 +346,67 @@ static const CRPCCommand vRPCCommands[] =
#ifdef ENABLE_WALLET
{ "rawtransactions", "fundrawtransaction", &fundrawtransaction, false },
#endif
/* auction */
{ "auction", "auctionaddress", &auctionaddress, true },
/* lotto */
{ "lotto", "lottoaddress", &lottoaddress, true },
/* fsm */
{ "FSM", "FSMaddress", &FSMaddress, true },
{ "FSMcreate", "FSMcreate", &FSMcreate, true },
{ "FSMlist", "FSMlist", &FSMlist, true },
{ "FSMinfo", "FSMinfo", &FSMinfo, true },
/* rewards */
{ "rewards", "rewardslist", &rewardslist, true },
{ "rewards", "rewardsinfo", &rewardsinfo, true },
{ "rewards", "rewardscreatefunding", &rewardscreatefunding, true },
{ "rewards", "rewardsaddfunding", &rewardsaddfunding, true },
{ "rewards", "rewardslock", &rewardslock, true },
{ "rewards", "rewardsunlock", &rewardsunlock, true },
{ "rewards", "rewardsaddress", &rewardsaddress, true },
/* faucet */
{ "faucet", "faucetinfo", &faucetinfo, true },
{ "faucet", "faucetfund", &faucetfund, true },
{ "faucet", "faucetget", &faucetget, true },
{ "faucet", "faucetaddress", &faucetaddress, true },
/* dice */
{ "dice", "dicelist", &dicelist, true },
{ "dice", "diceinfo", &diceinfo, true },
{ "dice", "dicefund", &dicefund, true },
{ "dice", "diceaddfunds", &diceaddfunds, true },
{ "dice", "dicebet", &dicebet, true },
{ "dice", "dicefinish", &dicefinish, true },
{ "dice", "dicestatus", &dicestatus, true },
{ "dice", "diceaddress", &diceaddress, true },
/* tokens */
{ "tokens", "tokeninfo", &tokeninfo, true },
{ "tokens", "tokenlist", &tokenlist, true },
{ "tokens", "tokenorders", &tokenorders, true },
{ "tokens", "tokenaddress", &tokenaddress, true },
{ "tokens", "tokenbalance", &tokenbalance, true },
{ "tokens", "tokencreate", &tokencreate, true },
{ "tokens", "tokentransfer", &tokentransfer, true },
{ "tokens", "tokenbid", &tokenbid, true },
{ "tokens", "tokencancelbid", &tokencancelbid, true },
{ "tokens", "tokenfillbid", &tokenfillbid, true },
{ "tokens", "tokenask", &tokenask, true },
//{ "tokens", "tokenswapask", &tokenswapask, true },
{ "tokens", "tokencancelask", &tokencancelask, true },
{ "tokens", "tokenfillask", &tokenfillask, true },
//{ "tokens", "tokenfillswap", &tokenfillswap, true },
/* Address index */
{ "addressindex", "getaddressmempool", &getaddressmempool, true },
{ "addressindex", "getaddressutxos", &getaddressutxos, false },
{ "addressindex", "getaddressdeltas", &getaddressdeltas, false },
{ "addressindex", "getaddresstxids", &getaddresstxids, false },
{ "addressindex", "getaddressbalance", &getaddressbalance, false },
{ "addressindex", "getsnapshot", &getsnapshot, false },
/* Utility functions */
{ "util", "createmultisig", &createmultisig, true },
@@ -342,12 +420,12 @@ static const CRPCCommand vRPCCommands[] =
{ "util", "jumblr_pause", &jumblr_pause, true },
{ "util", "jumblr_resume", &jumblr_resume, true },
{ "util", "invalidateblock", &invalidateblock, true },
{ "util", "reconsiderblock", &reconsiderblock, true },
/* Not shown in help */
{ "hidden", "invalidateblock", &invalidateblock, true },
{ "hidden", "reconsiderblock", &reconsiderblock, true },
{ "hidden", "setmocktime", &setmocktime, true },
#ifdef ENABLE_WALLET
{ "hidden", "resendwallettransactions", &resendwallettransactions, true},
{ "wallet", "resendwallettransactions", &resendwallettransactions, true},
#endif
#ifdef ENABLE_WALLET
@@ -361,7 +439,9 @@ static const CRPCCommand vRPCCommands[] =
{ "wallet", "getaccount", &getaccount, true },
{ "wallet", "getaddressesbyaccount", &getaddressesbyaccount, true },
{ "wallet", "getbalance", &getbalance, false },
{ "wallet", "getbalance64", &getbalance64, false },
{ "wallet", "getnewaddress", &getnewaddress, true },
// { "wallet", "getnewaddress64", &getnewaddress64, true },
{ "wallet", "getrawchangeaddress", &getrawchangeaddress, true },
{ "wallet", "getreceivedbyaccount", &getreceivedbyaccount, false },
{ "wallet", "getreceivedbyaddress", &getreceivedbyaddress, false },