Fabcoin Core  0.16.2
P2P Digital Currency
Classes | Functions
rpcwallet.cpp File Reference
#include <amount.h>
#include <base58.h>
#include <chain.h>
#include <consensus/validation.h>
#include <core_io.h>
#include <httpserver.h>
#include <init.h>
#include <net.h>
#include <policy/feerate.h>
#include <policy/fees.h>
#include <policy/policy.h>
#include <policy/rbf.h>
#include <rpc/mining.h>
#include <rpc/server.h>
#include <script/sign.h>
#include <timedata.h>
#include <util.h>
#include <utilmoneystr.h>
#include <validation.h>
#include <wallet/coincontrol.h>
#include <wallet/feebumper.h>
#include <wallet/wallet.h>
#include <wallet/walletdb.h>
#include <stdint.h>
#include <univalue.h>
#include <boost/assign/list_of.hpp>
#include <boost/optional.hpp>
Include dependency graph for rpcwallet.cpp:

Go to the source code of this file.

Classes

class  Witnessifier
 
struct  tallyitem
 

Functions

CWalletGetWalletForJSONRPCRequest (const JSONRPCRequest &request)
 Figures out what wallet, if any, to use for a JSONRPCRequest. More...
 
std::string HelpRequiringPassphrase (CWallet *const pwallet)
 
bool EnsureWalletIsAvailable (CWallet *const pwallet, bool avoidException)
 
void EnsureWalletIsUnlocked (CWallet *const pwallet)
 
void WalletTxToJSON (const CWalletTx &wtx, UniValue &entry)
 
std::string AccountFromValue (const UniValue &value)
 
UniValue getnewaddress (const JSONRPCRequest &request)
 
CFabcoinAddress GetAccountAddress (CWallet *const pwallet, std::string strAccount, bool bForceNew=false)
 
UniValue getaccountaddress (const JSONRPCRequest &request)
 
UniValue getrawchangeaddress (const JSONRPCRequest &request)
 
UniValue setaccount (const JSONRPCRequest &request)
 
UniValue getaccount (const JSONRPCRequest &request)
 
UniValue getaddressesbyaccount (const JSONRPCRequest &request)
 
UniValue sendtoaddress (const JSONRPCRequest &request)
 
bool base58toVMAddress (std::string &strAddr, std::vector< unsigned char > &contractAddress)
 
UniValue getvmaddress (const JSONRPCRequest &request)
 
UniValue getfabaddressbyvm (const JSONRPCRequest &request)
 
UniValue createcontract (const JSONRPCRequest &request)
 
UniValue sendtocontract (const JSONRPCRequest &request)
 
UniValue listaddressgroupings (const JSONRPCRequest &request)
 
UniValue signmessage (const JSONRPCRequest &request)
 
UniValue getreceivedbyaddress (const JSONRPCRequest &request)
 
UniValue getreceivedbyaccount (const JSONRPCRequest &request)
 
UniValue getbalance (const JSONRPCRequest &request)
 
UniValue getunconfirmedbalance (const JSONRPCRequest &request)
 
UniValue movecmd (const JSONRPCRequest &request)
 
UniValue sendfrom (const JSONRPCRequest &request)
 
UniValue sendmany (const JSONRPCRequest &request)
 
CScript _createmultisig_redeemScript (CWallet *const pwallet, const UniValue &params)
 Used by addmultisigaddress / createmultisig: More...
 
UniValue addmultisigaddress (const JSONRPCRequest &request)
 
UniValue addwitnessaddress (const JSONRPCRequest &request)
 
UniValue getnewwitnessaddress (const JSONRPCRequest &request)
 
UniValue ListReceived (CWallet *const pwallet, const UniValue &params, bool fByAccounts)
 
UniValue listreceivedbyaddress (const JSONRPCRequest &request)
 
UniValue listreceivedbyaccount (const JSONRPCRequest &request)
 
void ListTransactions (CWallet *const pwallet, const CWalletTx &wtx, const std::string &strAccount, int nMinDepth, bool fLong, UniValue &ret, const isminefilter &filter)
 List transactions based on the given criteria. More...
 
void AcentryToJSON (const CAccountingEntry &acentry, const std::string &strAccount, UniValue &ret)
 
UniValue listtransactions (const JSONRPCRequest &request)
 
UniValue listaccounts (const JSONRPCRequest &request)
 
UniValue listsinceblock (const JSONRPCRequest &request)
 
UniValue gettransaction (const JSONRPCRequest &request)
 
UniValue abandontransaction (const JSONRPCRequest &request)
 
UniValue backupwallet (const JSONRPCRequest &request)
 
UniValue keypoolrefill (const JSONRPCRequest &request)
 
UniValue walletpassphrase (const JSONRPCRequest &request)
 
UniValue walletpassphrasechange (const JSONRPCRequest &request)
 
UniValue walletlock (const JSONRPCRequest &request)
 
UniValue encryptwallet (const JSONRPCRequest &request)
 
UniValue lockunspent (const JSONRPCRequest &request)
 
UniValue listlockunspent (const JSONRPCRequest &request)
 
UniValue settxfee (const JSONRPCRequest &request)
 
UniValue getwalletinfo (const JSONRPCRequest &request)
 
UniValue listwallets (const JSONRPCRequest &request)
 
UniValue resendwallettransactions (const JSONRPCRequest &request)
 
UniValue listunspent (const JSONRPCRequest &request)
 
UniValue fundrawtransaction (const JSONRPCRequest &request)
 
UniValue bumpfee (const JSONRPCRequest &request)
 
UniValue generate (const JSONRPCRequest &request)
 
UniValue abortrescan (const JSONRPCRequest &request)
 
UniValue dumpprivkey (const JSONRPCRequest &request)
 
UniValue importprivkey (const JSONRPCRequest &request)
 
UniValue importaddress (const JSONRPCRequest &request)
 
UniValue importpubkey (const JSONRPCRequest &request)
 
UniValue dumpwallet (const JSONRPCRequest &request)
 
UniValue importwallet (const JSONRPCRequest &request)
 
UniValue importprunedfunds (const JSONRPCRequest &request)
 
UniValue removeprunedfunds (const JSONRPCRequest &request)
 
UniValue importmulti (const JSONRPCRequest &request)
 
void RegisterWalletRPCCommands (CRPCTable &t)
 

Function Documentation

CScript _createmultisig_redeemScript ( CWallet *const  pwallet,
const UniValue params 
)

Used by addmultisigaddress / createmultisig:

Definition at line 260 of file misc.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

UniValue abandontransaction ( const JSONRPCRequest request)

Definition at line 2522 of file rpcwallet.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

UniValue abortrescan ( const JSONRPCRequest request)

Definition at line 157 of file rpcdump.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

std::string AccountFromValue ( const UniValue value)

Definition at line 123 of file rpcwallet.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

void AcentryToJSON ( const CAccountingEntry acentry,
const std::string &  strAccount,
UniValue ret 
)

Definition at line 2078 of file rpcwallet.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

UniValue addmultisigaddress ( const JSONRPCRequest request)

Definition at line 1586 of file rpcwallet.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

UniValue addwitnessaddress ( const JSONRPCRequest request)

Definition at line 1693 of file rpcwallet.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

UniValue backupwallet ( const JSONRPCRequest request)

Definition at line 2559 of file rpcwallet.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

bool base58toVMAddress ( std::string &  strAddr,
std::vector< unsigned char > &  contractAddress 
)

Definition at line 536 of file rpcwallet.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

UniValue bumpfee ( const JSONRPCRequest request)

Definition at line 3445 of file rpcwallet.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

UniValue createcontract ( const JSONRPCRequest request)

Definition at line 594 of file rpcwallet.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

UniValue dumpprivkey ( const JSONRPCRequest request)

Definition at line 547 of file rpcdump.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

UniValue dumpwallet ( const JSONRPCRequest request)

Definition at line 588 of file rpcdump.cpp.

Here is the caller graph for this function:

UniValue encryptwallet ( const JSONRPCRequest request)

Definition at line 2775 of file rpcwallet.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

bool EnsureWalletIsAvailable ( CWallet *const  pwallet,
bool  avoidException 
)

Definition at line 61 of file rpcwallet.cpp.

Here is the call graph for this function:

void EnsureWalletIsUnlocked ( CWallet *const  pwallet)

Definition at line 78 of file rpcwallet.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

UniValue fundrawtransaction ( const JSONRPCRequest request)

Definition at line 3271 of file rpcwallet.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

UniValue generate ( const JSONRPCRequest request)

Definition at line 3584 of file rpcwallet.cpp.

UniValue getaccount ( const JSONRPCRequest request)

Definition at line 295 of file rpcwallet.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

CFabcoinAddress GetAccountAddress ( CWallet *const  pwallet,
std::string  strAccount,
bool  bForceNew = false 
)

Definition at line 175 of file rpcwallet.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

UniValue getaccountaddress ( const JSONRPCRequest request)

Definition at line 185 of file rpcwallet.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

UniValue getaddressesbyaccount ( const JSONRPCRequest request)

Definition at line 328 of file rpcwallet.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

UniValue getbalance ( const JSONRPCRequest request)

Definition at line 1255 of file rpcwallet.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

UniValue getfabaddressbyvm ( const JSONRPCRequest request)

Definition at line 568 of file rpcwallet.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

UniValue getnewaddress ( const JSONRPCRequest request)

Definition at line 131 of file rpcwallet.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

UniValue getnewwitnessaddress ( const JSONRPCRequest request)

Definition at line 1737 of file rpcwallet.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

UniValue getrawchangeaddress ( const JSONRPCRequest request)

Definition at line 215 of file rpcwallet.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

UniValue getreceivedbyaccount ( const JSONRPCRequest request)

Definition at line 1200 of file rpcwallet.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

UniValue getreceivedbyaddress ( const JSONRPCRequest request)

Definition at line 1143 of file rpcwallet.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

UniValue gettransaction ( const JSONRPCRequest request)

Definition at line 2432 of file rpcwallet.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

UniValue getunconfirmedbalance ( const JSONRPCRequest request)

Definition at line 1312 of file rpcwallet.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

UniValue getvmaddress ( const JSONRPCRequest request)

Definition at line 550 of file rpcwallet.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

CWallet* GetWalletForJSONRPCRequest ( const JSONRPCRequest request)

Figures out what wallet, if any, to use for a JSONRPCRequest.

Parameters
[in]requestJSONRPCRequest that wishes to access a wallet
Returns
nullptr if no wallet should be used, or a pointer to the CWallet

Definition at line 41 of file rpcwallet.cpp.

Here is the call graph for this function:

UniValue getwalletinfo ( const JSONRPCRequest request)

Definition at line 2992 of file rpcwallet.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

std::string HelpRequiringPassphrase ( CWallet *const  pwallet)

Definition at line 56 of file rpcwallet.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

UniValue importaddress ( const JSONRPCRequest request)

Definition at line 217 of file rpcdump.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

UniValue importmulti ( const JSONRPCRequest request)

Definition at line 1030 of file rpcdump.cpp.

Here is the caller graph for this function:

UniValue importprivkey ( const JSONRPCRequest request)

Definition at line 73 of file rpcdump.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

UniValue importprunedfunds ( const JSONRPCRequest request)

Definition at line 287 of file rpcdump.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

UniValue importpubkey ( const JSONRPCRequest request)

Definition at line 386 of file rpcdump.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

UniValue importwallet ( const JSONRPCRequest request)

Definition at line 446 of file rpcdump.cpp.

Here is the caller graph for this function:

UniValue keypoolrefill ( const JSONRPCRequest request)

Definition at line 2586 of file rpcwallet.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

UniValue listaccounts ( const JSONRPCRequest request)

Definition at line 2222 of file rpcwallet.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

UniValue listaddressgroupings ( const JSONRPCRequest request)

Definition at line 1037 of file rpcwallet.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

UniValue listlockunspent ( const JSONRPCRequest request)

Definition at line 2918 of file rpcwallet.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

UniValue ListReceived ( CWallet *const  pwallet,
const UniValue params,
bool  fByAccounts 
)

Definition at line 1801 of file rpcwallet.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

UniValue listreceivedbyaccount ( const JSONRPCRequest request)

Definition at line 1952 of file rpcwallet.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

UniValue listreceivedbyaddress ( const JSONRPCRequest request)

Definition at line 1910 of file rpcwallet.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

UniValue listsinceblock ( const JSONRPCRequest request)

Definition at line 2298 of file rpcwallet.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

void ListTransactions ( CWallet *const  pwallet,
const CWalletTx wtx,
const std::string &  strAccount,
int  nMinDepth,
bool  fLong,
UniValue ret,
const isminefilter filter 
)

List transactions based on the given criteria.

Parameters
pwalletThe wallet.
wtxThe wallet transaction.
strAccountThe account, if any, or "*" for all.
nMinDepthThe minimum confirmation depth.
fLongWhether to include the JSON version of the transaction.
retThe UniValue into which the result is stored.
filterThe "is mine" filter bool.

Definition at line 2006 of file rpcwallet.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

UniValue listtransactions ( const JSONRPCRequest request)

Definition at line 2094 of file rpcwallet.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

UniValue listunspent ( const JSONRPCRequest request)

Definition at line 3114 of file rpcwallet.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

UniValue listwallets ( const JSONRPCRequest request)

Definition at line 3051 of file rpcwallet.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

UniValue lockunspent ( const JSONRPCRequest request)

Definition at line 2832 of file rpcwallet.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

UniValue movecmd ( const JSONRPCRequest request)

Definition at line 1330 of file rpcwallet.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

void RegisterWalletRPCCommands ( CRPCTable t)

Definition at line 3705 of file rpcwallet.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

UniValue removeprunedfunds ( const JSONRPCRequest request)

Definition at line 348 of file rpcdump.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

UniValue resendwallettransactions ( const JSONRPCRequest request)

Definition at line 3081 of file rpcwallet.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

UniValue sendfrom ( const JSONRPCRequest request)

Definition at line 1378 of file rpcwallet.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

UniValue sendmany ( const JSONRPCRequest request)

Definition at line 1446 of file rpcwallet.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

UniValue sendtoaddress ( const JSONRPCRequest request)

Definition at line 402 of file rpcwallet.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

UniValue sendtocontract ( const JSONRPCRequest request)

Definition at line 822 of file rpcwallet.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

UniValue setaccount ( const JSONRPCRequest request)

Definition at line 251 of file rpcwallet.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

UniValue settxfee ( const JSONRPCRequest request)

Definition at line 2964 of file rpcwallet.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

UniValue signmessage ( const JSONRPCRequest request)

Definition at line 1088 of file rpcwallet.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

UniValue walletlock ( const JSONRPCRequest request)

Definition at line 2739 of file rpcwallet.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

UniValue walletpassphrase ( const JSONRPCRequest request)

Definition at line 2631 of file rpcwallet.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

UniValue walletpassphrasechange ( const JSONRPCRequest request)

Definition at line 2690 of file rpcwallet.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

void WalletTxToJSON ( const CWalletTx wtx,
UniValue entry 
)

Definition at line 85 of file rpcwallet.cpp.

Here is the call graph for this function:

Here is the caller graph for this function: