<commit_before>// Copyright (c) 2010 <NAME>
// Copyright (c) 2009-2014 The Bitcoin developers
// Copyright (c) 2013-2014 The Dogecoin developers
// Copyright (c)      2014 The Inutoshi developers
// Distributed under the MIT/X11 software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-license.php.

#include "chainparams.h"

#include "assert.h"
#include "core.h"
#include "protocol.h"
#include "util.h"

#include <boost/assign/list_of.hpp>

using namespace boost::assign;

//
// Main network
//

unsigned int pnSeed[] =
{
  
};

class CMainParams : public CChainParams {
public:
    CMainParams() {
        // The message start string is designed to be unlikely to occur in normal data.
        // The characters are rarely used upper ASCII, not valid as UTF-8, and produce
        // a large 4-byte int at any alignment.
        pchMessageStart[0] = 0xf3;
        pchMessageStart[1] = 0xf2;
        pchMessageStart[2] = 0xf2;
        pchMessageStart[3] = 0xf3;
        //owned and valid alert key
        vAlertPubKey = ParseHex("<KEY>");
        nDefaultPort = 9112; //p2p port
        nRPCPort = 9111;
        bnProofOfWorkLimit = CBigNum(~uint256(0) >> 20);
        nSubsidyHalvingInterval = 210000;

        // Build the genesis block. Note that the output of the genesis coinbase cannot
        // be spent as it did not originally exist in the database.
        const char* pszTimestamp = "NY Times 9/20/2014 ex-employees say home depot left data vulnerable";
        CTransaction txNew;
        txNew.vin.resize(1);
        txNew.vout.resize(1);
        txNew.vin[0].scriptSig = CScript() << 486604799 << CBigNum(4) << vector<unsigned char>((const unsigned char*)pszTimestamp, (const unsigned char*)pszTimestamp + strlen(pszTimestamp));
        txNew.vout[0].nValue = 1 * COIN;
        //use a probably impossible public key
        txNew.vout[0].scriptPubKey = CScript() << ParseHex("<KEY>") << OP_CHECKSIG;
        genesis.vtx.push_back(txNew);
        genesis.hashPrevBlock = 0;
        genesis.hashMerkleRoot = genesis.BuildMerkleTree();
        genesis.nVersion = 1;
        genesis.nBits    = 0x1e0ffff0;


        genesis.nTime = 1411271178;
        genesis.nNonce = 614264;
        assert(genesis.hashMerkleRoot == uint256("0x7fe1914ce8ec112ed706ac0c1ace60c6a1c3c238293d94256b2083d8e8729f21"));
        assert(genesis.GetHash() == uint256("0x000009ee1dec51a93d25a3a3230bfb2083180a926f4eddd61ec58e9c01cbb15b"));


        if (false) 
        {
            //This will output (to stdout) the code for a new genesis block when it is found
            genesis.nTime=time(NULL);
            genesis.nNonce=0;
            printf("Searching for genesis block...\n");

            uint256 hashTarget = CBigNum().SetCompact(genesis.nBits).getuint256();
            uint256 thash;

            while(1)
            {
                thash=genesis.GetHash();
                if (thash <= hashTarget)
                    break;
                if ((genesis.nNonce & 0xFFFF) == 0)
                {
                    printf("nonce %08X: hash = %s \n",genesis.nNonce, thash.ToString().c_str());
                }
                ++genesis.nNonce;
                if (genesis.nNonce == 0)
                {
                    printf("NONCE WRAPPED, incrementing time\n");
                    ++genesis.nTime;
                }
            }
            printf("genesis.nTime = %u;\n",genesis.nTime);
            printf("genesis.nNonce = %u;\n",genesis.nNonce);
            printf("assert(genesis.hashMerkleRoot == uint256(\"0x%s\"));\n",genesis.hashMerkleRoot.ToString().c_str());
            printf("assert(genesis.GetHash() == uint256(\"0x%s\"));\n",genesis.GetHash().ToString().c_str());
            exit(1);
        }


        hashGenesisBlock = genesis.GetHash();
        vSeeds.push_back(CDNSSeedData("earlz.net", "earlz.net"));
        vSeeds.push_back(CDNSSeedData("b1.earlz.net", "b1.earlz.net"));
        vSeeds.push_back(CDNSSeedData("b2.earlz.net", "b2.earlz.net"));



        // Workaround for Boost not being quite compatible with C++11;
        std::vector<unsigned char> pka = list_of(33); //E
        base58Prefixes[PUBKEY_ADDRESS] = pka;
        
        std::vector<unsigned char> sca = list_of(92); //e
        base58Prefixes[SCRIPT_ADDRESS] = sca;

        std::vector<unsigned char> sk  = list_of(128);
        base58Prefixes[SECRET_KEY]     = sk;
        
        std::vector<unsigned char> epk = list_of(0x04)(0x88)(0xC4)(0x2E);
        base58Prefixes[EXT_PUBLIC_KEY] = epk;
        
        std::vector<unsigned char> esk = list_of(0x04)(0x88)(0xE1)(0xF4);
        base58Prefixes[EXT_SECRET_KEY] = esk;


        // Convert the pnSeeds array into usable address objects.
        for (unsigned int i = 0; i < ARRAYLEN(pnSeed); i++)
        {<commit_msg>update to test genesis seed and prepare for mining<commit_after>// Copyright (c) 2010 <NAME>
// Copyright (c) 2009-2014 The Bitcoin developers
// Copyright (c) 2013-2014 The Dogecoin developers
// Copyright (c)      2014 The Inutoshi developers
// Distributed under the MIT/X11 software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-license.php.

#include "chainparams.h"

#include "assert.h"
#include "core.h"
#include "protocol.h"
#include "util.h"

#include <boost/assign/list_of.hpp>

using namespace boost::assign;

//
// Main network
//

unsigned int pnSeed[] =
{
  
};

class CMainParams : public CChainParams {
public:
    CMainParams() {
        // The message start string is designed to be unlikely to occur in normal data.
        // The characters are rarely used upper ASCII, not valid as UTF-8, and produce
        // a large 4-byte int at any alignment.
        pchMessageStart[0] = 0xf3;
        pchMessageStart[1] = 0xf2;
        pchMessageStart[2] = 0xf2;
        pchMessageStart[3] = 0xf3;
        //owned and valid alert key
        vAlertPubKey = ParseHex("<KEY>");
        nDefaultPort = 9112; //p2p port
        nRPCPort = 9111;
        bnProofOfWorkLimit = CBigNum(~uint256(0) >> 20);
        nSubsidyHalvingInterval = 210000;

        // Build the genesis block. Note that the output of the genesis coinbase cannot
        // be spent as it did not originally exist in the database.
        const char* pszTimestamp = "NY Times 9/25/2014 PRESIDENT, AT U.N., VOWS TO COUNTER EXTREMIST THREAT";
        CTransaction txNew;
        txNew.vin.resize(1);
        txNew.vout.resize(1);
        txNew.vin[0].scriptSig = CScript() << 486604799 << CBigNum(4) << vector<unsigned char>((const unsigned char*)pszTimestamp, (const unsigned char*)pszTimestamp + strlen(pszTimestamp));
        txNew.vout[0].nValue = 1 * COIN;
        //use a probably impossible public key
        txNew.vout[0].scriptPubKey = CScript() << ParseHex("000000000000000000000000000000000000000005b8c857fbcbc8bc4a8e4d3eb4b10f4d4604fa08dce601aaf0f470216fe1b51850b4acf21b179c45070ac7b03a") << OP_CHECKSIG;
        genesis.vtx.push_back(txNew);
        genesis.hashPrevBlock = 0;
        genesis.hashMerkleRoot = genesis.BuildMerkleTree();
        genesis.nVersion = 1;
        genesis.nBits    = 0x1e0ffff0;




        if (true) 
        {
            //This will output (to stdout) the code for a new genesis block when it is found
            genesis.nTime=time(NULL);
            genesis.nNonce=0;
            printf("Searching for genesis block...\n");

            uint256 hashTarget = CBigNum().SetCompact(genesis.nBits).getuint256();
            uint256 thash;

            while(1)
            {
                thash=genesis.GetHash();
                if (thash <= hashTarget)
                    break;
                if ((genesis.nNonce & 0xFFFF) == 0)
                {
                    printf("nonce %08X: hash = %s \n",genesis.nNonce, thash.ToString().c_str());
                }
                ++genesis.nNonce;
                if (genesis.nNonce == 0)
                {
                    printf("NONCE WRAPPED, incrementing time\n");
                    ++genesis.nTime;
                }
            }
            printf("genesis.nTime = %u;\n",genesis.nTime);
            printf("genesis.nNonce = %u;\n",genesis.nNonce);
            printf("assert(genesis.hashMerkleRoot == uint256(\"0x%s\"));\n",genesis.hashMerkleRoot.ToString().c_str());
            printf("assert(genesis.GetHash() == uint256(\"0x%s\"));\n",genesis.GetHash().ToString().c_str());
            exit(1);
        }


        hashGenesisBlock = genesis.GetHash();
        vSeeds.push_back(CDNSSeedData("earlz.net", "earlz.net"));



        // Workaround for Boost not being quite compatible with C++11;
        std::vector<unsigned char> pka = list_of(33); //E
        base58Prefixes[PUBKEY_ADDRESS] = pka;
        
        std::vector<unsigned char> sca = list_of(92); //e
        base58Prefixes[SCRIPT_ADDRESS] = sca;

        std::vector<unsigned char> sk  = list_of(128);
        base58Prefixes[SECRET_KEY]     = sk;
        
        std::vector<unsigned char> epk = list_of(0x04)(0x88)(0xC4)(0x2E);
        base58Prefixes[EXT_PUBLIC_KEY] = epk;
        
        std::vector<unsigned char> esk = list_of(0x04)(0x88)(0xE1)(0xF4);
        base58Prefixes[EXT_SECRET_KEY] = esk;


        // Convert the pnSeeds array into usable address objects.
        for (unsigned int i = 0; i < ARRAYLEN(pnSeed); i++)
        {
{'fraction_non_alphanumeric': 0.12228986435971377, 'fraction_numerical': 0.05425611449321799, 'mean_word_length': 2.310003534817957, 'pattern_counts': {'":': 0, '<': 46, '<?xml version=': 0, '>': 26, 'https://': 0, 'lorem ipsum': 0, 'www.': 2, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 1, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7617421', 'n_tokens_mistral': 3387, 'n_tokens_neox': 2975, 'n_words': 665}