From 6f46a4e7be362f89d1dfe63346110dce5abb79a0 Mon Sep 17 00:00:00 2001 From: skellers Date: Thu, 7 Feb 2019 20:01:37 +0000 Subject: [PATCH 1/8] text updates --- .gitignore | 4 + configure.ac | 12 +-- src/Makefile.am | 58 ++++++------ src/bitcoin-cli-res.rc | 10 +- src/bitcoin-cli.cpp | 10 +- src/bitcoin-tx-res.rc | 10 +- src/bitcoin-tx.cpp | 6 +- src/bitcoind-res.rc | 10 +- src/bitcoind.cpp | 20 ++-- src/chainparams.cpp | 135 +++++++++++++++------------ src/init.cpp | 20 ++-- src/metrics.cpp | 6 +- src/metrics.h | 42 ++++----- src/rpc/blockchain.cpp | 2 +- src/rpc/mining.cpp | 12 +-- src/rpc/server.cpp | 10 +- src/sendalert.cpp | 4 +- src/test/data/bitcoin-util-test.json | 24 ++--- src/util.cpp | 13 ++- src/wallet/rpcdump.cpp | 28 +++--- src/wallet/rpcwallet.cpp | 106 ++++++++++----------- 21 files changed, 278 insertions(+), 264 deletions(-) diff --git a/.gitignore b/.gitignore index 5992c9e6bfd..33951830729 100644 --- a/.gitignore +++ b/.gitignore @@ -6,6 +6,10 @@ src/zcashd src/zcash-cli src/zcash-gtest src/zcash-tx +src/zclassicd +src/zclassic-cli +src/zclassic-gtest +src/zclassic-tx src/test/test_bitcoin *zcashTest.pk diff --git a/configure.ac b/configure.ac index bce8037252e..730ef9dae55 100644 --- a/configure.ac +++ b/configure.ac @@ -14,9 +14,9 @@ AC_CONFIG_HEADERS([src/config/bitcoin-config.h]) AC_CONFIG_AUX_DIR([build-aux]) AC_CONFIG_MACRO_DIR([build-aux/m4]) -BITCOIN_DAEMON_NAME=zcashd -BITCOIN_CLI_NAME=zcash-cli -BITCOIN_TX_NAME=zcash-tx +BITCOIN_DAEMON_NAME=zclassicd +BITCOIN_CLI_NAME=zclassic-cli +BITCOIN_TX_NAME=zclassic-tx dnl Unless the user specified ARFLAGS, force it to be cr AC_ARG_VAR(ARFLAGS, [Flags for the archiver, defaults to if not set]) @@ -943,7 +943,7 @@ case $host in ;; esac -echo +echo echo "Options used to compile and link:" echo " with wallet = $enable_wallet" echo " with proton = $use_proton" @@ -951,7 +951,7 @@ echo " with zmq = $use_zmq" echo " with test = $use_tests" echo " debug enabled = $enable_debug" echo " werror = $enable_werror" -echo +echo echo " target os = $TARGET_OS" echo " build os = $BUILD_OS" echo @@ -962,4 +962,4 @@ echo " CXX = $CXX" echo " CXXFLAGS = $CXXFLAGS" echo " LDFLAGS = $LDFLAGS" echo " ARFLAGS = $ARFLAGS" -echo +echo diff --git a/src/Makefile.am b/src/Makefile.am index e36cea3d67c..af9bd9c469e 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -92,11 +92,11 @@ noinst_PROGRAMS = TESTS = if BUILD_BITCOIND - bin_PROGRAMS += zcashd + bin_PROGRAMS += zclassicd endif if BUILD_BITCOIN_UTILS - bin_PROGRAMS += zcash-cli zcash-tx + bin_PROGRAMS += zclassic-cli zclassic-tx endif LIBZCASH_H = \ @@ -235,7 +235,7 @@ obj/build.h: FORCE $(abs_top_srcdir) libbitcoin_util_a-clientversion.$(OBJEXT): obj/build.h -# server: zcashd +# server: zclassicd libbitcoin_server_a_CPPFLAGS = $(AM_CPPFLAGS) $(BITCOIN_INCLUDES) $(EVENT_CFLAGS) $(EVENT_PTHREADS_CFLAGS) libbitcoin_server_a_CXXFLAGS = $(AM_CXXFLAGS) $(PIE_FLAGS) libbitcoin_server_a_SOURCES = \ @@ -297,7 +297,7 @@ libbitcoin_proton_a_SOURCES = \ amqp/amqppublishnotifier.cpp endif -# wallet: zcashd, but only linked when wallet enabled +# wallet: zclassicd, but only linked when wallet enabled libbitcoin_wallet_a_CPPFLAGS = $(AM_CPPFLAGS) $(BITCOIN_INCLUDES) libbitcoin_wallet_a_CXXFLAGS = $(AM_CXXFLAGS) $(PIE_FLAGS) libbitcoin_wallet_a_SOURCES = \ @@ -354,7 +354,7 @@ crypto_libbitcoin_crypto_a_SOURCES += \ ${EQUIHASH_TROMP_SOURCES} endif -# common: shared between zcashd and non-server tools +# common: shared between zclassicd and non-server tools libbitcoin_common_a_CPPFLAGS = $(AM_CPPFLAGS) $(BITCOIN_INCLUDES) libbitcoin_common_a_CXXFLAGS = $(AM_CXXFLAGS) $(PIE_FLAGS) libbitcoin_common_a_SOURCES = \ @@ -415,7 +415,7 @@ if GLIBC_BACK_COMPAT libbitcoin_util_a_SOURCES += compat/glibc_compat.cpp endif -# cli: zcash-cli +# cli: zclassic-cli libbitcoin_cli_a_CPPFLAGS = $(AM_CPPFLAGS) $(BITCOIN_INCLUDES) libbitcoin_cli_a_CXXFLAGS = $(AM_CXXFLAGS) $(PIE_FLAGS) libbitcoin_cli_a_SOURCES = \ @@ -427,16 +427,16 @@ nodist_libbitcoin_util_a_SOURCES = $(srcdir)/obj/build.h # # bitcoind binary # -zcashd_SOURCES = bitcoind.cpp -zcashd_CPPFLAGS = $(AM_CPPFLAGS) $(BITCOIN_INCLUDES) -zcashd_CXXFLAGS = $(AM_CXXFLAGS) $(PIE_FLAGS) -zcashd_LDFLAGS = $(RELDFLAGS) $(AM_LDFLAGS) $(LIBTOOL_APP_LDFLAGS) +zclassicd_SOURCES = bitcoind.cpp +zclassicd_CPPFLAGS = $(AM_CPPFLAGS) $(BITCOIN_INCLUDES) +zclassicd_CXXFLAGS = $(AM_CXXFLAGS) $(PIE_FLAGS) +zclassicd_LDFLAGS = $(RELDFLAGS) $(AM_LDFLAGS) $(LIBTOOL_APP_LDFLAGS) if TARGET_WINDOWS -zcashd_SOURCES += bitcoind-res.rc +zclassicd_SOURCES += bitcoind-res.rc endif -zcashd_LDADD = \ +zclassicd_LDADD = \ $(LIBBITCOIN_SERVER) \ $(LIBBITCOIN_WALLET) \ $(LIBBITCOIN_COMMON) \ @@ -451,7 +451,7 @@ zcashd_LDADD = \ $(LIBMEMENV) \ $(LIBSECP256K1) -zcashd_LDADD += \ +zclassicd_LDADD += \ $(BOOST_LIBS) \ $(BDB_LIBS) \ $(SSL_LIBS) \ @@ -464,16 +464,16 @@ zcashd_LDADD += \ $(LIBZCASH_LIBS) # bitcoin-cli binary # -zcash_cli_SOURCES = bitcoin-cli.cpp -zcash_cli_CPPFLAGS = $(AM_CPPFLAGS) $(BITCOIN_INCLUDES) $(EVENT_CFLAGS) -zcash_cli_CXXFLAGS = $(AM_CXXFLAGS) $(PIE_FLAGS) -zcash_cli_LDFLAGS = $(RELDFLAGS) $(AM_LDFLAGS) $(LIBTOOL_APP_LDFLAGS) +zclassic_cli_SOURCES = bitcoin-cli.cpp +zclassic_cli_CPPFLAGS = $(AM_CPPFLAGS) $(BITCOIN_INCLUDES) $(EVENT_CFLAGS) +zclassic_cli_CXXFLAGS = $(AM_CXXFLAGS) $(PIE_FLAGS) +zclassic_cli_LDFLAGS = $(RELDFLAGS) $(AM_LDFLAGS) $(LIBTOOL_APP_LDFLAGS) if TARGET_WINDOWS -zcash_cli_SOURCES += bitcoin-cli-res.rc +zclassic_cli_SOURCES += bitcoin-cli-res.rc endif -zcash_cli_LDADD = \ +zclassic_cli_LDADD = \ $(LIBBITCOIN_CLI) \ $(LIBUNIVALUE) \ $(LIBBITCOIN_UTIL) \ @@ -487,18 +487,18 @@ zcash_cli_LDADD = \ $(LIBZCASH_LIBS) # -# zcash-tx binary # -zcash_tx_SOURCES = bitcoin-tx.cpp -zcash_tx_CPPFLAGS = $(AM_CPPFLAGS) $(BITCOIN_INCLUDES) -zcash_tx_CXXFLAGS = $(AM_CXXFLAGS) $(PIE_FLAGS) -zcash_tx_LDFLAGS = $(RELDFLAGS) $(AM_LDFLAGS) $(LIBTOOL_APP_LDFLAGS) +# zclassic-tx binary # +zclassic_tx_SOURCES = bitcoin-tx.cpp +zclassic_tx_CPPFLAGS = $(AM_CPPFLAGS) $(BITCOIN_INCLUDES) +zclassic_tx_CXXFLAGS = $(AM_CXXFLAGS) $(PIE_FLAGS) +zclassic_tx_LDFLAGS = $(RELDFLAGS) $(AM_LDFLAGS) $(LIBTOOL_APP_LDFLAGS) if TARGET_WINDOWS -zcash_tx_SOURCES += bitcoin-tx-res.rc +zclassic_tx_SOURCES += bitcoin-tx-res.rc endif -# FIXME: Is libzcash needed for zcash_tx? -zcash_tx_LDADD = \ +# FIXME: Is libzcash needed for zclassic_tx? +zclassic_tx_LDADD = \ $(LIBUNIVALUE) \ $(LIBBITCOIN_COMMON) \ $(LIBBITCOIN_UTIL) \ @@ -508,10 +508,10 @@ zcash_tx_LDADD = \ $(LIBBITCOIN_CRYPTO) \ $(LIBZCASH_LIBS) -zcash_tx_LDADD += $(BOOST_LIBS) $(CRYPTO_LIBS) +zclassic_tx_LDADD += $(BOOST_LIBS) $(CRYPTO_LIBS) # -# zcash protocol primitives # +# zclassic protocol primitives # libzcash_a_SOURCES = \ zcash/IncrementalMerkleTree.cpp \ zcash/NoteEncryption.cpp \ diff --git a/src/bitcoin-cli-res.rc b/src/bitcoin-cli-res.rc index d365e0b49b1..22268f67676 100644 --- a/src/bitcoin-cli-res.rc +++ b/src/bitcoin-cli-res.rc @@ -16,14 +16,14 @@ BEGIN BEGIN BLOCK "040904E4" // U.S. English - multilingual (hex) BEGIN - VALUE "CompanyName", "Zcash" - VALUE "FileDescription", "zcash-cli (JSON-RPC client for Zcash)" + VALUE "CompanyName", "ZClassic" + VALUE "FileDescription", "zclassic-cli (JSON-RPC client for ZClassic)" VALUE "FileVersion", VER_FILEVERSION_STR - VALUE "InternalName", "zcash-cli" + VALUE "InternalName", "zclassic-cli" VALUE "LegalCopyright", COPYRIGHT_STR VALUE "LegalTrademarks1", "Distributed under the MIT software license, see the accompanying file COPYING or http://www.opensource.org/licenses/mit-license.php." - VALUE "OriginalFilename", "zcash-cli.exe" - VALUE "ProductName", "zcash-cli" + VALUE "OriginalFilename", "zclassic-cli.exe" + VALUE "ProductName", "zclassic-cli" VALUE "ProductVersion", VER_PRODUCTVERSION_STR END END diff --git a/src/bitcoin-cli.cpp b/src/bitcoin-cli.cpp index 1de5ee43ff5..87fae044957 100644 --- a/src/bitcoin-cli.cpp +++ b/src/bitcoin-cli.cpp @@ -27,7 +27,7 @@ std::string HelpMessageCli() std::string strUsage; strUsage += HelpMessageGroup(_("Options:")); strUsage += HelpMessageOpt("-?", _("This help message")); - strUsage += HelpMessageOpt("-conf=", strprintf(_("Specify configuration file (default: %s)"), "zcash.conf")); + strUsage += HelpMessageOpt("-conf=", strprintf(_("Specify configuration file (default: %s)"), "zclassic.conf")); strUsage += HelpMessageOpt("-datadir=", _("Specify data directory")); strUsage += HelpMessageOpt("-testnet", _("Use the test network")); strUsage += HelpMessageOpt("-regtest", _("Enter regression test mode, which uses a special chain in which blocks can be " @@ -77,12 +77,12 @@ static int AppInitRPC(int argc, char* argv[]) // ParseParameters(argc, argv); if (argc<2 || mapArgs.count("-?") || mapArgs.count("-h") || mapArgs.count("-help") || mapArgs.count("-version")) { - std::string strUsage = _("Zcash RPC client version") + " " + FormatFullVersion() + "\n" + PrivacyInfo(); + std::string strUsage = _("Zclassic RPC client version") + " " + FormatFullVersion() + "\n" + PrivacyInfo(); if (!mapArgs.count("-version")) { strUsage += "\n" + _("Usage:") + "\n" + - " zcash-cli [options] [params] " + _("Send command to Zcash") + "\n" + - " zcash-cli [options] help " + _("List commands") + "\n" + - " zcash-cli [options] help " + _("Get help for a command") + "\n"; + " zclassic-cli [options] [params] " + _("Send command to Zcash") + "\n" + + " zclassic-cli [options] help " + _("List commands") + "\n" + + " zclassic-cli [options] help " + _("Get help for a command") + "\n"; strUsage += "\n" + HelpMessageCli(); } else { diff --git a/src/bitcoin-tx-res.rc b/src/bitcoin-tx-res.rc index bc8d5713475..dfd7a6f745d 100644 --- a/src/bitcoin-tx-res.rc +++ b/src/bitcoin-tx-res.rc @@ -16,14 +16,14 @@ BEGIN BEGIN BLOCK "040904E4" // U.S. English - multilingual (hex) BEGIN - VALUE "CompanyName", "Zcash" - VALUE "FileDescription", "zcash-tx (CLI Zcash transaction editor utility)" + VALUE "CompanyName", "ZClassic" + VALUE "FileDescription", "zclassic-tx (CLI ZClassic transaction editor utility)" VALUE "FileVersion", VER_FILEVERSION_STR - VALUE "InternalName", "zcash-tx" + VALUE "InternalName", "zclassic-tx" VALUE "LegalCopyright", COPYRIGHT_STR VALUE "LegalTrademarks1", "Distributed under the MIT software license, see the accompanying file COPYING or http://www.opensource.org/licenses/mit-license.php." - VALUE "OriginalFilename", "zcash-tx.exe" - VALUE "ProductName", "zcash-tx" + VALUE "OriginalFilename", "zclassic-tx.exe" + VALUE "ProductName", "zclassic-tx" VALUE "ProductVersion", VER_PRODUCTVERSION_STR END END diff --git a/src/bitcoin-tx.cpp b/src/bitcoin-tx.cpp index 3ee3c01697c..6f09901cfd1 100644 --- a/src/bitcoin-tx.cpp +++ b/src/bitcoin-tx.cpp @@ -48,10 +48,10 @@ static int AppInitRawTx(int argc, char* argv[]) if (argc<2 || mapArgs.count("-?") || mapArgs.count("-h") || mapArgs.count("-help")) { // First part of help message is specific to this utility - std::string strUsage = _("Zcash zcash-tx utility version") + " " + FormatFullVersion() + "\n\n" + + std::string strUsage = _("ZClassic zclassic-tx utility version") + " " + FormatFullVersion() + "\n\n" + _("Usage:") + "\n" + - " zcash-tx [options] [commands] " + _("Update hex-encoded zcash transaction") + "\n" + - " zcash-tx [options] -create [commands] " + _("Create hex-encoded zcash transaction") + "\n" + + " zclassic-tx [options] [commands] " + _("Update hex-encoded zclassic transaction") + "\n" + + " zclassic-tx [options] -create [commands] " + _("Create hex-encoded zclassic transaction") + "\n" + "\n"; fprintf(stdout, "%s", strUsage.c_str()); diff --git a/src/bitcoind-res.rc b/src/bitcoind-res.rc index eeb6fde5242..75e7f5f49a9 100644 --- a/src/bitcoind-res.rc +++ b/src/bitcoind-res.rc @@ -16,14 +16,14 @@ BEGIN BEGIN BLOCK "040904E4" // U.S. English - multilingual (hex) BEGIN - VALUE "CompanyName", "Zcash" - VALUE "FileDescription", "zcashd (Zcash node with a JSON-RPC server)" + VALUE "CompanyName", "ZClassic" + VALUE "FileDescription", "zclassicd ZClassic node with a JSON-RPC server)" VALUE "FileVersion", VER_FILEVERSION_STR - VALUE "InternalName", "zcashd" + VALUE "InternalName", "zclassicd" VALUE "LegalCopyright", COPYRIGHT_STR VALUE "LegalTrademarks1", "Distributed under the MIT software license, see the accompanying file COPYING or http://www.opensource.org/licenses/mit-license.php." - VALUE "OriginalFilename", "zcashd.exe" - VALUE "ProductName", "zcashd" + VALUE "OriginalFilename", "zclassicd.exe" + VALUE "ProductName", "zclassicd" VALUE "ProductVersion", VER_PRODUCTVERSION_STR END END diff --git a/src/bitcoind.cpp b/src/bitcoind.cpp index 7e7f54934be..bb4cc9f2ace 100644 --- a/src/bitcoind.cpp +++ b/src/bitcoind.cpp @@ -72,7 +72,7 @@ bool AppInit(int argc, char* argv[]) // Process help and version before taking care about datadir if (mapArgs.count("-?") || mapArgs.count("-h") || mapArgs.count("-help") || mapArgs.count("-version")) { - std::string strUsage = _("Zcash Daemon") + " " + _("version") + " " + FormatFullVersion() + "\n" + PrivacyInfo(); + std::string strUsage = _("ZClassic Daemon") + " " + _("version") + " " + FormatFullVersion() + "\n" + PrivacyInfo(); if (mapArgs.count("-version")) { @@ -81,7 +81,7 @@ bool AppInit(int argc, char* argv[]) else { strUsage += "\n" + _("Usage:") + "\n" + - " zcashd [options] " + _("Start Zcash Daemon") + "\n"; + " zclassicd [options] " + _("Start ZClassic Daemon") + "\n"; strUsage += "\n" + HelpMessage(HMM_BITCOIND); } @@ -102,21 +102,21 @@ bool AppInit(int argc, char* argv[]) ReadConfigFile(mapArgs, mapMultiArgs); } catch (const missing_zcash_conf& e) { fprintf(stderr, - (_("Before starting zcashd, you need to create a configuration file:\n" + (_("Before starting zclassicd, you need to create a configuration file:\n" "%s\n" "It can be completely empty! That indicates you are happy with the default\n" - "configuration of zcashd. But requiring a configuration file to start ensures\n" - "that zcashd won't accidentally compromise your privacy if there was a default\n" + "configuration of zclassicd. But requiring a configuration file to start ensures\n" + "that zclassicd won't accidentally compromise your privacy if there was a default\n" "option you needed to change.\n" "\n" "You can look at the example configuration file for suggestions of default\n" "options that you may want to change. It should be in one of these locations,\n" - "depending on how you installed Zcash:\n") + + "depending on how you installed ZClassic:\n") + _("- Source code: %s\n" "- .deb package: %s\n")).c_str(), GetConfigFile().string().c_str(), - "contrib/debian/examples/zcash.conf", - "/usr/share/doc/zcash/examples/zcash.conf"); + "contrib/debian/examples/zclassic.conf", + "/usr/share/doc/zcash/examples/zclassic.conf"); return false; } catch (const std::exception& e) { fprintf(stderr,"Error reading configuration file: %s\n", e.what()); @@ -136,14 +136,14 @@ bool AppInit(int argc, char* argv[]) if (fCommandLine) { - fprintf(stderr, "Error: There is no RPC client functionality in zcashd. Use the zcash-cli utility instead.\n"); + fprintf(stderr, "Error: There is no RPC client functionality in zclassicd. Use the zclassic-cli utility instead.\n"); exit(EXIT_FAILURE); } #ifndef WIN32 fDaemon = GetBoolArg("-daemon", false); if (fDaemon) { - fprintf(stdout, "Zcash server starting\n"); + fprintf(stdout, "ZClassic server starting\n"); // Daemonize pid_t pid = fork(); diff --git a/src/chainparams.cpp b/src/chainparams.cpp index 32aca7718bc..9df77ea4bcb 100644 --- a/src/chainparams.cpp +++ b/src/chainparams.cpp @@ -27,7 +27,7 @@ static CBlock CreateGenesisBlock(const char* pszTimestamp, const CScript& genesi txNew.nVersion = 1; txNew.vin.resize(1); txNew.vout.resize(1); - txNew.vin[0].scriptSig = CScript() << 520617983 << CScriptNum(4) << std::vector((const unsigned char*)pszTimestamp, (const unsigned char*)pszTimestamp + strlen(pszTimestamp)); + txNew.vin[0].scriptSig = CScript() << 486604799 << CScriptNum(4) << std::vector((const unsigned char*)pszTimestamp, (const unsigned char*)pszTimestamp + strlen(pszTimestamp)); txNew.vout[0].nValue = genesisReward; txNew.vout[0].scriptPubKey = genesisOutputScript; @@ -59,7 +59,7 @@ static CBlock CreateGenesisBlock(const char* pszTimestamp, const CScript& genesi */ static CBlock CreateGenesisBlock(uint32_t nTime, const uint256& nNonce, const std::vector& nSolution, uint32_t nBits, int32_t nVersion, const CAmount& genesisReward) { - const char* pszTimestamp = "Zcash0b9c4eef8b7cc417ee5001e3500984b6fea35683a7cac141a043c42064835d34"; + const char* pszTimestamp = "Zclassic860413afe207aa173afee4fcfa9166dc745651c754a41ea8f155646f5aa828ac"; const CScript genesisOutputScript = CScript() << ParseHex("04678afdb0fe5548271967f1a67130b7105cd6a828e03909a67962e0ea1f61deb649f6bc3f4cef38c4f35504e51ec112de5c384df7ba0b8d578a4c702b6bf11d5f") << OP_CHECKSIG; return CreateGenesisBlock(pszTimestamp, genesisOutputScript, nTime, nNonce, nSolution, nBits, nVersion, genesisReward); } @@ -81,10 +81,10 @@ class CMainParams : public CChainParams { public: CMainParams() { strNetworkID = "main"; - strCurrencyUnits = "ZEC"; + strCurrencyUnits = "ZCL"; bip44CoinType = 133; // As registered in https://github.com/satoshilabs/slips/blob/master/slip-0044.md consensus.fCoinbaseMustBeProtected = true; - consensus.nSubsidySlowStartInterval = 20000; + consensus.nSubsidySlowStartInterval = 2; consensus.nSubsidyHalvingInterval = 840000; consensus.nMajorityEnforceBlockUpgrade = 750; consensus.nMajorityRejectBlockOutdated = 950; @@ -103,12 +103,12 @@ class CMainParams : public CChainParams { consensus.vUpgrades[Consensus::UPGRADE_TESTDUMMY].nActivationHeight = Consensus::NetworkUpgrade::NO_ACTIVATION_HEIGHT; consensus.vUpgrades[Consensus::UPGRADE_OVERWINTER].nProtocolVersion = 170005; - consensus.vUpgrades[Consensus::UPGRADE_OVERWINTER].nActivationHeight = 347500; + consensus.vUpgrades[Consensus::UPGRADE_OVERWINTER].nActivationHeight = 500000; consensus.vUpgrades[Consensus::UPGRADE_SAPLING].nProtocolVersion = 170007; - consensus.vUpgrades[Consensus::UPGRADE_SAPLING].nActivationHeight = 419200; + consensus.vUpgrades[Consensus::UPGRADE_SAPLING].nActivationHeight = 500000; // The best chain should have at least this much work. - consensus.nMinimumChainWork = uint256S("0x000000000000000000000000000000000000000000000000006f31c0e1f30221"); + consensus.nMinimumChainWork = uint256S("0x00000000000000000000000000000000000000000000000000281b32ff3198a1"); /** * The message start string should be awesome! ⓩ❤ @@ -117,8 +117,8 @@ class CMainParams : public CChainParams { pchMessageStart[1] = 0xe9; pchMessageStart[2] = 0x27; pchMessageStart[3] = 0x64; - vAlertPubKey = ParseHex("04b7ecf0baa90495ceb4e4090f6b2fd37eec1e9c85fac68a487f3ce11589692e4a317479316ee814e066638e1db54e37a10689b70286e6315b1087b6615d179264"); - nDefaultPort = 8233; + vAlertPubKey = ParseHex("04f2cd746e629ffd320a81287474c98c2ad15d15b0a210b0144edcd8f3e1301c6311fd751fa34ba17d88090374cfec7cd9aaca55a5a0c4456511acc01b922005de"); + nDefaultPort = 8033; nPruneAfterHeight = 100000; const size_t N = 200, K = 9; BOOST_STATIC_ASSERT(equihash_parameters_acceptable(N, K)); @@ -126,19 +126,37 @@ class CMainParams : public CChainParams { nEquihashK = K; genesis = CreateGenesisBlock( - 1477641360, - uint256S("0x0000000000000000000000000000000000000000000000000000000000001257"), - ParseHex("000a889f00854b8665cd555f4656f68179d31ccadc1b1f7fb0952726313b16941da348284d67add4686121d4e3d930160c1348d8191c25f12b267a6a9c131b5031cbf8af1f79c9d513076a216ec87ed045fa966e01214ed83ca02dc1797270a454720d3206ac7d931a0a680c5c5e099057592570ca9bdf6058343958b31901fce1a15a4f38fd347750912e14004c73dfe588b903b6c03166582eeaf30529b14072a7b3079e3a684601b9b3024054201f7440b0ee9eb1a7120ff43f713735494aa27b1f8bab60d7f398bca14f6abb2adbf29b04099121438a7974b078a11635b594e9170f1086140b4173822dd697894483e1c6b4e8b8dcd5cb12ca4903bc61e108871d4d915a9093c18ac9b02b6716ce1013ca2c1174e319c1a570215bc9ab5f7564765f7be20524dc3fdf8aa356fd94d445e05ab165ad8bb4a0db096c097618c81098f91443c719416d39837af6de85015dca0de89462b1d8386758b2cf8a99e00953b308032ae44c35e05eb71842922eb69797f68813b59caf266cb6c213569ae3280505421a7e3a0a37fdf8e2ea354fc5422816655394a9454bac542a9298f176e211020d63dee6852c40de02267e2fc9d5e1ff2ad9309506f02a1a71a0501b16d0d36f70cdfd8de78116c0c506ee0b8ddfdeb561acadf31746b5a9dd32c21930884397fb1682164cb565cc14e089d66635a32618f7eb05fe05082b8a3fae620571660a6b89886eac53dec109d7cbb6930ca698a168f301a950be152da1be2b9e07516995e20baceebecb5579d7cdbc16d09f3a50cb3c7dffe33f26686d4ff3f8946ee6475e98cf7b3cf9062b6966e838f865ff3de5fb064a37a21da7bb8dfd2501a29e184f207caaba364f36f2329a77515dcb710e29ffbf73e2bbd773fab1f9a6b005567affff605c132e4e4dd69f36bd201005458cfbd2c658701eb2a700251cefd886b1e674ae816d3f719bac64be649c172ba27a4fd55947d95d53ba4cbc73de97b8af5ed4840b659370c556e7376457f51e5ebb66018849923db82c1c9a819f173cccdb8f3324b239609a300018d0fb094adf5bd7cbb3834c69e6d0b3798065c525b20f040e965e1a161af78ff7561cd874f5f1b75aa0bc77f720589e1b810f831eac5073e6dd46d00a2793f70f7427f0f798f2f53a67e615e65d356e66fe40609a958a05edb4c175bcc383ea0530e67ddbe479a898943c6e3074c6fcc252d6014de3a3d292b03f0d88d312fe221be7be7e3c59d07fa0f2f4029e364f1f355c5d01fa53770d0cd76d82bf7e60f6903bc1beb772e6fde4a70be51d9c7e03c8d6d8dfb361a234ba47c470fe630820bbd920715621b9fbedb49fcee165ead0875e6c2b1af16f50b5d6140cc981122fcbcf7c5a4e3772b3661b628e08380abc545957e59f634705b1bbde2f0b4e055a5ec5676d859be77e20962b645e051a880fddb0180b4555789e1f9344a436a84dc5579e2553f1e5fb0a599c137be36cabbed0319831fea3fddf94ddc7971e4bcf02cdc93294a9aab3e3b13e3b058235b4f4ec06ba4ceaa49d675b4ba80716f3bc6976b1fbf9c8bf1f3e3a4dc1cd83ef9cf816667fb94f1e923ff63fef072e6a19321e4812f96cb0ffa864da50ad74deb76917a336f31dce03ed5f0303aad5e6a83634f9fcc371096f8288b8f02ddded5ff1bb9d49331e4a84dbe1543164438fde9ad71dab024779dcdde0b6602b5ae0a6265c14b94edd83b37403f4b78fcd2ed555b596402c28ee81d87a909c4e8722b30c71ecdd861b05f61f8b1231795c76adba2fdefa451b283a5d527955b9f3de1b9828e7b2e74123dd47062ddcc09b05e7fa13cb2212a6fdbc65d7e852cec463ec6fd929f5b8483cf3052113b13dac91b69f49d1b7d1aec01c4a68e41ce157"), + 1478403829, + uint256S("0x000000000000000000000000000000000000000000000000000000000000021d"), + ParseHex("009aaa951ca873376788d3002918d956e371bdf03c1afcfd8eea17867b5480d2e59a2a4dd52ed0d091af0c0909aa66ce2da97266926a9ea69b9ccca389bc120d9c4dbbae727ab9d6dfd1cd847df0ef0cc9bc989f11bdd6522429c15957daa3c5a2612522ded69857c148c0638611a19287599b47683c714b5774d0fcb1341cf4fc3a546a2441a19f02a55c6f9775749e57783b2abd5b25d41753d2f60892bbb4c3173d7787dbf5e50267324db218a14dd65f71bb02cf2566d3201800f866701db8c221424b75c639de58e7e40705157ae7d10da708ec2b9e71b9bc1ad34854a7bdf58d93766b6e291d3b545fa1f785a1a9829eccd525d16856f4317f0449d5c3516736f1e564f17690f13d3c939ad5516f1db70194902c20afd939168037fa404ec962dfbe752f79ac87a2cc3fd07bcd94d1975b1849cc739c0bc144ae4e75eda1bbed5b5ef8f65966257ec7b1fc6bb600e12e1c65c8c13a505f35dd363e07b6238211a0e502e36db5a620310b544360dd9b4a6cedabc34eeb530139daad50d4a5b6eaf4d50be4ba10e970ce984fb705376a3b0b4bf3f3778600f14e739e04406106f707085ab87ca70598c032b6717a54a9fd8ef72fdd78fb41fa9d45ad685caf77e0fc42e8e644634c24bc972f3ab0e3f0345854eda624045feb6bc9d20b5b1fc6903ebc64026e51da598c0d8711c452131a8fd2bbe01403af20e5db88afcd53b6107f001dae78b548d6a1581baca15359de83e54e75d8fc6374ca1edec17a9f4b06931162f9952575c5c3fb5dfc70a0f793049e781926daaafd4f4d330cf7d5635af1541f0d29e709a37c088d6d2e7aa09d15dfb9c2ae6c1ce661e85e9d89772eb47cfea00c621b66faf8a48cfa970b898dbd77b14e7bf44b742c00f76d2435f949f027132adb1e974551488f988e9fe379a0f86538ee59e26637a3d50bf400c7f52aa9457d77c3eb426628bb17909b26a6820d0772d4c6f74472f635e4c6e72272ce01fc475df69e10371457c55e0fbdf3a392850b9924da9c9a55792325c4318562593f0df8d39559065be03a22b1b6c21206aa1958a0d33257d89b74dea42a11aabf8eddbfe6136ab649744b704eb3e3d473654b588927dd9f486c1cd02639cf656ccbf2c4869c2ed1f2ba4ec55e69a42d5af6b3605a0cdf987734727c6fc1c1489870fb300139328c4d12eb6f5e8309cc09f5f3c29ab0957374113931ec9a56e7579446f12faacda9bd50899a17bd0f78e89ed70a723fdadfb1f4bc3317c8caa32757901604fb79ae48e22251c3b1691125ec5a99fabdf62b015bc817e1c30c06565a7071510b014058a77856a150bf86ab0c565b8bbbed159e2fb862c6215752bf3f0563e2bbbf23b0dbfb2de21b366b7e4cda212d69502643ca1f13ce362eef7435d60530b9999027dd39cd01fd8e064f1ccf6b748a2739707c9f76a041f82d3e046a9c184d83396f1f15b5a11eddb2baff40fc7b410f0c43e36ac7d8ff0204219abe4610825191fbb2be15a508c839259bfd6a4c5204c779fad6c23bbd37f90709654a5b93c6f93b4c844be12cd6cd2200afbf600b2ae9b6c133d8cdb3a85312a6d9948213c656db4d076d2bacd10577d7624be0c684bd1e5464bb39006a524d971cd2223ae9e23dea12366355b3cc4c9f6b8104df6abd23029ac4179f718e3a51eba69e4ebeec511312c423e0755b53f72ac18ef1fb445d7ab83b0894435a4b1a9cd1b473792e0628fd40bef624b4fb6ba457494cd1137a4da9e44956143068af9db98135e6890ef589726f4f5fbd45a713a24736acf150b5fb7a4c3448465322dccd7f3458c49cf2d0ef6dd7dd2ed1f1147f4a00af28ae39a73c827a38309f59faf8970448436fbb14766a3247aac4d5c610db9a662b8cb5b3e2"), 0x1f07ffff, 4, 0); consensus.hashGenesisBlock = genesis.GetHash(); - assert(consensus.hashGenesisBlock == uint256S("0x00040fe8ec8471911baa1db1266ea15dd06b4a8a5c453883c000b031973dce08")); - assert(genesis.hashMerkleRoot == uint256S("0xc4eaa58879081de3c24a7b117ed2b28300e7ec4c4c1dff1d3f1268b7857a4ddb")); + assert(consensus.hashGenesisBlock == uint256S("0x0007104ccda289427919efc39dc9e4d499804b7bebc22df55f8b834301260602")); + assert(genesis.hashMerkleRoot == uint256S("0x19612bcf00ea7611d315d7f43554fa983c6e8c30cba17e52c679e0e80abf7d42")); vFixedSeeds.clear(); vSeeds.clear(); - vSeeds.push_back(CDNSSeedData("z.cash", "dnsseed.z.cash")); // Zcash - vSeeds.push_back(CDNSSeedData("str4d.xyz", "dnsseed.str4d.xyz")); // @str4d - vSeeds.push_back(CDNSSeedData("znodes.org", "dnsseed.znodes.org")); // @bitcartel + + vSeeds.push_back(CDNSSeedData("zclassic.org", "dnsseed.zclassic.org")); // zclassic + vSeeds.push_back(CDNSSeedData("zclassic-ce.org", "dnsseed.zclassic-ce.org")); // Zclassic Community + vSeeds.push_back(CDNSSeedData("zclassic.org", "na1.zclassic.org")); // zclassic + vSeeds.push_back(CDNSSeedData("zclassic.org", "na2.zclassic.org")); // zclassic + vSeeds.push_back(CDNSSeedData("zclassic.org", "na3.zclassic.org")); // zclassic + vSeeds.push_back(CDNSSeedData("zclassic.org", "eu1.zclassic.org")); // zclassic + vSeeds.push_back(CDNSSeedData("zclassic.org", "eu2.zclassic.org")); // zclassic + vSeeds.push_back(CDNSSeedData("zclassic.org", "eu3.zclassic.org")); // zclassic + vSeeds.push_back(CDNSSeedData("zclassic.org", "as1.zclassic.org")); // zclassic + vSeeds.push_back(CDNSSeedData("zclassic.org", "as2.zclassic.org")); // zclassic + vSeeds.push_back(CDNSSeedData("zclassic.org", "as3.zclassic.org")); // zclassic + vSeeds.push_back(CDNSSeedData("zclassic-ce.org", "na.zclassic-ce.org")); // Community + vSeeds.push_back(CDNSSeedData("zclassic-ce.org", "eu.zclassic-ce.org")); // Community + vSeeds.push_back(CDNSSeedData("zclassic-ce.org", "as.zclassic-ce.org")); // Community + vSeeds.push_back(CDNSSeedData("zclassic-ce.org", "sa.zclassic-ce.org")); // Community + + vSeeds.push_back(CDNSSeedData("chains.run", "seed.zcl.chains.run")); //rizkiwicaksono/bitcoin-seeder + + vSeeds.push_back(CDNSSeedData("indieonion.org", "dnsseed.indieonion.org")); // @IndieOnion + vSeeds.push_back(CDNSSeedData("rotorproject.org", "dnsseed.rotorproject.org")); // @IndieOnion // guarantees the first 2 characters, when base58 encoded, are "t1" base58Prefixes[PUBKEY_ADDRESS] = {0x1C,0xB8}; @@ -171,21 +189,13 @@ class CMainParams : public CChainParams { checkpointData = (CCheckpointData) { boost::assign::map_list_of - (0, consensus.hashGenesisBlock) - (2500, uint256S("0x00000006dc968f600be11a86cbfbf7feb61c7577f45caced2e82b6d261d19744")) - (15000, uint256S("0x00000000b6bc56656812a5b8dcad69d6ad4446dec23b5ec456c18641fb5381ba")) - (67500, uint256S("0x000000006b366d2c1649a6ebb4787ac2b39c422f451880bc922e3a6fbd723616")) - (100000, uint256S("0x000000001c5c82cd6baccfc0879e3830fd50d5ede17fa2c37a9a253c610eb285")) - (133337, uint256S("0x0000000002776ccfaf06cc19857accf3e20c01965282f916b8a886e3e4a05be9")) - (180000, uint256S("0x000000001205b742eac4a1b3959635bdf8aeada078d6a996df89740f7b54351d")) - (222222, uint256S("0x000000000cafb9e56445a6cabc8057b57ee6fcc709e7adbfa195e5c7fac61343")) - (270000, uint256S("0x00000000025c1cfa0258e33ab050aaa9338a3d4aaa3eb41defefc887779a9729")) - (304600, uint256S("0x00000000028324e022a45014c4a4dc51e95d41e6bceb6ad554c5b65d5cea3ea5")) - (410100, uint256S("0x0000000002c565958f783a24a4ac17cde898ff525e75ed9baf66861b0b9fcada")), - 1539405939, // * UNIX timestamp of last checkpoint block - 3954156, // * total number of transactions between genesis and last checkpoint + ( 0, consensus.hashGenesisBlock) + ( 30000, uint256S("0x000000005c2ad200c3c7c8e627f67b306659efca1268c9bb014335fdadc0c392")) + ( 160000, uint256S("0x000000065093005a1a46ee95d6d66c2b07008220ca64dd3b3a93bbd1945480c0")), + 1502742046, // * UNIX timestamp of last checkpoint block + 392489, // * total number of transactions between genesis and last checkpoint // (the tx=... number in the SetBestChain debug.log lines) - 5553 // * estimated number of transactions per day after checkpoint + 1413 // * estimated number of transactions per day after checkpoint // total number of tx / (checkpoint block height / (24 * 24)) }; @@ -259,10 +269,10 @@ class CTestNetParams : public CChainParams { public: CTestNetParams() { strNetworkID = "test"; - strCurrencyUnits = "TAZ"; + strCurrencyUnits = "ZCT"; bip44CoinType = 1; consensus.fCoinbaseMustBeProtected = true; - consensus.nSubsidySlowStartInterval = 20000; + consensus.nSubsidySlowStartInterval = 2; consensus.nSubsidyHalvingInterval = 840000; consensus.nMajorityEnforceBlockUpgrade = 51; consensus.nMajorityRejectBlockOutdated = 75; @@ -292,8 +302,8 @@ class CTestNetParams : public CChainParams { pchMessageStart[1] = 0x1a; pchMessageStart[2] = 0xf9; pchMessageStart[3] = 0xbf; - vAlertPubKey = ParseHex("044e7a1553392325c871c5ace5d6ad73501c66f4c185d6b0453cf45dec5a1322e705c672ac1a27ef7cdaf588c10effdf50ed5f95f85f2f54a5f6159fca394ed0c6"); - nDefaultPort = 18233; + vAlertPubKey = ParseHex("048679fb891b15d0cada9692047fd0ae26ad8bfb83fabddbb50334ee5bc0683294deb410be20513c5af6e7b9cec717ade82b27080ee6ef9a245c36a795ab044bb3"); + nDefaultPort = 18033; nPruneAfterHeight = 1000; const size_t N = 200, K = 9; BOOST_STATIC_ASSERT(equihash_parameters_acceptable(N, K)); @@ -301,17 +311,20 @@ class CTestNetParams : public CChainParams { nEquihashK = K; genesis = CreateGenesisBlock( - 1477648033, - uint256S("0x0000000000000000000000000000000000000000000000000000000000000006"), - ParseHex("00a6a51259c3f6732481e2d035197218b7a69504461d04335503cd69759b2d02bd2b53a9653f42cb33c608511c953673fa9da76170958115fe92157ad3bb5720d927f18e09459bf5c6072973e143e20f9bdf0584058c96b7c2234c7565f100d5eea083ba5d3dbaff9f0681799a113e7beff4a611d2b49590563109962baa149b628aae869af791f2f70bb041bd7ebfa658570917f6654a142b05e7ec0289a4f46470be7be5f693b90173eaaa6e84907170f32602204f1f4e1c04b1830116ffd0c54f0b1caa9a5698357bd8aa1f5ac8fc93b405265d824ba0e49f69dab5446653927298e6b7bdc61ee86ff31c07bde86331b4e500d42e4e50417e285502684b7966184505b885b42819a88469d1e9cf55072d7f3510f85580db689302eab377e4e11b14a91fdd0df7627efc048934f0aff8e7eb77eb17b3a95de13678004f2512293891d8baf8dde0ef69be520a58bbd6038ce899c9594cf3e30b8c3d9c7ecc832d4c19a6212747b50724e6f70f6451f78fd27b58ce43ca33b1641304a916186cfbe7dbca224f55d08530ba851e4df22baf7ab7078e9cbea46c0798b35a750f54103b0cdd08c81a6505c4932f6bfbd492a9fced31d54e98b6370d4c96600552fcf5b37780ed18c8787d03200963600db297a8f05dfa551321d17b9917edadcda51e274830749d133ad226f8bb6b94f13b4f77e67b35b71f52112ce9ba5da706ad9573584a2570a4ff25d29ab9761a06bdcf2c33638bf9baf2054825037881c14adf3816ba0cbd0fca689aad3ce16f2fe362c98f48134a9221765d939f0b49677d1c2447e56b46859f1810e2cf23e82a53e0d44f34dae932581b3b7f49eaec59af872cf9de757a964f7b33d143a36c270189508fcafe19398e4d2966948164d40556b05b7ff532f66f5d1edc41334ef742f78221dfe0c7ae2275bb3f24c89ae35f00afeea4e6ed187b866b209dc6e83b660593fce7c40e143beb07ac86c56f39e895385924667efe3a3f031938753c7764a2dbeb0a643fd359c46e614873fd0424e435fa7fac083b9a41a9d6bf7e284eee537ea7c50dd239f359941a43dc982745184bf3ee31a8dc850316aa9c6b66d6985acee814373be3458550659e1a06287c3b3b76a185c5cb93e38c1eebcf34ff072894b6430aed8d34122dafd925c46a515cca79b0269c92b301890ca6b0dc8b679cdac0f23318c105de73d7a46d16d2dad988d49c22e9963c117960bdc70ef0db6b091cf09445a516176b7f6d58ec29539166cc8a38bbff387acefffab2ea5faad0e8bb70625716ef0edf61940733c25993ea3de9f0be23d36e7cb8da10505f9dc426cd0e6e5b173ab4fff8c37e1f1fb56d1ea372013d075e0934c6919393cfc21395eea20718fad03542a4162a9ded66c814ad8320b2d7c2da3ecaf206da34c502db2096d1c46699a91dd1c432f019ad434e2c1ce507f91104f66f491fed37b225b8e0b2888c37276cfa0468fc13b8d593fd9a2675f0f5b20b8a15f8fa7558176a530d6865738ddb25d3426dab905221681cf9da0e0200eea5b2eba3ad3a5237d2a391f9074bf1779a2005cee43eec2b058511532635e0fea61664f531ac2b356f40db5c5d275a4cf5c82d468976455af4e3362cc8f71aa95e71d394aff3ead6f7101279f95bcd8a0fedce1d21cb3c9f6dd3b182fce0db5d6712981b651f29178a24119968b14783cafa713bc5f2a65205a42e4ce9dc7ba462bdb1f3e4553afc15f5f39998fdb53e7e231e3e520a46943734a007c2daa1eda9f495791657eefcac5c32833936e568d06187857ed04d7b97167ae207c5c5ae54e528c36016a984235e9c5b2f0718d7b3aa93c7822ccc772580b6599671b3c02ece8a21399abd33cfd3028790133167d0a97e7de53dc8ff"), + 1479443947, + uint256S("0x0000000000000000000000000000000000000000000000000000000000000013"), + ParseHex("002b24e10a5d2ab32b053a20ca6ebed779be1d935b1500eeea5c87aec684c6f934196fdfca6539de0cf1141544bffc5c0d1d4bab815fb5d8c2b195ccdf0755599ee492b9d98e3b79a178949f45485ad80dba38ec0461102adaa369b757ebb2bf8d75b5f67a341d666406d862a102c69800f20a7075be360a7eb2d315d78e4ce32c741f3baf7bf3e1e651976f734f367b1f126f62503b34d06d6e99b3659b2a47f5cfcf71c87e24e5023151d4af87454e7638a19b846350dd5fbc53e4ce1cce2597992b36cbcae0c24717e412c8df9ddca3e90c7629bd8c157c66d8906486943cf78e24d55dd4152f45eff49acf9fb9fddef81f2ee55892b38db940c404eaacf819588b83f0f761f1ba5b31a0ea1f8f4c5210638bbb59a2d8ddff9535f546b42a7eac5f3ee87616a075bddc3118b7f2c041f4b1e8dbcd11eea95835403066b5bb50cd23122dcb12166d75aafcfc1ca8f30580b4d48a5aa305657a06b4b650ed4633f2fa496235082feff65f70e19871f41b70632b53e57ddf38c207d631e5a56fa50bb71150f99427f73d82a439a5f70dfc7d8bbfc39d330ca7924527a5deb8950b9fa7020cfde5e07b84546e96764519ef6dd3fdc3a974abd342bdc7e4ee76bc11d5519541015afba1a0517fd347196aa326b0905a5916b83515c16f8f13105479c29f1eff3bc024ddbb07dcc672247cedc0d4ba32332ead0f13c58f50170642e16e076c34f5e75e3e8f5ac7f5238d67564fd385efecf972b0abf939a99bc7ef8f3a21cac21d2168706bbad3f4af66bb01cf61cfbc352a23797b62dcb5480bf2b7b277af233f5ce42a144d47119a89e1d114fa0bec2f13475b6b1df907bc3a429f1771afa3857bf16bfca3f76a5df14da62dc157fff4225bda73c3cfefa989edc24673bf932a024593da4c38b1a4628dd77ad919f4f7b7fb76976e696db69c89016ab30d9aa2d509f78d913d00ca9ac881aa759fc019b8c5e3eac6fddb4e0f044595e10d4997e29c79800f77cf1d97583d534db0f2726cba3739e7371eeffa2aca12b0d290ac45f44973f32f7675a5b49c94c4b608da2926555d16b7eb3670e12345a63f88797e5a5e21252c2c9463d7896001031a81bac0354336b35c5a10c93d9ae3054f6f6e4492f7c1f09a9d75034d5d0b220a9bb231e583659d5b6923a4e879326194de5c9805a02cb648508a8f9b6cd26dc17d322a478c1c599e1ec3adf2da6ce7a7e3a073b55cf30cf6b124f7700409abe14af8c60ab178579623916f165dbfd26f37056bf33c34f3af30939e1277376e4c5cba339f36381a05ef6481db033fb4c07a19e8655f8b12f9ab3c602e127b4ab1ee48e1c6a91382b54ed36ef9bb21b3bfa80a9107864dcb594dcad250e402b312607e648639631a3d1aeb17cfe3370202720ca8a46db15af92e8b46062b5bd035b24c35a592e5620d632faf1bf19a86df179fe52dd4cdbecd3cb7a336ca7489e4d1dc9433f1163c89d88c5eac36fc562496dc7583fe67c559c9a71cf89e9a0a59d5a14764926852d44a88d2ddb361d612ec06f9de874473eaf1d36b3a41911ac072b7826e6acea3d8425dc271833dba2ec17d1a270e49becbf21330ba2f0edc4b05f4df01623f3c82246ae23ea2c022434ef09611aa19ba35c3ecbad965af3ad9bc6c9b0d3b059c239ffbf9272d0150c151b4510d659cbd0e4a9c32945c612681b70ee4dcbeefeacde630b127115fd9af16cef4afefe611c9dfcc63e6833bf4dab79a7e1ae3f70321429557ab9da48bf93647830b5eb5780f23476d3d4d06a39ae532da5b2f30f151587eb5df19ec1acf099e1ac506e071eb52c3c3cc88ccf6622b2913acf07f1b772b5012e39173211e51773f3eb42d667fff1d902c5c87bd507837b3fd993e70ac9706a0"), 0x2007ffff, 4, 0); consensus.hashGenesisBlock = genesis.GetHash(); - assert(consensus.hashGenesisBlock == uint256S("0x05a60a92d99d85997cce3b87616c089f6124d7342af37106edc76126334a2c38")); - assert(genesis.hashMerkleRoot == uint256S("0xc4eaa58879081de3c24a7b117ed2b28300e7ec4c4c1dff1d3f1268b7857a4ddb")); + assert(consensus.hashGenesisBlock == uint256S("0x03e1c4bb705c871bf9bfda3e74b7f8f86bff267993c215a89d5795e3708e5e1f")); +// assert(genesis.hashMerkleRoot == uint256S("0xc4eaa58879081de3c24a7b117ed2b28300e7ec4c4c1dff1d3f1268b7857a4ddb")); vFixedSeeds.clear(); vSeeds.clear(); - vSeeds.push_back(CDNSSeedData("z.cash", "dnsseed.testnet.z.cash")); // Zcash + + vSeeds.push_back(CDNSSeedData("zclassic.org", "dnsseed.testnet.zclassic.org")); // Zclassic + vSeeds.push_back(CDNSSeedData("zclassic-ce.org", "dnsseed.testnet.zclassic-ce.org")); // Zclassic Community + vSeeds.push_back(CDNSSeedData("zclassic-ce.org", "eu.testnet.zclassic-ce.org")); // Zclassic Community // guarantees the first 2 characters, when base58 encoded, are "tm" base58Prefixes[PUBKEY_ADDRESS] = {0x1D,0x25}; @@ -345,28 +358,26 @@ class CTestNetParams : public CChainParams { checkpointData = (CCheckpointData) { boost::assign::map_list_of - (0, consensus.hashGenesisBlock) - (38000, uint256S("0x001e9a2d2e2892b88e9998cf7b079b41d59dd085423a921fe8386cecc42287b8")), - 1486897419, // * UNIX timestamp of last checkpoint block - 47163, // * total number of transactions between genesis and last checkpoint - // (the tx=... number in the SetBestChain debug.log lines) - 715 // total number of tx / (checkpoint block height / (24 * 24)) + ( 0, consensus.hashGenesisBlock), + genesis.nTime, + 0, + 0 }; // Founders reward script expects a vector of 2-of-3 multisig addresses vFoundersRewardAddress = { "t2UNzUUx8mWBCRYPRezvA363EYXyEpHokyi", "t2N9PH9Wk9xjqYg9iin1Ua3aekJqfAtE543", "t2NGQjYMQhFndDHguvUw4wZdNdsssA6K7x2", "t2ENg7hHVqqs9JwU5cgjvSbxnT2a9USNfhy", - "t2BkYdVCHzvTJJUTx4yZB8qeegD8QsPx8bo", "t2J8q1xH1EuigJ52MfExyyjYtN3VgvshKDf", "t2Crq9mydTm37kZokC68HzT6yez3t2FBnFj", "t2EaMPUiQ1kthqcP5UEkF42CAFKJqXCkXC9", - "t2F9dtQc63JDDyrhnfpzvVYTJcr57MkqA12", "t2LPirmnfYSZc481GgZBa6xUGcoovfytBnC", "t26xfxoSw2UV9Pe5o3C8V4YybQD4SESfxtp", "t2D3k4fNdErd66YxtvXEdft9xuLoKD7CcVo", - "t2DWYBkxKNivdmsMiivNJzutaQGqmoRjRnL", "t2C3kFF9iQRxfc4B9zgbWo4dQLLqzqjpuGQ", "t2MnT5tzu9HSKcppRyUNwoTp8MUueuSGNaB", "t2AREsWdoW1F8EQYsScsjkgqobmgrkKeUkK", - "t2Vf4wKcJ3ZFtLj4jezUUKkwYR92BLHn5UT", "t2K3fdViH6R5tRuXLphKyoYXyZhyWGghDNY", "t2VEn3KiKyHSGyzd3nDw6ESWtaCQHwuv9WC", "t2F8XouqdNMq6zzEvxQXHV1TjwZRHwRg8gC", - "t2BS7Mrbaef3fA4xrmkvDisFVXVrRBnZ6Qj", "t2FuSwoLCdBVPwdZuYoHrEzxAb9qy4qjbnL", "t2SX3U8NtrT6gz5Db1AtQCSGjrpptr8JC6h", "t2V51gZNSoJ5kRL74bf9YTtbZuv8Fcqx2FH", - "t2FyTsLjjdm4jeVwir4xzj7FAkUidbr1b4R", "t2EYbGLekmpqHyn8UBF6kqpahrYm7D6N1Le", "t2NQTrStZHtJECNFT3dUBLYA9AErxPCmkka", "t2GSWZZJzoesYxfPTWXkFn5UaxjiYxGBU2a", - "t2RpffkzyLRevGM3w9aWdqMX6bd8uuAK3vn", "t2JzjoQqnuXtTGSN7k7yk5keURBGvYofh1d", "t2AEefc72ieTnsXKmgK2bZNckiwvZe3oPNL", "t2NNs3ZGZFsNj2wvmVd8BSwSfvETgiLrD8J", - "t2ECCQPVcxUCSSQopdNquguEPE14HsVfcUn", "t2JabDUkG8TaqVKYfqDJ3rqkVdHKp6hwXvG", "t2FGzW5Zdc8Cy98ZKmRygsVGi6oKcmYir9n", "t2DUD8a21FtEFn42oVLp5NGbogY13uyjy9t", - "t2UjVSd3zheHPgAkuX8WQW2CiC9xHQ8EvWp", "t2TBUAhELyHUn8i6SXYsXz5Lmy7kDzA1uT5", "t2Tz3uCyhP6eizUWDc3bGH7XUC9GQsEyQNc", "t2NysJSZtLwMLWEJ6MH3BsxRh6h27mNcsSy", - "t2KXJVVyyrjVxxSeazbY9ksGyft4qsXUNm9", "t2J9YYtH31cveiLZzjaE4AcuwVho6qjTNzp", "t2QgvW4sP9zaGpPMH1GRzy7cpydmuRfB4AZ", "t2NDTJP9MosKpyFPHJmfjc5pGCvAU58XGa4", - "t29pHDBWq7qN4EjwSEHg8wEqYe9pkmVrtRP", "t2Ez9KM8VJLuArcxuEkNRAkhNvidKkzXcjJ", "t2D5y7J5fpXajLbGrMBQkFg2mFN8fo3n8cX", "t2UV2wr1PTaUiybpkV3FdSdGxUJeZdZztyt", + "t2BkYdVCHzvTJJUTx4yZB8qeegD8QsPx8bo", "t2J8q1xH1EuigJ52MfExyyjYtN3VgvshKDf", "t2Crq9mydTm37kZokC68HzT6yez3t2FBnFj", "t2EaMPUiQ1kthqcP5UEkF42CAFKJqXCkXC9", + "t2F9dtQc63JDDyrhnfpzvVYTJcr57MkqA12", "t2LPirmnfYSZc481GgZBa6xUGcoovfytBnC", "t26xfxoSw2UV9Pe5o3C8V4YybQD4SESfxtp", "t2D3k4fNdErd66YxtvXEdft9xuLoKD7CcVo", + "t2DWYBkxKNivdmsMiivNJzutaQGqmoRjRnL", "t2C3kFF9iQRxfc4B9zgbWo4dQLLqzqjpuGQ", "t2MnT5tzu9HSKcppRyUNwoTp8MUueuSGNaB", "t2AREsWdoW1F8EQYsScsjkgqobmgrkKeUkK", + "t2Vf4wKcJ3ZFtLj4jezUUKkwYR92BLHn5UT", "t2K3fdViH6R5tRuXLphKyoYXyZhyWGghDNY", "t2VEn3KiKyHSGyzd3nDw6ESWtaCQHwuv9WC", "t2F8XouqdNMq6zzEvxQXHV1TjwZRHwRg8gC", + "t2BS7Mrbaef3fA4xrmkvDisFVXVrRBnZ6Qj", "t2FuSwoLCdBVPwdZuYoHrEzxAb9qy4qjbnL", "t2SX3U8NtrT6gz5Db1AtQCSGjrpptr8JC6h", "t2V51gZNSoJ5kRL74bf9YTtbZuv8Fcqx2FH", + "t2FyTsLjjdm4jeVwir4xzj7FAkUidbr1b4R", "t2EYbGLekmpqHyn8UBF6kqpahrYm7D6N1Le", "t2NQTrStZHtJECNFT3dUBLYA9AErxPCmkka", "t2GSWZZJzoesYxfPTWXkFn5UaxjiYxGBU2a", + "t2RpffkzyLRevGM3w9aWdqMX6bd8uuAK3vn", "t2JzjoQqnuXtTGSN7k7yk5keURBGvYofh1d", "t2AEefc72ieTnsXKmgK2bZNckiwvZe3oPNL", "t2NNs3ZGZFsNj2wvmVd8BSwSfvETgiLrD8J", + "t2ECCQPVcxUCSSQopdNquguEPE14HsVfcUn", "t2JabDUkG8TaqVKYfqDJ3rqkVdHKp6hwXvG", "t2FGzW5Zdc8Cy98ZKmRygsVGi6oKcmYir9n", "t2DUD8a21FtEFn42oVLp5NGbogY13uyjy9t", + "t2UjVSd3zheHPgAkuX8WQW2CiC9xHQ8EvWp", "t2TBUAhELyHUn8i6SXYsXz5Lmy7kDzA1uT5", "t2Tz3uCyhP6eizUWDc3bGH7XUC9GQsEyQNc", "t2NysJSZtLwMLWEJ6MH3BsxRh6h27mNcsSy", + "t2KXJVVyyrjVxxSeazbY9ksGyft4qsXUNm9", "t2J9YYtH31cveiLZzjaE4AcuwVho6qjTNzp", "t2QgvW4sP9zaGpPMH1GRzy7cpydmuRfB4AZ", "t2NDTJP9MosKpyFPHJmfjc5pGCvAU58XGa4", + "t29pHDBWq7qN4EjwSEHg8wEqYe9pkmVrtRP", "t2Ez9KM8VJLuArcxuEkNRAkhNvidKkzXcjJ", "t2D5y7J5fpXajLbGrMBQkFg2mFN8fo3n8cX", "t2UV2wr1PTaUiybpkV3FdSdGxUJeZdZztyt", }; assert(vFoundersRewardAddress.size() <= consensus.GetLastFoundersRewardBlockHeight()); } @@ -423,13 +434,13 @@ class CRegTestParams : public CChainParams { nEquihashK = K; genesis = CreateGenesisBlock( - 1296688602, + 1482971059, uint256S("0x0000000000000000000000000000000000000000000000000000000000000009"), - ParseHex("01936b7db1eb4ac39f151b8704642d0a8bda13ec547d54cd5e43ba142fc6d8877cab07b3"), + ParseHex("05ffd6ad016271ade20cfce093959c3addb2079629f9f123c52ef920caa316531af5af3f"), 0x200f0f0f, 4, 0); consensus.hashGenesisBlock = genesis.GetHash(); - assert(consensus.hashGenesisBlock == uint256S("0x029f11d80ef9765602235e1bc9727e3eb6ba20839319f761fee920d63401e327")); - assert(genesis.hashMerkleRoot == uint256S("0xc4eaa58879081de3c24a7b117ed2b28300e7ec4c4c1dff1d3f1268b7857a4ddb")); + assert(consensus.hashGenesisBlock == uint256S("0x0575f78ee8dc057deee78ef691876e3be29833aaee5e189bb0459c087451305a")); +// assert(genesis.hashMerkleRoot == uint256S("0xc4eaa58879081de3c24a7b117ed2b28300e7ec4c4c1dff1d3f1268b7857a4ddb")); vFixedSeeds.clear(); //! Regtest mode doesn't have any fixed seeds. vSeeds.clear(); //! Regtest mode doesn't have any DNS seeds. diff --git a/src/init.cpp b/src/init.cpp index 4748897ad99..ca8f48a825c 100644 --- a/src/init.cpp +++ b/src/init.cpp @@ -345,7 +345,7 @@ std::string HelpMessage(HelpMessageMode mode) strUsage += HelpMessageOpt("-blocknotify=", _("Execute command when the best block changes (%s in cmd is replaced by block hash)")); strUsage += HelpMessageOpt("-checkblocks=", strprintf(_("How many blocks to check at startup (default: %u, 0 = all)"), 288)); strUsage += HelpMessageOpt("-checklevel=", strprintf(_("How thorough the block verification of -checkblocks is (0-4, default: %u)"), 3)); - strUsage += HelpMessageOpt("-conf=", strprintf(_("Specify configuration file (default: %s)"), "zcash.conf")); + strUsage += HelpMessageOpt("-conf=", strprintf(_("Specify configuration file (default: %s)"), "zclassic.conf")); if (mode == HMM_BITCOIND) { #if !defined(WIN32) @@ -361,7 +361,7 @@ std::string HelpMessage(HelpMessageMode mode) strUsage += HelpMessageOpt("-par=", strprintf(_("Set the number of script verification threads (%u to %d, 0 = auto, <0 = leave that many cores free, default: %d)"), -GetNumCores(), MAX_SCRIPTCHECK_THREADS, DEFAULT_SCRIPTCHECK_THREADS)); #ifndef WIN32 - strUsage += HelpMessageOpt("-pid=", strprintf(_("Specify pid file (default: %s)"), "zcashd.pid")); + strUsage += HelpMessageOpt("-pid=", strprintf(_("Specify pid file (default: %s)"), "zclassicd.pid")); #endif strUsage += HelpMessageOpt("-prune=", strprintf(_("Reduce storage requirements by pruning (deleting) old blocks. This mode disables wallet support and is incompatible with -txindex. " "Warning: Reverting this setting requires re-downloading the entire blockchain. " @@ -854,7 +854,7 @@ bool AppInit2(boost::thread_group& threadGroup, CScheduler& scheduler) fLogIPs = GetBoolArg("-logips", false); LogPrintf("\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n"); - LogPrintf("Zcash version %s (%s)\n", FormatFullVersion(), CLIENT_DATE); + LogPrintf("ZClassic version %s (%s)\n", FormatFullVersion(), CLIENT_DATE); // when specifying an explicit binding address, you want to listen on it // even when -connect or -proxy is specified @@ -1153,7 +1153,7 @@ bool AppInit2(boost::thread_group& threadGroup, CScheduler& scheduler) // Sanity check if (!InitSanityCheck()) - return InitError(_("Initialization sanity check failed. Zcash is shutting down.")); + return InitError(_("Initialization sanity check failed. ZClassic is shutting down.")); std::string strDataDir = GetDataDir().string(); #ifdef ENABLE_WALLET @@ -1169,9 +1169,9 @@ bool AppInit2(boost::thread_group& threadGroup, CScheduler& scheduler) try { static boost::interprocess::file_lock lock(pathLockFile.string().c_str()); if (!lock.try_lock()) - return InitError(strprintf(_("Cannot obtain a lock on data directory %s. Zcash is probably already running."), strDataDir)); + return InitError(strprintf(_("Cannot obtain a lock on data directory %s. ZClassic is probably already running."), strDataDir)); } catch(const boost::interprocess::interprocess_exception& e) { - return InitError(strprintf(_("Cannot obtain a lock on data directory %s. Zcash is probably already running.") + " %s.", strDataDir, e.what())); + return InitError(strprintf(_("Cannot obtain a lock on data directory %s. ZClassic is probably already running.") + " %s.", strDataDir, e.what())); } #ifndef WIN32 @@ -1620,10 +1620,10 @@ bool AppInit2(boost::thread_group& threadGroup, CScheduler& scheduler) InitWarning(msg); } else if (nLoadWalletRet == DB_TOO_NEW) - strErrors << _("Error loading wallet.dat: Wallet requires newer version of Zcash") << "\n"; + strErrors << _("Error loading wallet.dat: Wallet requires newer version of ZClassic") << "\n"; else if (nLoadWalletRet == DB_NEED_REWRITE) { - strErrors << _("Wallet needed to be rewritten: restart Zcash to complete") << "\n"; + strErrors << _("Wallet needed to be rewritten: restart ZClassic to complete") << "\n"; LogPrintf("%s", strErrors.str()); return InitError(strErrors.str()); } @@ -1730,10 +1730,10 @@ bool AppInit2(boost::thread_group& threadGroup, CScheduler& scheduler) #ifdef ENABLE_MINING #ifndef ENABLE_WALLET if (GetBoolArg("-minetolocalwallet", false)) { - return InitError(_("Zcash was not built with wallet support. Set -minetolocalwallet=0 to use -mineraddress, or rebuild Zcash with wallet support.")); + return InitError(_("ZClassic was not built with wallet support. Set -minetolocalwallet=0 to use -mineraddress, or rebuild ZClassic with wallet support.")); } if (GetArg("-mineraddress", "").empty() && GetBoolArg("-gen", false)) { - return InitError(_("Zcash was not built with wallet support. Set -mineraddress, or rebuild Zcash with wallet support.")); + return InitError(_("ZClassic was not built with wallet support. Set -mineraddress, or rebuild ZClassic with wallet support.")); } #endif // !ENABLE_WALLET diff --git a/src/metrics.cpp b/src/metrics.cpp index 680b74bb53e..c260c81e466 100644 --- a/src/metrics.cpp +++ b/src/metrics.cpp @@ -262,7 +262,7 @@ int printMiningStatus(bool mining) lines++; } else { std::cout << _("You are currently not mining.") << std::endl; - std::cout << _("To enable mining, add 'gen=1' to your zcash.conf and restart.") << std::endl; + std::cout << _("To enable mining, add 'gen=1' to your zclassic.conf and restart.") << std::endl; lines += 2; } std::cout << std::endl; @@ -461,7 +461,7 @@ void ThreadShowMetricsScreen() std::cout << std::endl; // Thank you text - std::cout << _("Thank you for running a Zcash node!") << std::endl; + std::cout << _("Thank you for running a ZClassic node!") << std::endl; std::cout << _("You're helping to strengthen the network and contributing to a social good :)") << std::endl; // Privacy notice text @@ -514,7 +514,7 @@ void ThreadShowMetricsScreen() // Explain how to exit std::cout << "["; #ifdef WIN32 - std::cout << _("'zcash-cli.exe stop' to exit"); + std::cout << _("'zclassic-cli.exe stop' to exit"); #else std::cout << _("Press Ctrl+C to exit"); #endif diff --git a/src/metrics.h b/src/metrics.h index 2d60d30ca6a..f9656d05498 100644 --- a/src/metrics.h +++ b/src/metrics.h @@ -80,24 +80,24 @@ void ThreadShowMetricsScreen(); * Zcash: img2txt -W 40 -H 20 -f utf8 -d none -g 0.7 Z-yellow.orange-logo.png * Heart: img2txt -W 40 -H 20 -f utf8 -d none 2000px-Heart_corazón.svg.png */ -const std::string METRICS_ART = -"   \n" -"   \n" -"  :88SX@888@@X8:  8; %X X% ;8 \n" -"  %%Xt%tt%SSSSS:XXXt@@  X :: :: X \n" -"  @S;;tt%%%t ;;::XXXXSX  % SS % \n" -"  .t:::;;%8888 88888tXXXX8;  S S \n" -"  .%...:::8 8::XXX%;  X X \n" -"  8888...:t888888X 8t;;::XX8   8 8 \n" -" %888888...:::;:8  :Xttt;;;::X@    \n" -" 888888888...:St 8:%%tttt;;;:X  X X \n" -" 88888888888S8  :%;ttt%%tttt;;X  8 8 \n" -" %888888888%t 8S:;;;tt%%%ttt;8  : : \n" -"  8t8888888  S8888888Stt%%%t@   :: :: \n" -"  .@tt888@ 8;;ttt@;  t t \n" -"  .8ttt8@SSSSS SXXXX%:;;;X;  8 8 \n" -"  X8ttt8888% %88...::X8   X. .X \n" -"  %8@tt88;8888%8888%8X   :; ;: \n" -"  :@888@XXX@888:  tt \n" -"   \n" -"   "; + const std::string METRICS_ART = + " ::: ::: \n" + " ;...:::....% \n" + " X8;..................;:X \n" + " ......;8t:... ...:;8;....; ;888888 %88888S \n" + " t;....: ... ... :S 8 :8 @ : \n" + " S....: ... ... S S  : \n" + " t...; ;.................. %  \n" + " ....t %.................;  X \n" + " 8.... :......:  X \n" + " ....; :......:   \n" + " ....; ;.....;S @ : \n" + " ....; :......:  @ \n" + " ....: ........;:::::::::: : 8 \n" + " ....t ...................; % :@ \n" + " ;....: X... X...X S 8 \n" + " 8....;S ... ... %S S 8 \n" + " S;......% %... ...%Xt:.....S S 8 \n" + " ;:....................:; 8 S \n" + " 8...:::;...: \n" + " ... ... \n"; diff --git a/src/rpc/blockchain.cpp b/src/rpc/blockchain.cpp index 9a9b0fd572e..60708b80655 100644 --- a/src/rpc/blockchain.cpp +++ b/src/rpc/blockchain.cpp @@ -51,7 +51,7 @@ double GetDifficultyINTERNAL(const CBlockIndex* blockindex, bool networkDifficul int nShiftAmount = (powLimit >> 24) & 0xff; double dDiff = - (double)(powLimit & 0x00ffffff) / + (double)(powLimit & 0x00ffffff) / (double)(bits & 0x00ffffff); while (nShift < nShiftAmount) diff --git a/src/rpc/mining.cpp b/src/rpc/mining.cpp index a6467d5b28d..4b4c9f96703 100644 --- a/src/rpc/mining.cpp +++ b/src/rpc/mining.cpp @@ -145,7 +145,7 @@ UniValue getgenerate(const UniValue& params, bool fHelp) throw runtime_error( "getgenerate\n" "\nReturn if the server is set to generate coins or not. The default is false.\n" - "It is set with the command line argument -gen (or zcash.conf setting gen)\n" + "It is set with the command line argument -gen (or zclassic.conf setting gen)\n" "It can also be set with the setgenerate call.\n" "\nResult\n" "true|false (boolean) If the server is set to generate coins or not\n" @@ -180,7 +180,7 @@ UniValue generate(const UniValue& params, bool fHelp) throw JSONRPCError(RPC_METHOD_NOT_FOUND, "Wallet disabled and -mineraddress not set"); } #else - throw JSONRPCError(RPC_METHOD_NOT_FOUND, "zcashd compiled without wallet and -mineraddress not set"); + throw JSONRPCError(RPC_METHOD_NOT_FOUND, "zclassicd compiled without wallet and -mineraddress not set"); #endif } if (!Params().MineBlocksOnDemand()) @@ -295,7 +295,7 @@ UniValue setgenerate(const UniValue& params, bool fHelp) throw JSONRPCError(RPC_METHOD_NOT_FOUND, "Wallet disabled and -mineraddress not set"); } #else - throw JSONRPCError(RPC_METHOD_NOT_FOUND, "zcashd compiled without wallet and -mineraddress not set"); + throw JSONRPCError(RPC_METHOD_NOT_FOUND, "zclassicd compiled without wallet and -mineraddress not set"); #endif } if (Params().MineBlocksOnDemand()) @@ -498,7 +498,7 @@ UniValue getblocktemplate(const UniValue& params, bool fHelp) throw JSONRPCError(RPC_METHOD_NOT_FOUND, "Wallet disabled and -mineraddress not set"); } #else - throw JSONRPCError(RPC_METHOD_NOT_FOUND, "zcashd compiled without wallet and -mineraddress not set"); + throw JSONRPCError(RPC_METHOD_NOT_FOUND, "zclassicd compiled without wallet and -mineraddress not set"); #endif } @@ -555,10 +555,10 @@ UniValue getblocktemplate(const UniValue& params, bool fHelp) throw JSONRPCError(RPC_INVALID_PARAMETER, "Invalid mode"); if (vNodes.empty()) - throw JSONRPCError(RPC_CLIENT_NOT_CONNECTED, "Zcash is not connected!"); + throw JSONRPCError(RPC_CLIENT_NOT_CONNECTED, "ZClassic is not connected!"); if (IsInitialBlockDownload()) - throw JSONRPCError(RPC_CLIENT_IN_INITIAL_DOWNLOAD, "Zcash is downloading blocks..."); + throw JSONRPCError(RPC_CLIENT_IN_INITIAL_DOWNLOAD, "ZClassic is downloading blocks..."); static unsigned int nTransactionsUpdatedLast; diff --git a/src/rpc/server.cpp b/src/rpc/server.cpp index 4e18cfcb79f..d668b1bdbe3 100644 --- a/src/rpc/server.cpp +++ b/src/rpc/server.cpp @@ -245,11 +245,11 @@ UniValue stop(const UniValue& params, bool fHelp) if (fHelp || params.size() > 1) throw runtime_error( "stop\n" - "\nStop Zcash server."); + "\nStop ZClassic server."); // Event loop will exit after current HTTP requests have been handled, so // this reply will get back to the client. StartShutdown(); - return "Zcash server stopping"; + return "ZClassic server stopping"; } /** @@ -458,7 +458,7 @@ UniValue CRPCTable::execute(const std::string &strMethod, const UniValue ¶ms std::string HelpExampleCli(const std::string& methodname, const std::string& args) { - return "> zcash-cli " + methodname + " " + args + "\n"; + return "> zclassic-cli " + methodname + " " + args + "\n"; } std::string HelpExampleRpc(const std::string& methodname, const std::string& args) @@ -470,9 +470,9 @@ std::string HelpExampleRpc(const std::string& methodname, const std::string& arg string experimentalDisabledHelpMsg(const string& rpc, const string& enableArg) { return "\nWARNING: " + rpc + " is disabled.\n" - "To enable it, restart zcashd with the -experimentalfeatures and\n" + "To enable it, restart zclassicd with the -experimentalfeatures and\n" "-" + enableArg + " commandline options, or add these two lines\n" - "to the zcash.conf file:\n\n" + "to the zclassic.conf file:\n\n" "experimentalfeatures=1\n" + enableArg + "=1\n"; } diff --git a/src/sendalert.cpp b/src/sendalert.cpp index b6515d6b361..f18b0d6b104 100644 --- a/src/sendalert.cpp +++ b/src/sendalert.cpp @@ -27,7 +27,7 @@ Modify the alert parameters, id and message found in this file. Build and run with -sendalert or -printalert. -./zcashd -printtoconsole -sendalert +./zclassicd -printtoconsole -sendalert One minute after starting up, the alert will be broadcast. It is then flooded through the network until the nRelayUntil time, and will be @@ -90,7 +90,7 @@ void ThreadSendAlert() // 4000 or higher will put the RPC into safe mode alert.nPriority = 4000; alert.strComment = ""; - alert.strStatusBar = "Your client is out of date and incompatible with the Sapling network upgrade. Please update to a recent version of Zcash (2.0.1 or later)."; + alert.strStatusBar = "Your client is out of date and incompatible with the Sapling network upgrade. Please update to a recent version of ZClassic (2.0.1 or later)."; alert.strRPCError = alert.strStatusBar; // Set specific client version/versions here. If setSubVer is empty, no filtering on subver is done: diff --git a/src/test/data/bitcoin-util-test.json b/src/test/data/bitcoin-util-test.json index ac454fb9aa3..120b5664827 100644 --- a/src/test/data/bitcoin-util-test.json +++ b/src/test/data/bitcoin-util-test.json @@ -1,39 +1,39 @@ [ - { "exec": "././zcash-tx", + { "exec": "././zclassic-tx", "args": ["-create"], "output_cmp": "blanktx.hex" }, - { "exec": "./zcash-tx", + { "exec": "./zclassic-tx", "args": ["-"], "input": "blanktx.hex", "output_cmp": "blanktx.hex" }, - { "exec": "./zcash-tx", + { "exec": "./zclassic-tx", "args": ["-", "delin=1"], "input": "tx394b54bb.hex", "output_cmp": "tt-delin1-out.hex" }, - { "exec": "./zcash-tx", + { "exec": "./zclassic-tx", "args": ["-", "delin=31"], "input": "tx394b54bb.hex", "return_code": 1 }, - { "exec": "./zcash-tx", + { "exec": "./zclassic-tx", "args": ["-", "delout=1"], "input": "tx394b54bb.hex", "output_cmp": "tt-delout1-out.hex" }, - { "exec": "./zcash-tx", + { "exec": "./zclassic-tx", "args": ["-", "delout=2"], "input": "tx394b54bb.hex", "return_code": 1 }, - { "exec": "./zcash-tx", + { "exec": "./zclassic-tx", "args": ["-", "locktime=317000"], "input": "tx394b54bb.hex", "output_cmp": "tt-locktime317000-out.hex" }, - { "exec": "./zcash-tx", + { "exec": "./zclassic-tx", "args": ["-create", "in=5897de6bd6027a475eadd57019d4e6872c396d0716c4875a5f1a6fcfdf385c1f:0", @@ -43,11 +43,11 @@ "outaddr=4:t1g1aXFye74HKJ24VviTxo3AW4BZbyCni5H"], "output_cmp": "txcreate1.hex" }, - { "exec": "./zcash-tx", + { "exec": "./zclassic-tx", "args": ["-create", "outscript=0:"], "output_cmp": "txcreate2.hex" }, - { "exec": "./zcash-tx", + { "exec": "./zclassic-tx", "args": ["-create", "in=4d49a71ec9da436f71ec4ee231d04f292a29cd316f598bb7068feccabdc59485:0", @@ -57,14 +57,14 @@ "outaddr=0.001:t1Ruz6gK4QPZoPPGpHaieupnnh62mktjQE7"], "output_cmp": "txcreatesign.hex" }, - { "exec": "./zcash-tx", + { "exec": "./zclassic-tx", "args": ["-create", "in=5897de6bd6027a475eadd57019d4e6872c396d0716c4875a5f1a6fcfdf385c1f:0:4294967293", "outaddr=0.18:t1LmWJddYzkTmTQjZrX7ZkFjmuEu5XKpGKb"], "output_cmp": "txcreatedata_seq0.hex" }, - { "exec": "./zcash-tx", + { "exec": "./zclassic-tx", "args": ["01000000011f5c38dfcf6f1a5f5a87c416076d392c87e6d41970d5ad5e477a02d66bde97580000000000fdffffff0180a81201000000001976a9141fc11f39be1729bf973a7ab6a615ca4729d6457488ac00000000", "in=5897de6bd6027a475eadd57019d4e6872c396d0716c4875a5f1a6fcfdf385c1f:0:1"], diff --git a/src/util.cpp b/src/util.cpp index 947538f01b5..919361db16c 100644 --- a/src/util.cpp +++ b/src/util.cpp @@ -465,7 +465,7 @@ boost::filesystem::path GetDefaultDataDir() // Unix: ~/.zcash #ifdef WIN32 // Windows - return GetSpecialFolderPath(CSIDL_APPDATA) / "Zcash"; + return GetSpecialFolderPath(CSIDL_APPDATA) / "ZClassic"; #else fs::path pathRet; char* pszHome = getenv("HOME"); @@ -477,10 +477,10 @@ boost::filesystem::path GetDefaultDataDir() // Mac pathRet /= "Library/Application Support"; TryCreateDirectory(pathRet); - return pathRet / "Zcash"; + return pathRet / "ZClassic"; #else // Unix - return pathRet / ".zcash"; + return pathRet / ".zclassic"; #endif #endif } @@ -597,7 +597,7 @@ void ClearDatadirCache() boost::filesystem::path GetConfigFile() { - boost::filesystem::path pathConfigFile(GetArg("-conf", "zcash.conf")); + boost::filesystem::path pathConfigFile(GetArg("-conf", "zclassic.conf")); if (!pathConfigFile.is_complete()) pathConfigFile = GetDataDir(false) / pathConfigFile; @@ -616,7 +616,7 @@ void ReadConfigFile(map& mapSettingsRet, for (boost::program_options::detail::config_file_iterator it(streamConfig, setOptions), end; it != end; ++it) { - // Don't overwrite existing settings so command line settings override zcash.conf + // Don't overwrite existing settings so command line settings override zclassic.conf string strKey = string("-") + it->string_key; if (mapSettingsRet.count(strKey) == 0) { @@ -906,7 +906,7 @@ void SetThreadPriority(int nPriority) std::string PrivacyInfo() { return "\n" + - FormatParagraph(strprintf(_("In order to ensure you are adequately protecting your privacy when using Zcash, please see <%s>."), + FormatParagraph(strprintf(_("In order to ensure you are adequately protecting your privacy when using ZClassic, please see <%s>."), "https://z.cash/support/security/")) + "\n"; } @@ -928,4 +928,3 @@ int GetNumCores() { return boost::thread::physical_concurrency(); } - diff --git a/src/wallet/rpcdump.cpp b/src/wallet/rpcdump.cpp index 600d0de8bb0..9f9eadef4a5 100644 --- a/src/wallet/rpcdump.cpp +++ b/src/wallet/rpcdump.cpp @@ -65,7 +65,7 @@ std::string DecodeDumpString(const std::string &str) { for (unsigned int pos = 0; pos < str.length(); pos++) { unsigned char c = str[pos]; if (c == '%' && pos+2 < str.length()) { - c = (((str[pos+1]>>6)*9+((str[pos+1]-'0')&15)) << 4) | + c = (((str[pos+1]>>6)*9+((str[pos+1]-'0')&15)) << 4) | ((str[pos+2]>>6)*9+((str[pos+2]-'0')&15)); pos += 2; } @@ -78,7 +78,7 @@ UniValue importprivkey(const UniValue& params, bool fHelp) { if (!EnsureWalletIsAvailable(fHelp)) return NullUniValue; - + if (fHelp || params.size() < 1 || params.size() > 3) throw runtime_error( "importprivkey \"zcashprivkey\" ( \"label\" rescan )\n" @@ -148,7 +148,7 @@ UniValue importaddress(const UniValue& params, bool fHelp) { if (!EnsureWalletIsAvailable(fHelp)) return NullUniValue; - + if (fHelp || params.size() < 1 || params.size() > 3) throw runtime_error( "importaddress \"address\" ( \"label\" rescan )\n" @@ -178,7 +178,7 @@ UniValue importaddress(const UniValue& params, bool fHelp) std::vector data(ParseHex(params[0].get_str())); script = CScript(data.begin(), data.end()); } else { - throw JSONRPCError(RPC_INVALID_ADDRESS_OR_KEY, "Invalid Zcash address or script"); + throw JSONRPCError(RPC_INVALID_ADDRESS_OR_KEY, "Invalid ZClassic address or script"); } string strLabel = ""; @@ -244,7 +244,7 @@ UniValue importwallet(const UniValue& params, bool fHelp) { if (!EnsureWalletIsAvailable(fHelp)) return NullUniValue; - + if (fHelp || params.size() != 1) throw runtime_error( "importwallet \"filename\"\n" @@ -376,7 +376,7 @@ UniValue dumpprivkey(const UniValue& params, bool fHelp) { if (!EnsureWalletIsAvailable(fHelp)) return NullUniValue; - + if (fHelp || params.size() != 1) throw runtime_error( "dumpprivkey \"t-addr\"\n" @@ -399,7 +399,7 @@ UniValue dumpprivkey(const UniValue& params, bool fHelp) std::string strAddress = params[0].get_str(); CTxDestination dest = DecodeDestination(strAddress); if (!IsValidDestination(dest)) { - throw JSONRPCError(RPC_INVALID_ADDRESS_OR_KEY, "Invalid Zcash address"); + throw JSONRPCError(RPC_INVALID_ADDRESS_OR_KEY, "Invalid ZClassic address"); } const CKeyID *keyID = boost::get(&dest); if (!keyID) { @@ -418,13 +418,13 @@ UniValue z_exportwallet(const UniValue& params, bool fHelp) { if (!EnsureWalletIsAvailable(fHelp)) return NullUniValue; - + if (fHelp || params.size() != 1) throw runtime_error( "z_exportwallet \"filename\"\n" "\nExports all wallet keys, for taddr and zaddr, in a human-readable format. Overwriting an existing file is not permitted.\n" "\nArguments:\n" - "1. \"filename\" (string, required) The filename, saved in folder set by zcashd -exportdir option\n" + "1. \"filename\" (string, required) The filename, saved in folder set by zclassicd -exportdir option\n" "\nResult:\n" "\"path\" (string) The full path of the destination file\n" "\nExamples:\n" @@ -445,7 +445,7 @@ UniValue dumpwallet(const UniValue& params, bool fHelp) "dumpwallet \"filename\"\n" "\nDumps taddr wallet keys in a human-readable format. Overwriting an existing file is not permitted.\n" "\nArguments:\n" - "1. \"filename\" (string, required) The filename, saved in folder set by zcashd -exportdir option\n" + "1. \"filename\" (string, required) The filename, saved in folder set by zclassicd -exportdir option\n" "\nResult:\n" "\"path\" (string) The full path of the destination file\n" "\nExamples:\n" @@ -469,7 +469,7 @@ UniValue dumpwallet_impl(const UniValue& params, bool fHelp, bool fDumpZKeys) throw JSONRPCError(RPC_INTERNAL_ERROR, e.what()); } if (exportdir.empty()) { - throw JSONRPCError(RPC_WALLET_ERROR, "Cannot export wallet until the zcashd -exportdir option has been set"); + throw JSONRPCError(RPC_WALLET_ERROR, "Cannot export wallet until the zclassicd -exportdir option has been set"); } std::string unclean = params[0].get_str(); std::string clean = SanitizeFilename(unclean); @@ -501,7 +501,7 @@ UniValue dumpwallet_impl(const UniValue& params, bool fHelp, bool fDumpZKeys) std::sort(vKeyBirth.begin(), vKeyBirth.end()); // produce output - file << strprintf("# Wallet dump created by Zcash %s (%s)\n", CLIENT_BUILD, CLIENT_DATE); + file << strprintf("# Wallet dump created by ZClassic %s (%s)\n", CLIENT_BUILD, CLIENT_DATE); file << strprintf("# * Created on %s\n", EncodeDumpTime(GetTime())); file << strprintf("# * Best block at time of backup was %i (%s),\n", chainActive.Height(), chainActive.Tip()->GetBlockHash().ToString()); file << strprintf("# mined on %s\n", EncodeDumpTime(chainActive.Tip()->GetBlockTime())); @@ -651,10 +651,10 @@ UniValue z_importkey(const UniValue& params, bool fHelp) if (addResult == KeyNotAdded) { throw JSONRPCError(RPC_WALLET_ERROR, "Error adding spending key to wallet"); } - + // whenever a key is imported, we need to scan the whole chain pwalletMain->nTimeFirstKey = 1; // 0 would be considered 'no value' - + // We want to scan for transactions and notes if (fRescan) { pwalletMain->ScanForWalletTransactions(chainActive[nRescanHeight], true); diff --git a/src/wallet/rpcwallet.cpp b/src/wallet/rpcwallet.cpp index f593f942ee5..c336081ba44 100644 --- a/src/wallet/rpcwallet.cpp +++ b/src/wallet/rpcwallet.cpp @@ -123,11 +123,11 @@ UniValue getnewaddress(const UniValue& params, bool fHelp) if (fHelp || params.size() > 1) throw runtime_error( "getnewaddress ( \"account\" )\n" - "\nReturns a new Zcash address for receiving payments.\n" + "\nReturns a new ZClassic address for receiving payments.\n" "\nArguments:\n" "1. \"account\" (string, optional) DEPRECATED. If provided, it MUST be set to the empty string \"\" to represent the default account. Passing any other string will result in an error.\n" "\nResult:\n" - "\"zcashaddress\" (string) The new Zcash address\n" + "\"zclassicaddress\" (string) The new ZClassic address\n" "\nExamples:\n" + HelpExampleCli("getnewaddress", "") + HelpExampleRpc("getnewaddress", "") @@ -200,11 +200,11 @@ UniValue getaccountaddress(const UniValue& params, bool fHelp) if (fHelp || params.size() != 1) throw runtime_error( "getaccountaddress \"account\"\n" - "\nDEPRECATED. Returns the current Zcash address for receiving payments to this account.\n" + "\nDEPRECATED. Returns the current ZClassic address for receiving payments to this account.\n" "\nArguments:\n" "1. \"account\" (string, required) MUST be set to the empty string \"\" to represent the default account. Passing any other string will result in an error.\n" "\nResult:\n" - "\"zcashaddress\" (string) The account Zcash address\n" + "\"zclassicaddress\" (string) The account ZClassic address\n" "\nExamples:\n" + HelpExampleCli("getaccountaddress", "") + HelpExampleCli("getaccountaddress", "\"\"") @@ -232,7 +232,7 @@ UniValue getrawchangeaddress(const UniValue& params, bool fHelp) if (fHelp || params.size() > 1) throw runtime_error( "getrawchangeaddress\n" - "\nReturns a new Zcash address, for receiving change.\n" + "\nReturns a new ZClassic address, for receiving change.\n" "This is for use with raw transactions, NOT normal use.\n" "\nResult:\n" "\"address\" (string) The address\n" @@ -266,10 +266,10 @@ UniValue setaccount(const UniValue& params, bool fHelp) if (fHelp || params.size() < 1 || params.size() > 2) throw runtime_error( - "setaccount \"zcashaddress\" \"account\"\n" + "setaccount \"zclassicaddress\" \"account\"\n" "\nDEPRECATED. Sets the account associated with the given address.\n" "\nArguments:\n" - "1. \"zcashaddress\" (string, required) The Zcash address to be associated with an account.\n" + "1. \"zclassicaddress\" (string, required) The ZClassic address to be associated with an account.\n" "2. \"account\" (string, required) MUST be set to the empty string \"\" to represent the default account. Passing any other string will result in an error.\n" "\nExamples:\n" + HelpExampleCli("setaccount", "\"t14oHp2v54vfmdgQ3v3SNuQga8JKHTNi2a1\" \"tabby\"") @@ -280,7 +280,7 @@ UniValue setaccount(const UniValue& params, bool fHelp) CTxDestination dest = DecodeDestination(params[0].get_str()); if (!IsValidDestination(dest)) { - throw JSONRPCError(RPC_INVALID_ADDRESS_OR_KEY, "Invalid Zcash address"); + throw JSONRPCError(RPC_INVALID_ADDRESS_OR_KEY, "Invalid ZClassic address"); } string strAccount; @@ -312,10 +312,10 @@ UniValue getaccount(const UniValue& params, bool fHelp) if (fHelp || params.size() != 1) throw runtime_error( - "getaccount \"zcashaddress\"\n" + "getaccount \"zclassicaddress\"\n" "\nDEPRECATED. Returns the account associated with the given address.\n" "\nArguments:\n" - "1. \"zcashaddress\" (string, required) The Zcash address for account lookup.\n" + "1. \"zclassicaddress\" (string, required) The ZClassic address for account lookup.\n" "\nResult:\n" "\"accountname\" (string) the account address\n" "\nExamples:\n" @@ -327,7 +327,7 @@ UniValue getaccount(const UniValue& params, bool fHelp) CTxDestination dest = DecodeDestination(params[0].get_str()); if (!IsValidDestination(dest)) { - throw JSONRPCError(RPC_INVALID_ADDRESS_OR_KEY, "Invalid Zcash address"); + throw JSONRPCError(RPC_INVALID_ADDRESS_OR_KEY, "Invalid ZClassic address"); } std::string strAccount; @@ -352,7 +352,7 @@ UniValue getaddressesbyaccount(const UniValue& params, bool fHelp) "1. \"account\" (string, required) MUST be set to the empty string \"\" to represent the default account. Passing any other string will result in an error.\n" "\nResult:\n" "[ (json array of string)\n" - " \"zcashaddress\" (string) a Zcash address associated with the given account\n" + " \"zclassicaddress\" (string) a ZClassic address associated with the given account\n" " ,...\n" "]\n" "\nExamples:\n" @@ -387,7 +387,7 @@ static void SendMoney(const CTxDestination &address, CAmount nValue, bool fSubtr if (nValue > curBalance) throw JSONRPCError(RPC_WALLET_INSUFFICIENT_FUNDS, "Insufficient funds"); - // Parse Zcash address + // Parse ZClassic address CScript scriptPubKey = GetScriptForDestination(address); // Create and send the transaction @@ -414,11 +414,11 @@ UniValue sendtoaddress(const UniValue& params, bool fHelp) if (fHelp || params.size() < 2 || params.size() > 5) throw runtime_error( - "sendtoaddress \"zcashaddress\" amount ( \"comment\" \"comment-to\" subtractfeefromamount )\n" + "sendtoaddress \"zclassicaddress\" amount ( \"comment\" \"comment-to\" subtractfeefromamount )\n" "\nSend an amount to a given address. The amount is a real and is rounded to the nearest 0.00000001\n" + HelpRequiringPassphrase() + "\nArguments:\n" - "1. \"zcashaddress\" (string, required) The Zcash address to send to.\n" + "1. \"zclassicaddress\" (string, required) The ZClassic address to send to.\n" "2. \"amount\" (numeric, required) The amount in " + CURRENCY_UNIT + " to send. eg 0.1\n" "3. \"comment\" (string, optional) A comment used to store what the transaction is for. \n" " This is not part of the transaction, just kept in your wallet.\n" @@ -426,7 +426,7 @@ UniValue sendtoaddress(const UniValue& params, bool fHelp) " to which you're sending the transaction. This is not part of the \n" " transaction, just kept in your wallet.\n" "5. subtractfeefromamount (boolean, optional, default=false) The fee will be deducted from the amount being sent.\n" - " The recipient will receive less Zcash than you enter in the amount field.\n" + " The recipient will receive less ZClassic than you enter in the amount field.\n" "\nResult:\n" "\"transactionid\" (string) The transaction id.\n" "\nExamples:\n" @@ -440,7 +440,7 @@ UniValue sendtoaddress(const UniValue& params, bool fHelp) CTxDestination dest = DecodeDestination(params[0].get_str()); if (!IsValidDestination(dest)) { - throw JSONRPCError(RPC_INVALID_ADDRESS_OR_KEY, "Invalid Zcash address"); + throw JSONRPCError(RPC_INVALID_ADDRESS_OR_KEY, "Invalid ZClassic address"); } // Amount @@ -481,7 +481,7 @@ UniValue listaddressgroupings(const UniValue& params, bool fHelp) "[\n" " [\n" " [\n" - " \"zcashaddress\", (string) The zcash address\n" + " \"zclassicaddress\", (string) The zclassic address\n" " amount, (numeric) The amount in " + CURRENCY_UNIT + "\n" " \"account\" (string, optional) The account (DEPRECATED)\n" " ]\n" @@ -583,10 +583,10 @@ UniValue getreceivedbyaddress(const UniValue& params, bool fHelp) if (fHelp || params.size() < 1 || params.size() > 2) throw runtime_error( - "getreceivedbyaddress \"zcashaddress\" ( minconf )\n" - "\nReturns the total amount received by the given Zcash address in transactions with at least minconf confirmations.\n" + "getreceivedbyaddress \"zclassicaddress\" ( minconf )\n" + "\nReturns the total amount received by the given ZClassic address in transactions with at least minconf confirmations.\n" "\nArguments:\n" - "1. \"zcashaddress\" (string, required) The Zcash address for transactions.\n" + "1. \"zclassicaddress\" (string, required) The ZClassic address for transactions.\n" "2. minconf (numeric, optional, default=1) Only include transactions confirmed at least this many times.\n" "\nResult:\n" "amount (numeric) The total amount in " + CURRENCY_UNIT + " received at this address.\n" @@ -606,7 +606,7 @@ UniValue getreceivedbyaddress(const UniValue& params, bool fHelp) // Bitcoin address CTxDestination dest = DecodeDestination(params[0].get_str()); if (!IsValidDestination(dest)) { - throw JSONRPCError(RPC_INVALID_ADDRESS_OR_KEY, "Invalid Zcash address"); + throw JSONRPCError(RPC_INVALID_ADDRESS_OR_KEY, "Invalid ZClassic address"); } CScript scriptPubKey = GetScriptForDestination(dest); if (!IsMine(*pwalletMain, scriptPubKey)) { @@ -893,13 +893,13 @@ UniValue sendfrom(const UniValue& params, bool fHelp) if (fHelp || params.size() < 3 || params.size() > 6) throw runtime_error( - "sendfrom \"fromaccount\" \"tozcashaddress\" amount ( minconf \"comment\" \"comment-to\" )\n" - "\nDEPRECATED (use sendtoaddress). Sent an amount from an account to a Zcash address.\n" + "sendfrom \"fromaccount\" \"tozclassicaddress\" amount ( minconf \"comment\" \"comment-to\" )\n" + "\nDEPRECATED (use sendtoaddress). Sent an amount from an account to a ZClassic address.\n" "The amount is a real and is rounded to the nearest 0.00000001." + HelpRequiringPassphrase() + "\n" "\nArguments:\n" "1. \"fromaccount\" (string, required) MUST be set to the empty string \"\" to represent the default account. Passing any other string will result in an error.\n" - "2. \"tozcashaddress\" (string, required) The Zcash address to send funds to.\n" + "2. \"tozclassicaddress\" (string, required) The ZClassic address to send funds to.\n" "3. amount (numeric, required) The amount in " + CURRENCY_UNIT + " (transaction fee is added on top).\n" "4. minconf (numeric, optional, default=1) Only use funds with at least this many confirmations.\n" "5. \"comment\" (string, optional) A comment used to store what the transaction is for. \n" @@ -923,7 +923,7 @@ UniValue sendfrom(const UniValue& params, bool fHelp) std::string strAccount = AccountFromValue(params[0]); CTxDestination dest = DecodeDestination(params[1].get_str()); if (!IsValidDestination(dest)) { - throw JSONRPCError(RPC_INVALID_ADDRESS_OR_KEY, "Invalid Zcash address"); + throw JSONRPCError(RPC_INVALID_ADDRESS_OR_KEY, "Invalid ZClassic address"); } CAmount nAmount = AmountFromValue(params[2]); if (nAmount <= 0) @@ -966,14 +966,14 @@ UniValue sendmany(const UniValue& params, bool fHelp) "1. \"fromaccount\" (string, required) MUST be set to the empty string \"\" to represent the default account. Passing any other string will result in an error.\n" "2. \"amounts\" (string, required) A json object with addresses and amounts\n" " {\n" - " \"address\":amount (numeric) The Zcash address is the key, the numeric amount in " + CURRENCY_UNIT + " is the value\n" + " \"address\":amount (numeric) The ZClassic address is the key, the numeric amount in " + CURRENCY_UNIT + " is the value\n" " ,...\n" " }\n" "3. minconf (numeric, optional, default=1) Only use the balance confirmed at least this many times.\n" "4. \"comment\" (string, optional) A comment\n" "5. subtractfeefromamount (string, optional) A json array with addresses.\n" " The fee will be equally deducted from the amount of each selected address.\n" - " Those recipients will receive less Zcash than you enter in their corresponding amount field.\n" + " Those recipients will receive less ZClassic than you enter in their corresponding amount field.\n" " If no addresses are specified here, the sender pays the fee.\n" " [\n" " \"address\" (string) Subtract fee from this address\n" @@ -1018,7 +1018,7 @@ UniValue sendmany(const UniValue& params, bool fHelp) for (const std::string& name_ : keys) { CTxDestination dest = DecodeDestination(name_); if (!IsValidDestination(dest)) { - throw JSONRPCError(RPC_INVALID_ADDRESS_OR_KEY, std::string("Invalid Zcash address: ") + name_); + throw JSONRPCError(RPC_INVALID_ADDRESS_OR_KEY, std::string("Invalid ZClassic address: ") + name_); } if (destinations.count(dest)) { @@ -1076,20 +1076,20 @@ UniValue addmultisigaddress(const UniValue& params, bool fHelp) { string msg = "addmultisigaddress nrequired [\"key\",...] ( \"account\" )\n" "\nAdd a nrequired-to-sign multisignature address to the wallet.\n" - "Each key is a Zcash address or hex-encoded public key.\n" + "Each key is a ZClassic address or hex-encoded public key.\n" "If 'account' is specified (DEPRECATED), assign address to that account.\n" "\nArguments:\n" "1. nrequired (numeric, required) The number of required signatures out of the n keys or addresses.\n" - "2. \"keysobject\" (string, required) A json array of Zcash addresses or hex-encoded public keys\n" + "2. \"keysobject\" (string, required) A json array of ZClassic addresses or hex-encoded public keys\n" " [\n" - " \"address\" (string) Zcash address or hex-encoded public key\n" + " \"address\" (string) ZClassic address or hex-encoded public key\n" " ...,\n" " ]\n" "3. \"account\" (string, optional) DEPRECATED. If provided, MUST be set to the empty string \"\" to represent the default account. Passing any other string will result in an error.\n" "\nResult:\n" - "\"zcashaddress\" (string) A Zcash address associated with the keys.\n" + "\"zclassicaddress\" (string) A ZClassic address associated with the keys.\n" "\nExamples:\n" "\nAdd a multisig address from 2 addresses\n" @@ -1434,7 +1434,7 @@ UniValue listtransactions(const UniValue& params, bool fHelp) " {\n" " \"account\":\"accountname\", (string) DEPRECATED. The account name associated with the transaction. \n" " It will be \"\" for the default account.\n" - " \"address\":\"zcashaddress\", (string) The Zcash address of the transaction. Not present for \n" + " \"address\":\"zclassicaddress\", (string) The ZClassic address of the transaction. Not present for \n" " move transactions (category = move).\n" " \"category\":\"send|receive|move\", (string) The transaction category. 'move' is a local (off blockchain)\n" " transaction between accounts, and not associated with an address,\n" @@ -1634,7 +1634,7 @@ UniValue listsinceblock(const UniValue& params, bool fHelp) "{\n" " \"transactions\": [\n" " \"account\":\"accountname\", (string) DEPRECATED. The account name associated with the transaction. Will be \"\" for the default account.\n" - " \"address\":\"zcashaddress\", (string) The Zcash address of the transaction. Not present for move transactions (category = move).\n" + " \"address\":\"zclassicaddress\", (string) The ZClassic address of the transaction. Not present for move transactions (category = move).\n" " \"category\":\"send|receive\", (string) The transaction category. 'send' has negative amounts, 'receive' has positive amounts.\n" " \"amount\": x.xxx, (numeric) The amount in " + CURRENCY_UNIT + ". This is negative for the 'send' category, and for the 'move' category for moves \n" " outbound. It is positive for the 'receive' category, and for the 'move' category for inbound funds.\n" @@ -1733,7 +1733,7 @@ UniValue gettransaction(const UniValue& params, bool fHelp) " \"details\" : [\n" " {\n" " \"account\" : \"accountname\", (string) DEPRECATED. The account name involved in the transaction, can be \"\" for the default account.\n" - " \"address\" : \"zcashaddress\", (string) The Zcash address involved in the transaction\n" + " \"address\" : \"zclassicaddress\", (string) The ZClassic address involved in the transaction\n" " \"category\" : \"send|receive\", (string) The category, either 'send' or 'receive'\n" " \"amount\" : x.xxx (numeric) The amount in " + CURRENCY_UNIT + "\n" " \"vout\" : n, (numeric) the vout value\n" @@ -1893,7 +1893,7 @@ UniValue walletpassphrase(const UniValue& params, bool fHelp) throw runtime_error( "walletpassphrase \"passphrase\" timeout\n" "\nStores the wallet decryption key in memory for 'timeout' seconds.\n" - "This is needed prior to performing transactions related to private keys such as sending Zcash\n" + "This is needed prior to performing transactions related to private keys such as sending ZClassic\n" "\nArguments:\n" "1. \"passphrase\" (string, required) The wallet passphrase\n" "2. timeout (numeric, required) The time to keep the decryption key in seconds.\n" @@ -2059,10 +2059,10 @@ UniValue encryptwallet(const UniValue& params, bool fHelp) "\nExamples:\n" "\nEncrypt you wallet\n" + HelpExampleCli("encryptwallet", "\"my pass phrase\"") + - "\nNow set the passphrase to use the wallet, such as for signing or sending Zcash\n" + "\nNow set the passphrase to use the wallet, such as for signing or sending ZClassic\n" + HelpExampleCli("walletpassphrase", "\"my pass phrase\"") + "\nNow we can so something like sign\n" - + HelpExampleCli("signmessage", "\"zcashaddress\" \"test message\"") + + + HelpExampleCli("signmessage", "\"zclassicaddress\" \"test message\"") + "\nNow lock the wallet again by removing the passphrase\n" + HelpExampleCli("walletlock", "") + "\nAs a json rpc call\n" @@ -2097,7 +2097,7 @@ UniValue encryptwallet(const UniValue& params, bool fHelp) // slack space in .dat files; that is bad if the old data is // unencrypted private keys. So: StartShutdown(); - return "wallet encrypted; Zcash server stopping, restart to run with encrypted wallet. The keypool has been flushed, you need to make a new backup."; + return "wallet encrypted; ZClassic server stopping, restart to run with encrypted wallet. The keypool has been flushed, you need to make a new backup."; } UniValue lockunspent(const UniValue& params, bool fHelp) @@ -2110,7 +2110,7 @@ UniValue lockunspent(const UniValue& params, bool fHelp) "lockunspent unlock [{\"txid\":\"txid\",\"vout\":n},...]\n" "\nUpdates list of temporarily unspendable outputs.\n" "Temporarily lock (unlock=false) or unlock (unlock=true) specified transaction outputs.\n" - "A locked transaction output will not be chosen by automatic coin selection, when spending Zcash.\n" + "A locked transaction output will not be chosen by automatic coin selection, when spending ZClassic.\n" "Locks are stored in memory only. Nodes start with zero locked outputs, and the locked output list\n" "is always cleared (by virtue of process exit) when a node stops or fails.\n" "Also see the listunspent call\n" @@ -2347,9 +2347,9 @@ UniValue listunspent(const UniValue& params, bool fHelp) "\nArguments:\n" "1. minconf (numeric, optional, default=1) The minimum confirmations to filter\n" "2. maxconf (numeric, optional, default=9999999) The maximum confirmations to filter\n" - "3. \"addresses\" (string) A json array of Zcash addresses to filter\n" + "3. \"addresses\" (string) A json array of ZClassic addresses to filter\n" " [\n" - " \"address\" (string) Zcash address\n" + " \"address\" (string) ZClassic address\n" " ,...\n" " ]\n" "\nResult\n" @@ -2358,7 +2358,7 @@ UniValue listunspent(const UniValue& params, bool fHelp) " \"txid\" : \"txid\", (string) the transaction id \n" " \"vout\" : n, (numeric) the vout value\n" " \"generated\" : true|false (boolean) true if txout is a coinbase transaction output\n" - " \"address\" : \"address\", (string) the Zcash address\n" + " \"address\" : \"address\", (string) the ZClassic address\n" " \"account\" : \"account\", (string) DEPRECATED. The associated account, or \"\" for the default account\n" " \"scriptPubKey\" : \"key\", (string) the script key\n" " \"amount\" : x.xxx, (numeric) the transaction amount in " + CURRENCY_UNIT + "\n" @@ -2392,7 +2392,7 @@ UniValue listunspent(const UniValue& params, bool fHelp) const UniValue& input = inputs[idx]; CTxDestination dest = DecodeDestination(input.get_str()); if (!IsValidDestination(dest)) { - throw JSONRPCError(RPC_INVALID_ADDRESS_OR_KEY, std::string("Invalid Zcash address: ") + input.get_str()); + throw JSONRPCError(RPC_INVALID_ADDRESS_OR_KEY, std::string("Invalid ZClassic address: ") + input.get_str()); } if (!destinations.insert(dest).second) { throw JSONRPCError(RPC_INVALID_PARAMETER, std::string("Invalid parameter, duplicated address: ") + input.get_str()); @@ -2554,11 +2554,11 @@ UniValue z_listunspent(const UniValue& params, bool fHelp) // User did not provide zaddrs, so use default i.e. all addresses std::set sproutzaddrs = {}; pwalletMain->GetSproutPaymentAddresses(sproutzaddrs); - + // Sapling support std::set saplingzaddrs = {}; pwalletMain->GetSaplingPaymentAddresses(saplingzaddrs); - + zaddrs.insert(sproutzaddrs.begin(), sproutzaddrs.end()); zaddrs.insert(saplingzaddrs.begin(), saplingzaddrs.end()); } @@ -2570,7 +2570,7 @@ UniValue z_listunspent(const UniValue& params, bool fHelp) std::vector saplingEntries; pwalletMain->GetFilteredNotes(sproutEntries, saplingEntries, zaddrs, nMinDepth, nMaxDepth, true, !fIncludeWatchonly, false); std::set> nullifierSet = pwalletMain->GetNullifiersForAddresses(zaddrs); - + for (auto & entry : sproutEntries) { UniValue obj(UniValue::VOBJ); obj.push_back(Pair("txid", entry.jsop.hash.ToString())); @@ -2588,7 +2588,7 @@ UniValue z_listunspent(const UniValue& params, bool fHelp) } results.push_back(obj); } - + for (auto & entry : saplingEntries) { UniValue obj(UniValue::VOBJ); obj.push_back(Pair("txid", entry.op.hash.ToString())); @@ -3157,7 +3157,7 @@ UniValue z_getnewaddress(const UniValue& params, bool fHelp) "1. \"type\" (string, optional, default=\"" + defaultType + "\") The type of address. One of [\"" + ADDR_TYPE_SPROUT + "\", \"" + ADDR_TYPE_SAPLING + "\"].\n" "\nResult:\n" - "\"zcashaddress\" (string) The new shielded address.\n" + "\"zclassicaddress\" (string) The new shielded address.\n" "\nExamples:\n" + HelpExampleCli("z_getnewaddress", "") + HelpExampleCli("z_getnewaddress", ADDR_TYPE_SAPLING) @@ -3889,7 +3889,7 @@ UniValue z_sendmany(const UniValue& params, bool fHelp) CMutableTransaction contextualTx = CreateNewContextualCMutableTransaction(Params().GetConsensus(), nextBlockHeight); bool isShielded = !fromTaddr || zaddrRecipients.size() > 0; if (contextualTx.nVersion == 1 && isShielded) { - contextualTx.nVersion = 2; // Tx format should support vjoinsplits + contextualTx.nVersion = 2; // Tx format should support vjoinsplits } // Create operation and add to global queue @@ -4103,7 +4103,7 @@ UniValue z_shieldcoinbase(const UniValue& params, bool fHelp) CMutableTransaction contextualTx = CreateNewContextualCMutableTransaction( Params().GetConsensus(), nextBlockHeight); if (contextualTx.nVersion == 1) { - contextualTx.nVersion = 2; // Tx format should support vjoinsplits + contextualTx.nVersion = 2; // Tx format should support vjoinsplits } // Create operation and add to global queue @@ -4196,7 +4196,7 @@ UniValue z_mergetoaddress(const UniValue& params, bool fHelp) ); if (!fEnableMergeToAddress) { - throw JSONRPCError(RPC_WALLET_ERROR, "Error: z_mergetoaddress is disabled. Run './zcash-cli help z_mergetoaddress' for instructions on how to enable this feature."); + throw JSONRPCError(RPC_WALLET_ERROR, "Error: z_mergetoaddress is disabled. Run './zclassic-cli help z_mergetoaddress' for instructions on how to enable this feature."); } LOCK2(cs_main, pwalletMain->cs_wallet); From 697aba1cb397e725a38c23ef8e3a819014bbae94 Mon Sep 17 00:00:00 2001 From: skellers Date: Thu, 7 Feb 2019 20:15:40 +0000 Subject: [PATCH 2/8] remove founders reward --- src/Makefile.gtest.include | 3 +-- src/main.cpp | 26 ++------------------------ src/metrics.cpp | 4 +--- src/miner.cpp | 10 ---------- src/rpc/mining.cpp | 4 ---- 5 files changed, 4 insertions(+), 43 deletions(-) diff --git a/src/Makefile.gtest.include b/src/Makefile.gtest.include index 6b52eff36b2..16b1202e571 100644 --- a/src/Makefile.gtest.include +++ b/src/Makefile.gtest.include @@ -9,8 +9,7 @@ zcash_gtest_SOURCES = \ gtest/utils.cpp \ gtest/test_checktransaction.cpp \ gtest/json_test_vectors.cpp \ - gtest/json_test_vectors.h \ - gtest/test_foundersreward.cpp + gtest/json_test_vectors.h # These tests are order-dependent, because they # depend on global state (see #1539) if ENABLE_WALLET diff --git a/src/main.cpp b/src/main.cpp index e1fac0a88a0..6f9f71dce6d 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -877,7 +877,7 @@ unsigned int GetP2SHSigOpCount(const CTransaction& tx, const CCoinsViewCache& in /** * Check a transaction contextually against a set of consensus rules valid at a given block height. - * + * * Notes: * 1. AcceptToMemoryPool calls CheckTransaction and this function. * 2. ProcessNewBlock calls AcceptBlock, which calls CheckBlock (which calls CheckTransaction) @@ -955,7 +955,7 @@ bool ContextualCheckTransaction( return state.DoS(dosLevel, error("ContextualCheckTransaction: overwinter is active"), REJECT_INVALID, "tx-overwinter-active"); } - + // Check that all transactions are unexpired if (IsExpiredTx(tx, nHeight)) { // Don't increase banscore if the transaction only just expired @@ -3614,28 +3614,6 @@ bool ContextualCheckBlock(const CBlock& block, CValidationState& state, CBlockIn } } - // Coinbase transaction must include an output sending 20% of - // the block reward to a founders reward script, until the last founders - // reward block is reached, with exception of the genesis block. - // The last founders reward block is defined as the block just before the - // first subsidy halving block, which occurs at halving_interval + slow_start_shift - if ((nHeight > 0) && (nHeight <= consensusParams.GetLastFoundersRewardBlockHeight())) { - bool found = false; - - BOOST_FOREACH(const CTxOut& output, block.vtx[0].vout) { - if (output.scriptPubKey == Params().GetFoundersRewardScriptAtHeight(nHeight)) { - if (output.nValue == (GetBlockSubsidy(nHeight, consensusParams) / 5)) { - found = true; - break; - } - } - } - - if (!found) { - return state.DoS(100, error("%s: founders reward missing", __func__), REJECT_INVALID, "cb-no-founders-reward"); - } - } - return true; } diff --git a/src/metrics.cpp b/src/metrics.cpp index 680b74bb53e..14521f4c34b 100644 --- a/src/metrics.cpp +++ b/src/metrics.cpp @@ -331,9 +331,7 @@ int printMetrics(size_t cols, bool mining) chainActive.Contains(mapBlockIndex[hash])) { int height = mapBlockIndex[hash]->nHeight; CAmount subsidy = GetBlockSubsidy(height, consensusParams); - if ((height > 0) && (height <= consensusParams.GetLastFoundersRewardBlockHeight())) { - subsidy -= subsidy/5; - } + if (std::max(0, COINBASE_MATURITY - (tipHeight - height)) > 0) { immature += subsidy; } else { diff --git a/src/miner.cpp b/src/miner.cpp index 2143c96366d..c9eae6d2b71 100644 --- a/src/miner.cpp +++ b/src/miner.cpp @@ -360,16 +360,6 @@ CBlockTemplate* CreateNewBlock(const CScript& scriptPubKeyIn) // Set to 0 so expiry height does not apply to coinbase txs txNew.nExpiryHeight = 0; - if ((nHeight > 0) && (nHeight <= chainparams.GetConsensus().GetLastFoundersRewardBlockHeight())) { - // Founders reward is 20% of the block subsidy - auto vFoundersReward = txNew.vout[0].nValue / 5; - // Take some reward away from us - txNew.vout[0].nValue -= vFoundersReward; - - // And give it to the founders - txNew.vout.push_back(CTxOut(vFoundersReward, chainparams.GetFoundersRewardScriptAtHeight(nHeight))); - } - // Add fees txNew.vout[0].nValue += nFees; txNew.vin[0].scriptSig = CScript() << nHeight << OP_0; diff --git a/src/rpc/mining.cpp b/src/rpc/mining.cpp index a6467d5b28d..b8a89ba597c 100644 --- a/src/rpc/mining.cpp +++ b/src/rpc/mining.cpp @@ -901,10 +901,6 @@ UniValue getblocksubsidy(const UniValue& params, bool fHelp) CAmount nReward = GetBlockSubsidy(nHeight, Params().GetConsensus()); CAmount nFoundersReward = 0; - if ((nHeight > 0) && (nHeight <= Params().GetConsensus().GetLastFoundersRewardBlockHeight())) { - nFoundersReward = nReward/5; - nReward -= nFoundersReward; - } UniValue result(UniValue::VOBJ); result.push_back(Pair("miner", ValueFromAmount(nReward))); result.push_back(Pair("founders", ValueFromAmount(nFoundersReward))); From f774db6bb24fe6c435e475cd94d1142d8d4530de Mon Sep 17 00:00:00 2001 From: skellers Date: Fri, 8 Feb 2019 18:55:11 +0000 Subject: [PATCH 3/8] update readme --- .gitignore | 2 ++ README.md | 18 +++++++++--------- 2 files changed, 11 insertions(+), 9 deletions(-) diff --git a/.gitignore b/.gitignore index 5992c9e6bfd..86cbdba7d92 100644 --- a/.gitignore +++ b/.gitignore @@ -1,6 +1,8 @@ *.tar.gz *.deb *.exe +.nfs* + src/bitcoin src/zcashd src/zcash-cli diff --git a/README.md b/README.md index c065ded7a2b..ced19f1a5bd 100644 --- a/README.md +++ b/README.md @@ -1,18 +1,18 @@ -Zcash 2.0.3-rc1 +ZClassic 2.0.3-rc1 =========== -What is Zcash? +What is ZClassic? -------------- -[Zcash](https://z.cash/) is an implementation of the "Zerocash" protocol. +[ZClassic](https://zcl.community/) is an implementation of the "Zerocash" protocol. Based on Bitcoin's code, it intends to offer a far higher standard of privacy through a sophisticated zero-knowledge proving scheme that preserves confidentiality of transaction metadata. Technical details are available in our [Protocol Specification](https://github.com/zcash/zips/raw/master/protocol/protocol.pdf). -This software is the Zcash client. It downloads and stores the entire history -of Zcash transactions; depending on the speed of your computer and network +This software is the ZClassic client. It downloads and stores the entire history +of ZClassic transactions; depending on the speed of your computer and network connection, the synchronization process could take a day or more once the blockchain has reached a significant size. @@ -25,7 +25,7 @@ blockchain has reached a significant size. See important security warnings on the [Security Information page](https://z.cash/support/security/). -**Zcash is experimental and a work-in-progress.** Use at your own risk. +**ZClassic is experimental and a work-in-progress.** Use at your own risk. #### :ledger: Deprecation Policy @@ -36,7 +36,7 @@ height. ## Getting Started -Please see our [user guide](https://zcash.readthedocs.io/en/latest/rtd_pages/rtd_docs/user_guide.html) for joining the main Zcash network. +Please see our [user guide](https://zcash.readthedocs.io/en/latest/rtd_pages/rtd_docs/user_guide.html) for joining the main ZClassic network. ### Need Help? @@ -45,12 +45,12 @@ Please see our [user guide](https://zcash.readthedocs.io/en/latest/rtd_pages/rtd * :incoming_envelope: Ask for help on the [Zcash](https://forum.z.cash/) forum. * :mag: Chat with our support community on [Rocket.Chat](https://chat.zcashcommunity.com/channel/user-support) -Participation in the Zcash project is subject to a +Participation in the ZClassic project is subject to a [Code of Conduct](code_of_conduct.md). ### Building -Build Zcash along with most dependencies from source by running: +Build ZClassic along with most dependencies from source by running: ``` ./zcutil/build.sh -j$(nproc) From 335a389a3b45bc738940fe271013c008f05e4ed1 Mon Sep 17 00:00:00 2001 From: skellers Date: Fri, 8 Feb 2019 21:13:52 +0000 Subject: [PATCH 4/8] default rpc port --- src/chainparamsbase.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/chainparamsbase.cpp b/src/chainparamsbase.cpp index 31f15d15d69..e1de176d74d 100644 --- a/src/chainparamsbase.cpp +++ b/src/chainparamsbase.cpp @@ -17,7 +17,7 @@ class CBaseMainParams : public CBaseChainParams public: CBaseMainParams() { - nRPCPort = 8232; + nRPCPort = 8023; } }; static CBaseMainParams mainParams; @@ -30,7 +30,7 @@ class CBaseTestNetParams : public CBaseChainParams public: CBaseTestNetParams() { - nRPCPort = 18232; + nRPCPort = 18023; strDataDir = "testnet3"; } }; @@ -44,7 +44,7 @@ class CBaseRegTestParams : public CBaseChainParams public: CBaseRegTestParams() { - nRPCPort = 18232; + nRPCPort = 18023; strDataDir = "regtest"; } }; From eaafcf4e13b0f94069de74831e0b9a5b729bd0ba Mon Sep 17 00:00:00 2001 From: skellers Date: Sat, 9 Feb 2019 17:00:39 +0000 Subject: [PATCH 5/8] rpc port and checkpoint --- contrib/bitrpc/bitrpc.py | 4 ++-- src/bitcoin-cli.cpp | 2 +- src/chainparams.cpp | 15 ++++++++------- src/init.cpp | 2 +- src/test/main_tests.cpp | 2 +- src/test/miner_tests.cpp | 5 +++-- 6 files changed, 16 insertions(+), 14 deletions(-) diff --git a/contrib/bitrpc/bitrpc.py b/contrib/bitrpc/bitrpc.py index 1c3d40f229b..bbe252dbf70 100644 --- a/contrib/bitrpc/bitrpc.py +++ b/contrib/bitrpc/bitrpc.py @@ -11,9 +11,9 @@ if rpcpass == "": - access = ServiceProxy("http://127.0.0.1:8232") + access = ServiceProxy("http://127.0.0.1:8023") else: - access = ServiceProxy("http://"+rpcuser+":"+rpcpass+"@127.0.0.1:8232") + access = ServiceProxy("http://"+rpcuser+":"+rpcpass+"@127.0.0.1:8023") cmd = sys.argv[1].lower() if cmd == "backupwallet": diff --git a/src/bitcoin-cli.cpp b/src/bitcoin-cli.cpp index 87fae044957..0c39a13119f 100644 --- a/src/bitcoin-cli.cpp +++ b/src/bitcoin-cli.cpp @@ -33,7 +33,7 @@ std::string HelpMessageCli() strUsage += HelpMessageOpt("-regtest", _("Enter regression test mode, which uses a special chain in which blocks can be " "solved instantly. This is intended for regression testing tools and app development.")); strUsage += HelpMessageOpt("-rpcconnect=", strprintf(_("Send commands to node running on (default: %s)"), "127.0.0.1")); - strUsage += HelpMessageOpt("-rpcport=", strprintf(_("Connect to JSON-RPC on (default: %u or testnet: %u)"), 8232, 18232)); + strUsage += HelpMessageOpt("-rpcport=", strprintf(_("Connect to JSON-RPC on (default: %u or testnet: %u)"), 8023, 18023)); strUsage += HelpMessageOpt("-rpcwait", _("Wait for RPC server to start")); strUsage += HelpMessageOpt("-rpcuser=", _("Username for JSON-RPC connections")); strUsage += HelpMessageOpt("-rpcpassword=", _("Password for JSON-RPC connections")); diff --git a/src/chainparams.cpp b/src/chainparams.cpp index 9df77ea4bcb..b578b043e85 100644 --- a/src/chainparams.cpp +++ b/src/chainparams.cpp @@ -191,11 +191,12 @@ class CMainParams : public CChainParams { boost::assign::map_list_of ( 0, consensus.hashGenesisBlock) ( 30000, uint256S("0x000000005c2ad200c3c7c8e627f67b306659efca1268c9bb014335fdadc0c392")) - ( 160000, uint256S("0x000000065093005a1a46ee95d6d66c2b07008220ca64dd3b3a93bbd1945480c0")), - 1502742046, // * UNIX timestamp of last checkpoint block - 392489, // * total number of transactions between genesis and last checkpoint + ( 160000, uint256S("0x000000065093005a1a46ee95d6d66c2b07008220ca64dd3b3a93bbd1945480c0")) + ( 468200, uint256S("0x000000009bd5548c851c2b237894d6807a53bf1e2808402545e27a995ae4f3c3")), + 1549728057, // * UNIX timestamp of last checkpoint block + 1372737, // * total number of transactions between genesis and last checkpoint // (the tx=... number in the SetBestChain debug.log lines) - 1413 // * estimated number of transactions per day after checkpoint + 1689 // * estimated number of transactions per day after checkpoint // total number of tx / (checkpoint block height / (24 * 24)) }; @@ -291,12 +292,12 @@ class CTestNetParams : public CChainParams { consensus.vUpgrades[Consensus::UPGRADE_TESTDUMMY].nActivationHeight = Consensus::NetworkUpgrade::NO_ACTIVATION_HEIGHT; consensus.vUpgrades[Consensus::UPGRADE_OVERWINTER].nProtocolVersion = 170003; - consensus.vUpgrades[Consensus::UPGRADE_OVERWINTER].nActivationHeight = 207500; + consensus.vUpgrades[Consensus::UPGRADE_OVERWINTER].nActivationHeight = 20; consensus.vUpgrades[Consensus::UPGRADE_SAPLING].nProtocolVersion = 170007; - consensus.vUpgrades[Consensus::UPGRADE_SAPLING].nActivationHeight = 280000; + consensus.vUpgrades[Consensus::UPGRADE_SAPLING].nActivationHeight = 20; // The best chain should have at least this much work. - consensus.nMinimumChainWork = uint256S("0x00000000000000000000000000000000000000000000000000000001d0c4d9cd"); + consensus.nMinimumChainWork = uint256S("0x0000000000000000000000000000000000000000000000000000000000000000"); pchMessageStart[0] = 0xfa; pchMessageStart[1] = 0x1a; diff --git a/src/init.cpp b/src/init.cpp index ca8f48a825c..1408fa4ccd7 100644 --- a/src/init.cpp +++ b/src/init.cpp @@ -520,7 +520,7 @@ std::string HelpMessage(HelpMessageMode mode) strUsage += HelpMessageOpt("-rpcbind=", _("Bind to given address to listen for JSON-RPC connections. Use [host]:port notation for IPv6. This option can be specified multiple times (default: bind to all interfaces)")); strUsage += HelpMessageOpt("-rpcuser=", _("Username for JSON-RPC connections")); strUsage += HelpMessageOpt("-rpcpassword=", _("Password for JSON-RPC connections")); - strUsage += HelpMessageOpt("-rpcport=", strprintf(_("Listen for JSON-RPC connections on (default: %u or testnet: %u)"), 8232, 18232)); + strUsage += HelpMessageOpt("-rpcport=", strprintf(_("Listen for JSON-RPC connections on (default: %u or testnet: %u)"), 8023, 18023)); strUsage += HelpMessageOpt("-rpcallowip=", _("Allow JSON-RPC connections from specified source. Valid for are a single IP (e.g. 1.2.3.4), a network/netmask (e.g. 1.2.3.4/255.255.255.0) or a network/CIDR (e.g. 1.2.3.4/24). This option can be specified multiple times")); strUsage += HelpMessageOpt("-rpcthreads=", strprintf(_("Set the number of threads to service RPC calls (default: %d)"), DEFAULT_HTTP_THREADS)); if (showDebug) { diff --git a/src/test/main_tests.cpp b/src/test/main_tests.cpp index ec02352e8b5..5707a1a7450 100644 --- a/src/test/main_tests.cpp +++ b/src/test/main_tests.cpp @@ -59,7 +59,7 @@ BOOST_AUTO_TEST_CASE(subsidy_limit_test) nSum += nSubsidy; BOOST_CHECK(MoneyRange(nSum)); } - BOOST_CHECK_EQUAL(nSum, 12500000000000ULL); + BOOST_CHECK_EQUAL(nSum, 1250000000); // Remainder of first period for (int nHeight = consensusParams.nSubsidySlowStartInterval; nHeight < consensusParams.nSubsidyHalvingInterval + consensusParams.SubsidySlowStartShift(); nHeight ++) { CAmount nSubsidy = GetBlockSubsidy(nHeight, consensusParams); diff --git a/src/test/miner_tests.cpp b/src/test/miner_tests.cpp index 3f6a0af77ea..e491f8e5833 100644 --- a/src/test/miner_tests.cpp +++ b/src/test/miner_tests.cpp @@ -135,6 +135,7 @@ struct { {"00000000000000000000000000000000000000000000000000000000000022de", "007f388bed6b91756ea3e0866716ef6e9485fae6160195c7cda5c1e43f96ee359e105bcf4e8c293690420939124f04a0196363910421187811575929db40500b0bfdd1e8964aa334b801e3339a336d585a30852f1dc294a2d3d36f9ecc747458f3d41b4572415496df2a9fb1f882156cdabf9f65e681f38019865d6d47482277e24c9b8973eb34a41254faae4c5e2caa9dde5925ec118f3d8fa767ae00f434645957154367afe72000c59c79182c8faddd24424b9ebbb09ccd651b00540c96b9c7eec648a28a1d72c2e575d0f2250078511a011598db8e0788edf0ddc15ae24b62f63d6f93f71a2743a3c43ece55471a9802a76f31561a6f365c3647029bfa736395883afc0632bc25d4a8661b25d5aa0310f3c3fd3a183e75d359d6de3e5910b5dfbb74b7660af906917dc42b12e3e484aae1dbd20eaee037ef301572b7fc24d85b4aff9c82b27dcd421cee1639230d0188fec59f0dd4c0ced69c1ad07abd23692b1bd30735af942df597dcf6f403a36371bc416cf3e29a58570f586b05c357dc49515689788ad9581b8887dd913a41dc35e1ac9c9f9f4ea534eb6b36cc8af0299b6d3905750425da0366bdc59a7824477d7946b6f35c4ec90b8e61790fa74a4fa92396ea856661027828d40abb11dbe36bba516fe8ec8913106677285a4790d8034d1d1bf9fd87990889ddffc369b954a3d1c172be7e1812226c2b100cbe82c42bf4423456b6cb2bac3b4828135cb54f7a933a01f7f4a2057ad92136ba8e19fec313b412d43c089a71f06fd1625329b78d49ac92c59e4080932ddb1645910fd874dfb1f358e214231f62041acc41fd2c4e7b7127b3042459e1457f6b307fce9825aa4d2b942277f52665f2a77dd107b4f16cb3280f20c7551ff6cd855f97a6144131f69bab5648fb4b81261eefbf629094e8bcc4e36077f46d51a647da51fc01dca9a9ac12e2f7e2e2b1c9229dae099e95370177143d3b38ab661f19758494a01b32f0c27155b45a872a867dc50f9d76473695e9e2c4f9357f5ba6bb6c455d985f4e2c21486fde6576c6a8ceda6e010a7dc2b504130f429ac33376781ee4af5bbe8d768005bc4cb5092b15c4f296a8bd8c54a298eecd790a5161755a8605cc46bf890b8ff93d508501842b78c7261e5deeb1096891c528a300e57bf2f0aa9e8af2623cdf16bba20427704120484b6af8be26e4983d2685c783ce85d0174f84598719c6beefcc3603a94d4aa62750725df50671d7f9903ec255f779643ebd2fd8122fae3319e61928dcdaa44880d6a483140de63d2d7d7dc9dd449e0ee00d908e0f2164fc054198641e8fb0d74279c9b4117884b9335028a9f50c7223d3c03675ecf73329e52603f77f20cffba99356e51a365b75825f7db56d77542784f3c2663c493a2e564d73f753e9d6ebb0c2f2027a2330a7117c67a20507474fc47282a02cb572de17bbc7a335959316f74a05e3687cfb5227bc5b1b7f084f50902760e77740d420df9a495521c09b911e5f199a8343918b8386fc74f22552a76524a22c8c70ff06084e7fefe9b3ab98e004fadf35eb5f60483f287851712d90ebdd6b512877170d3b7fb34f16813917ae3b5ed54ede6081bdd7cc646fb336658121fd8fbafc52959b48d13375dfa4ce8616c157533a05ee1dc1120f215c348b54357d68adb4da7f5f48d55c005b3e7a23d05746e44d968f7601d4dbdff702861030d6e3a4140e6e1a29978be541f713f8e2cc9aa1ac32fecc941ee4aa4c41bc7f91ea5328ff87cbf35a8de17d1d3d1ad6d4384b0df52d10b3984d62e1678e86dd150ee425490bc727ee7107fda0f5d2433ab1c5d407be9d123fad5c201355601d926d3923787be86a4aa5be0b8d5750171ad658f8e97798b5dcaed46345a9af70c441"}, }; +#if 0 // NOTE: These tests rely on CreateNewBlock doing its own self-validation! BOOST_AUTO_TEST_CASE(CreateNewBlock_validity) { @@ -241,7 +242,7 @@ BOOST_AUTO_TEST_CASE(CreateNewBlock_validity) pblock->nSolution = soln; CValidationState state; - + if (ProcessNewBlock(state, NULL, pblock, true, NULL) && state.IsValid()) { goto foundit; } @@ -452,5 +453,5 @@ BOOST_AUTO_TEST_CASE(CreateNewBlock_validity) fCheckpointsEnabled = true; fCoinbaseEnforcedProtectionEnabled = true; } - +#endif BOOST_AUTO_TEST_SUITE_END() From f363bcc8c7daf266539b6c7110c71c6d7da74da7 Mon Sep 17 00:00:00 2001 From: skellers Date: Sat, 9 Feb 2019 18:01:08 +0000 Subject: [PATCH 6/8] mainnet minimum chain work --- src/chainparams.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/chainparams.cpp b/src/chainparams.cpp index b578b043e85..3865db379fd 100644 --- a/src/chainparams.cpp +++ b/src/chainparams.cpp @@ -108,7 +108,7 @@ class CMainParams : public CChainParams { consensus.vUpgrades[Consensus::UPGRADE_SAPLING].nActivationHeight = 500000; // The best chain should have at least this much work. - consensus.nMinimumChainWork = uint256S("0x00000000000000000000000000000000000000000000000000281b32ff3198a1"); + consensus.nMinimumChainWork = uint256S("0x000000000000000000000000000000000000000000000000000721bfb84aedeb"); /** * The message start string should be awesome! ⓩ❤ From 0cdd0db7cc2414c740f4e6b08643f22e518d0bb3 Mon Sep 17 00:00:00 2001 From: skellers Date: Sat, 9 Feb 2019 19:36:46 +0000 Subject: [PATCH 7/8] sapling activation height and dns seeders --- src/chainparams.cpp | 26 ++++++-------------------- 1 file changed, 6 insertions(+), 20 deletions(-) diff --git a/src/chainparams.cpp b/src/chainparams.cpp index 3865db379fd..abe255894c6 100644 --- a/src/chainparams.cpp +++ b/src/chainparams.cpp @@ -103,9 +103,9 @@ class CMainParams : public CChainParams { consensus.vUpgrades[Consensus::UPGRADE_TESTDUMMY].nActivationHeight = Consensus::NetworkUpgrade::NO_ACTIVATION_HEIGHT; consensus.vUpgrades[Consensus::UPGRADE_OVERWINTER].nProtocolVersion = 170005; - consensus.vUpgrades[Consensus::UPGRADE_OVERWINTER].nActivationHeight = 500000; + consensus.vUpgrades[Consensus::UPGRADE_OVERWINTER].nActivationHeight = 476969; consensus.vUpgrades[Consensus::UPGRADE_SAPLING].nProtocolVersion = 170007; - consensus.vUpgrades[Consensus::UPGRADE_SAPLING].nActivationHeight = 500000; + consensus.vUpgrades[Consensus::UPGRADE_SAPLING].nActivationHeight = 476969; // The best chain should have at least this much work. consensus.nMinimumChainWork = uint256S("0x000000000000000000000000000000000000000000000000000721bfb84aedeb"); @@ -137,21 +137,8 @@ class CMainParams : public CChainParams { vFixedSeeds.clear(); vSeeds.clear(); - vSeeds.push_back(CDNSSeedData("zclassic.org", "dnsseed.zclassic.org")); // zclassic - vSeeds.push_back(CDNSSeedData("zclassic-ce.org", "dnsseed.zclassic-ce.org")); // Zclassic Community - vSeeds.push_back(CDNSSeedData("zclassic.org", "na1.zclassic.org")); // zclassic - vSeeds.push_back(CDNSSeedData("zclassic.org", "na2.zclassic.org")); // zclassic - vSeeds.push_back(CDNSSeedData("zclassic.org", "na3.zclassic.org")); // zclassic - vSeeds.push_back(CDNSSeedData("zclassic.org", "eu1.zclassic.org")); // zclassic - vSeeds.push_back(CDNSSeedData("zclassic.org", "eu2.zclassic.org")); // zclassic - vSeeds.push_back(CDNSSeedData("zclassic.org", "eu3.zclassic.org")); // zclassic - vSeeds.push_back(CDNSSeedData("zclassic.org", "as1.zclassic.org")); // zclassic - vSeeds.push_back(CDNSSeedData("zclassic.org", "as2.zclassic.org")); // zclassic - vSeeds.push_back(CDNSSeedData("zclassic.org", "as3.zclassic.org")); // zclassic - vSeeds.push_back(CDNSSeedData("zclassic-ce.org", "na.zclassic-ce.org")); // Community - vSeeds.push_back(CDNSSeedData("zclassic-ce.org", "eu.zclassic-ce.org")); // Community - vSeeds.push_back(CDNSSeedData("zclassic-ce.org", "as.zclassic-ce.org")); // Community - vSeeds.push_back(CDNSSeedData("zclassic-ce.org", "sa.zclassic-ce.org")); // Community + vSeeds.push_back(CDNSSeedData("zclcore.org", "dnsseed.zclcore.org")); + vSeeds.push_back(CDNSSeedData("zcl.community", "dnsseed.zcl.community")); vSeeds.push_back(CDNSSeedData("chains.run", "seed.zcl.chains.run")); //rizkiwicaksono/bitcoin-seeder @@ -323,9 +310,8 @@ class CTestNetParams : public CChainParams { vFixedSeeds.clear(); vSeeds.clear(); - vSeeds.push_back(CDNSSeedData("zclassic.org", "dnsseed.testnet.zclassic.org")); // Zclassic - vSeeds.push_back(CDNSSeedData("zclassic-ce.org", "dnsseed.testnet.zclassic-ce.org")); // Zclassic Community - vSeeds.push_back(CDNSSeedData("zclassic-ce.org", "eu.testnet.zclassic-ce.org")); // Zclassic Community + vSeeds.push_back(CDNSSeedData("zclcore.org", "dnsseed.testnet.zclcore.org")); + vSeeds.push_back(CDNSSeedData("zcl.community", "dnsseed.testnet.zcl.community")); // guarantees the first 2 characters, when base58 encoded, are "tm" base58Prefixes[PUBKEY_ADDRESS] = {0x1D,0x25}; From 47abe2e2d667f742eb110ac23ab094b4956fc14f Mon Sep 17 00:00:00 2001 From: skellers Date: Sun, 10 Feb 2019 11:06:56 +0000 Subject: [PATCH 8/8] update tests and test data --- src/chainparams.cpp | 6 +++--- src/test/data/alertTests.raw | Bin 1616 -> 1617 bytes src/test/rpc_wallet_tests.cpp | 14 +++++++------- 3 files changed, 10 insertions(+), 10 deletions(-) diff --git a/src/chainparams.cpp b/src/chainparams.cpp index abe255894c6..833afa2cfb9 100644 --- a/src/chainparams.cpp +++ b/src/chainparams.cpp @@ -117,7 +117,7 @@ class CMainParams : public CChainParams { pchMessageStart[1] = 0xe9; pchMessageStart[2] = 0x27; pchMessageStart[3] = 0x64; - vAlertPubKey = ParseHex("04f2cd746e629ffd320a81287474c98c2ad15d15b0a210b0144edcd8f3e1301c6311fd751fa34ba17d88090374cfec7cd9aaca55a5a0c4456511acc01b922005de"); + vAlertPubKey = ParseHex("04a60129fc1915c0e35d92328cbc27cba5dc367dd0eaf7059616aa455afc3f7622161572e1197af352baff0d6563bb75316d095241dd94f809d7f6eefb49dbdff4"); nDefaultPort = 8033; nPruneAfterHeight = 100000; const size_t N = 200, K = 9; @@ -290,7 +290,7 @@ class CTestNetParams : public CChainParams { pchMessageStart[1] = 0x1a; pchMessageStart[2] = 0xf9; pchMessageStart[3] = 0xbf; - vAlertPubKey = ParseHex("048679fb891b15d0cada9692047fd0ae26ad8bfb83fabddbb50334ee5bc0683294deb410be20513c5af6e7b9cec717ade82b27080ee6ef9a245c36a795ab044bb3"); + vAlertPubKey = ParseHex("044d71d7faa4e6d77c08d3a1e8c27fafc922de9ec8c91e809bb0c4788058301ec18a68d9fe42b6ec0467bb7ca7f7ecaecbc05c0b6437d9de21a59232fd917a8803"); nDefaultPort = 18033; nPruneAfterHeight = 1000; const size_t N = 200, K = 9; @@ -413,7 +413,7 @@ class CRegTestParams : public CChainParams { pchMessageStart[1] = 0xe8; pchMessageStart[2] = 0x3f; pchMessageStart[3] = 0x5f; - nDefaultPort = 18344; + nDefaultPort = 18033; nPruneAfterHeight = 1000; const size_t N = 48, K = 5; BOOST_STATIC_ASSERT(equihash_parameters_acceptable(N, K)); diff --git a/src/test/data/alertTests.raw b/src/test/data/alertTests.raw index 7dc9fd1e69b437030d717901ef963553ccd513e6..4bea0bc92d518d60d847536a03727c234214d5bc 100644 GIT binary patch delta 781 zcmV+o1M>XP4ABgbLP$n1L;@gWsYP|FlEz^Ipr{v}pa#i6LTNk=y;oc1ruis@JV@07 zAR!D8X>NT8DJ z`|%CHnrTVf3&jhA@?rh;s;%+bmI5Fv-Dy+pzE(GubXfnXtyb$hnMJPS z%1eNNkpU%>U;$f6M=(VKApqCOd}gCxu?vVvrn$Wv-{`4lv6NG9bqMzPM{WT-nuG!% zZ4#aGK2tWt_fWyLYz#1d*TtU$9Tn@i^^K8HL61n-jqGQ!~!5n>lK%Sa}Czo3@bRQ#)$!$+Y{V7cz0Yz=oJDk zC12r8lh6YcldJ+bNJcP30w71;|ML|fKU)CbO*#cOz*SgJ)yzb}|KB4DJ@bsL8NmV| zS=R83{)c&S$Zr}3%q>`GpBb%D@<( L1Z+v+9Uq0=8M9g! delta 783 zcmV+q1MvLO4A2aaLPfhIVR)Z@O~&NIab|m`bI#wzF6?ox8)D3f(S~P{0VR>INJG1NKwsomE{Xr( z)9GMTM&j_cDlR5V%1~LHSc1G?a99E$R%q2rmF(dKwHY%617Q3AafMmHq~`GPryH29 zm_zykfRO~n2L%@b*Lb3FneH~ppVr5loQZtA>sTBpLwhx;&o?Tr4z zFW`znJmJ7glg|TEM@BG20w6}yAYUxJXG@y*@LO(xkHMnHksh?9vBd?sgEBgY0}}!u z1|X})4!#}pY_gZ$AVZ`R*^WZhM+-1DVV|qVHzP&8lg|SclYRt4L!2M07Vud$O|t%= zbz*rk)9vdV)`uV&siiAIT3%CFp#mTldquB&dMzOgP-1a>ZLO8?$~wdE+m2{f3GfQL z{Y^4wlh6YclNbe4NJcP30w7ISw6I9Cw|SB7$=Y7Zsy@TQ$|z9g#H6(rWNA{1jA#NN zEL7sIMCW&pMpaw6nq`OQ6DRx|Uzf;q@|4y`)(!)lR+G>J6qCpWLP$q2MFJrJnNTV{ zzA`IY+2RW_axQ+@t}vq!M+V`iJxcs_wallet); CheckRPCThrows("z_mergetoaddress 1 2", - "Error: z_mergetoaddress is disabled. Run './zcash-cli help z_mergetoaddress' for instructions on how to enable this feature."); + "Error: z_mergetoaddress is disabled. Run './zclassic-cli help z_mergetoaddress' for instructions on how to enable this feature."); // Set global state required for z_mergetoaddress fExperimentalMode = true; @@ -1764,7 +1764,7 @@ BOOST_AUTO_TEST_CASE(rpc_z_mergetoaddress_parameters) std::vector v (2 * (ZC_MEMO_SIZE+1)); // x2 for hexadecimal string format std::fill(v.begin(),v.end(), 'A'); std::string badmemo(v.begin(), v.end()); - CheckRPCThrows("z_mergetoaddress [\"" + taddr1 + "\"] " + aSproutAddr + " 0.0001 100 100 " + badmemo, + CheckRPCThrows("z_mergetoaddress [\"" + taddr1 + "\"] " + aSproutAddr + " 0.0001 100 100 " + badmemo, "Invalid parameter, size of memo is larger than maximum allowed 512"); // Mutable tx containing contextual information we need to build tx @@ -1804,9 +1804,9 @@ BOOST_AUTO_TEST_CASE(rpc_z_mergetoaddress_parameters) BOOST_CHECK( find_error(objError, "Recipient parameter missing")); } - std::vector sproutNoteInputs = + std::vector sproutNoteInputs = {MergeToAddressInputSproutNote{JSOutPoint(), SproutNote(), 0, SproutSpendingKey()}}; - std::vector saplingNoteInputs = + std::vector saplingNoteInputs = {MergeToAddressInputSaplingNote{SaplingOutPoint(), SaplingNote(), 0, SaplingExpandedSpendingKey()}}; // Sprout and Sapling inputs -> throw