|
43 | 43 | #include <ui_interface.h> |
44 | 44 | #include <util.h> |
45 | 45 | #include <utilmoneystr.h> |
| 46 | +#include <utilstrencodings.h> |
46 | 47 | #include <validationinterface.h> |
47 | 48 | #include <warnings.h> |
48 | 49 | #include <walletinitinterface.h> |
@@ -349,7 +350,6 @@ void SetupServerArgs() |
349 | 350 | // Hidden Options |
350 | 351 | std::vector<std::string> hidden_args = {"-rpcssl", "-benchmark", "-h", "-help", "-socks", "-tor", "-debugnet", "-whitelistalwaysrelay", |
351 | 352 | "-prematurewitness", "-walletprematurewitness", "-promiscuousmempoolflags", "-blockminsize", "-dbcrashratio", "-forcecompactdb", "-usehd", |
352 | | - "-con_fpowallowmindifficultyblocks", "-con_fpownoretargeting", "-con_nsubsidyhalvinginterval", "-con_bip16exception", "-con_bip34height", "-con_bip65height", "-con_bip66height", "-con_npowtargettimespan", "-con_npowtargetspacing", "-con_nrulechangeactivationthreshold", "-con_nminerconfirmationwindow", "-con_powlimit", "-con_bip34hash", "-con_nminimumchainwork", "-con_defaultassumevalid", "-npruneafterheight", "-fdefaultconsistencychecks", "-fmineblocksondemand", "-bech32_hrp", "-fallback_fee_enabled", "-pubkeyprefix", "-scriptprefix", "-secretprefix", "-extpubkeyprefix", "-extprvkeyprefix", "-pchmessagestart", |
353 | 353 | // GUI args. These will be overwritten by SetupUIArgs for the GUI |
354 | 354 | "-allowselfsignedrootcertificates", "-choosedatadir", "-lang=<lang>", "-min", "-resetguisettings", "-rootcertificates=<file>", "-splash", "-uiplatform"}; |
355 | 355 |
|
@@ -516,14 +516,30 @@ void SetupServerArgs() |
516 | 516 | gArgs.AddArg("-rpcworkqueue=<n>", strprintf("Set the depth of the work queue to service RPC calls (default: %d)", DEFAULT_HTTP_WORKQUEUE), true, OptionsCategory::RPC); |
517 | 517 | gArgs.AddArg("-server", "Accept command line and JSON-RPC commands", false, OptionsCategory::RPC); |
518 | 518 |
|
| 519 | + // chain params |
| 520 | + gArgs.AddArg("-pubkeyprefix", strprintf("The byte prefix, in decimal, of the chain's base58 pubkey address. (default: %d)", defaultChainParams->Base58Prefix(CChainParams::PUBKEY_ADDRESS)[0]), false, OptionsCategory::CHAINPARAMS); |
| 521 | + gArgs.AddArg("-scriptprefix", strprintf("The byte prefix, in decimal, of the chain's base58 script address. (default: %d)", defaultChainParams->Base58Prefix(CChainParams::SCRIPT_ADDRESS)[0]), false, OptionsCategory::CHAINPARAMS); |
| 522 | + gArgs.AddArg("-secretprefix", strprintf("The byte prefix, in decimal, of the chain's base58 secret key encoding. (default: %d)", defaultChainParams->Base58Prefix(CChainParams::SECRET_KEY)[0]), false, OptionsCategory::CHAINPARAMS); |
| 523 | + gArgs.AddArg("-extpubkeyprefix", strprintf("The 4-byte prefix, in hex, of the chain's base58 extended public key encoding. (default: %s)", HexStr(defaultChainParams->Base58Prefix(CChainParams::EXT_PUBLIC_KEY))), false, OptionsCategory::CHAINPARAMS); |
| 524 | + gArgs.AddArg("-extprvkeyprefix", strprintf("The 4-byte prefix, in hex, of the chain's base58 extended private key encoding. (default: %s)", HexStr(defaultChainParams->Base58Prefix(CChainParams::EXT_SECRET_KEY))), false, OptionsCategory::CHAINPARAMS); |
| 525 | + gArgs.AddArg("-bech32_hrp", strprintf("The human-readable part of the chain's bech32 encoding. (default: %s)", defaultChainParams->Bech32HRP()), false, OptionsCategory::CHAINPARAMS); |
| 526 | + |
519 | 527 | #if HAVE_DECL_DAEMON |
520 | 528 | gArgs.AddArg("-daemon", "Run in the background as a daemon and accept commands", false, OptionsCategory::OPTIONS); |
521 | 529 | #else |
522 | 530 | hidden_args.emplace_back("-daemon"); |
523 | 531 | #endif |
524 | 532 |
|
| 533 | + // |
| 534 | + // Elements-specific arguments. |
| 535 | + // |
| 536 | + |
| 537 | + std::vector<std::string> elements_hidden_args = {"-con_fpowallowmindifficultyblocks", "-con_fpownoretargeting", "-con_nsubsidyhalvinginterval", "-con_bip16exception", "-con_bip34height", "-con_bip65height", "-con_bip66height", "-con_npowtargettimespan", "-con_npowtargetspacing", "-con_nrulechangeactivationthreshold", "-con_nminerconfirmationwindow", "-con_powlimit", "-con_bip34hash", "-con_nminimumchainwork", "-con_defaultassumevalid", "-npruneafterheight", "-fdefaultconsistencychecks", "-fmineblocksondemand", "-fallback_fee_enabled", "-pchmessagestart"}; |
| 538 | + |
| 539 | + |
525 | 540 | // Add the hidden options |
526 | 541 | gArgs.AddHiddenArgs(hidden_args); |
| 542 | + gArgs.AddHiddenArgs(elements_hidden_args); |
527 | 543 | } |
528 | 544 |
|
529 | 545 | std::string LicenseInfo() |
|
0 commit comments