Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Signet nits #9

Open
wants to merge 23 commits into
base: signet
Choose a base branch
from
Open
Changes from 1 commit
Commits
Show all changes
23 commits
Select commit Hold shift + click to select a range
f7d9294
add witness commitment section support to primitive/block
kallewoof Jul 17, 2019
a5fa1a7
add simple signature support (checker/creator)
kallewoof Jul 17, 2019
88902e2
add signet basic support (signet.cpp)
kallewoof Jul 17, 2019
93dd0a1
add signet chain and accompanying parameters
kallewoof Aug 19, 2019
d691232
qt: update QT to support signet network
kallewoof Jul 17, 2019
7c3dec1
consensus: add signet validation
kallewoof Jul 17, 2019
934c0ac
i/o: make DecodeHexBlk able to read block hex from file
kallewoof Jul 18, 2019
264ceda
rpc: add getnewblockhex command for obtaining an unsigned block
kallewoof Jul 18, 2019
59e8952
rpc: add signblock command
kallewoof Jul 18, 2019
3f856b9
rpc: include signet commitment in blockToJSON dictionary results
kallewoof Jul 18, 2019
d15d65e
rpc: refactor out grindBlock part from generateBlocks
kallewoof Aug 19, 2019
4b46180
rpc: add grindblock command for generating POW on a signed signet block
kallewoof Aug 19, 2019
fc94419
test: added signet mining tests
kallewoof Aug 5, 2019
cac0e98
contrib: add signet scripts (issuer, etc)
kallewoof Jul 17, 2019
d3f63bd
signet: hard-coded parameters for Signet Global Network III (2019-08-19)
kallewoof Jun 28, 2019
2335feb
rpc/signet: show signet blockscript in 'getblockchaininfo'
kallewoof Aug 23, 2019
9f2e4b0
util_tests.cpp update hash for hard coded chain merge
kallewoof Sep 10, 2019
b4f922f
9102: Really don't validate genesis block
instagibbs Nov 7, 2016
8ffa06c
nit: consensus.signet_blocks = false in the other chains
jtimon Sep 7, 2019
a908c78
nit: moveonly: easier to make CreateSignetGenesisBlock static in the …
jtimon Sep 8, 2019
55a7ceb
nit: SigNetParams: set each default value independently
jtimon Sep 7, 2019
010cca0
nit: no need to grind genesis blocks
jtimon Sep 7, 2019
7623165
proposal: signet restart (hash chain name too)
jtimon Sep 8, 2019
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
nit: SigNetParams: set each default value independently
(except for the default seeds)
  • Loading branch information
jtimon committed Sep 10, 2019
commit 55a7ceb943b706103cf8662396f91d92b53f838a
30 changes: 11 additions & 19 deletions src/chainparams.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -274,32 +274,24 @@ class CTestNetParams : public CChainParams {
class SigNetParams : public CChainParams {
public:
SigNetParams(const ArgsManager& args) {
std::vector<uint8_t> bin;
vSeeds.clear();
uint32_t genesis_nonce = 0;

if (!args.IsArgSet("-signet_blockscript")) {
LogPrintf("Using default signet network\n");
bin = ParseHex("512103ad5e0edad18cb1f0fc0d28a3d4f1f3e445640337489abb10404f2d1e086be43051ae");
genesis_nonce = 621297;
vSeeds.clear();
if (args.IsArgSet("-signet_seednode")) {
vSeeds = gArgs.GetArgs("-signet_seednode");
} else if (!args.IsArgSet("-signet_blockscript")) {
LogPrintf("Using default signet network seeds\n");
vSeeds.push_back("178.128.221.177");
vSeeds.push_back("2a01:7c8:d005:390::5");
vSeeds.push_back("ntv3mtqw5wt63red.onion:38333");
} else {
if (args.GetArgs("-signet_blockscript").size() != 1) {
throw std::runtime_error(strprintf("%s: -signet_blockscript cannot be multiple values.", __func__));
}
bin = ParseHex(args.GetArgs("-signet_blockscript")[0]);
genesis_nonce = args.GetArg("-signet_genesisnonce", 0);
if (args.IsArgSet("-signet_seednode")) {
vSeeds = gArgs.GetArgs("-signet_seednode");
}

LogPrintf("SigNet with block script %s\n", gArgs.GetArgs("-signet_blockscript")[0]);
}

strNetworkID = "signet";
const uint32_t genesis_nonce = args.GetArg("-signet_genesisnonce", 621297);
const std::string signet_blockscript_str = args.GetArg("-signet_blockscript", "512103ad5e0edad18cb1f0fc0d28a3d4f1f3e445640337489abb10404f2d1e086be43051ae");
LogPrintf("SigNet with block script %s\n", signet_blockscript_str);
std::vector<uint8_t> bin = ParseHex(signet_blockscript_str);
g_signet_blockscript = CScript(bin.begin(), bin.end());

strNetworkID = "signet";
consensus.signet_blocks = true;
consensus.nSubsidyHalvingInterval = 210000;
consensus.BIP34Height = 1;
Expand Down