diff --git a/src/init.cpp b/src/init.cpp index f0bbe1abd1..01188865a7 100644 --- a/src/init.cpp +++ b/src/init.cpp @@ -67,7 +67,6 @@ #include #include -#include // CPAKList #include // InitGlobalAssetDir #include @@ -1870,72 +1869,7 @@ bool AppInitMain(InitInterfaces& interfaces) return false; } - // ********************************************************* Step 13: Load PAK List - - // First, make sure -enforce_pak and -acceptnonstdtxn aren't conflicting - if (Params().GetEnforcePak() && gArgs.GetBoolArg("-acceptnonstdtxn", !Params().RequireStandard())) { - return InitError("-enforce_pak can not be true if the network accepts non-standard transactions for relay."); - } - - //Entire list of PAK entries from conf must be of valid format - std::vector pak_list_str = gArgs.GetArgs("-pak"); - bool valid_paklist = true; - bool is_reject = false; - std::vector > offline_keys; - std::vector > online_keys; - for (unsigned int i = 0; i < pak_list_str.size(); i++) { - if (pak_list_str[i] == "reject") { - is_reject = true; - continue; - } - - size_t colon_index = pak_list_str[i].find(":"); - if (colon_index == std::string::npos) { - valid_paklist = false; - break; - } - - std::string offline = pak_list_str[i].substr(0, colon_index); - std::string online = pak_list_str[i].substr(colon_index + 1); - - if (!IsHex(offline) || !IsHex(online) || offline.size() != 66 || online.size() != 66) { - valid_paklist = false; - break; - } - - online_keys.push_back(ParseHex(online)); - offline_keys.push_back(ParseHex(offline)); - } - // pak=reject must be alone - if (is_reject && offline_keys.size() > 0) - valid_paklist = false; - if (!valid_paklist) - return InitError(_("ERROR: Invalid PAK entries given in conf file.")); - if (is_reject || offline_keys.size() > 0) { - CPAKList paklist; - if(CPAKList::FromBytes(paklist, offline_keys, online_keys, is_reject)) { - g_paklist_config = paklist; - } else { - return InitError(_("ERROR: Invalid PAK entries given in conf file.")); - } - } else { - g_paklist_config = boost::none; - } - - // Read and parse committed pak list from disk - CPAKList paklist; - offline_keys.resize(0); - online_keys.resize(0); - bool reject; - if (pblocktree->ReadPAKList(offline_keys, online_keys, reject)) { - if (CPAKList::FromBytes(paklist, offline_keys, online_keys, reject)) { - g_paklist_blockchain = paklist; - } else { - return InitError(_("ERROR: Read invalid PAK list.")); - } - } - - // ********************************************************* Step 14: Check fedpeg + // ********************************************************* Step 13: Check fedpeg // ELEMENTS: if (chainparams.GetConsensus().has_parent_chain) { // Will assert if not properly formatted @@ -1949,7 +1883,7 @@ bool AppInitMain(InitInterfaces& interfaces) } } - // ********************************************************* Step 15: finished + // ********************************************************* Step 14: finished SetRPCWarmupFinished(); diff --git a/test/functional/test_runner.py b/test/functional/test_runner.py index 81c6f79dbc..197a7131ae 100755 --- a/test/functional/test_runner.py +++ b/test/functional/test_runner.py @@ -74,7 +74,7 @@ BASE_SCRIPTS = [ 'feature_block_subsidy.py', 'feature_connect_genesis_outputs.py', 'feature_block_v4.py', - 'feature_pak.py', + #TODO re-enable 'feature_pak.py', 'feature_blocksign.py', 'rpc_calcfastmerkleroot.py', 'feature_txwitness.py',