|
7 | 7 | namespace Blockcore.Networks.City |
8 | 8 | { |
9 | 9 | internal class CitySetup |
10 | | - { |
11 | | - internal static CitySetup Instance = new CitySetup(); |
| 10 | + { |
| 11 | + internal static CitySetup Instance = new CitySetup(); |
12 | 12 |
|
13 | | - internal CoinSetup Setup = new CoinSetup |
14 | | - { |
15 | | - FileNamePrefix = "city", |
16 | | - ConfigFileName = "city.conf", |
17 | | - Magic = "01-59-54-43", |
18 | | - CoinType = 1926, // SLIP-0044: https://github.com/satoshilabs/slips/blob/master/slip-0044.md, |
19 | | - PremineReward = 13736000000, |
20 | | - PoWBlockReward = 2, |
21 | | - PoSBlockReward = 20, |
22 | | - LastPowBlock = 2500, |
23 | | - GenesisText = "July 27, 2018, New Scientiest, Bitcoin’s roots are in anarcho-capitalism", // The New York Times, 2020-04-16 |
24 | | - TargetSpacing = TimeSpan.FromSeconds(64), |
25 | | - ProofOfStakeTimestampMask = 0x0000000F, // 0x0000003F // 64 sec |
26 | | - PoSVersion = 3 |
27 | | - }; |
| 13 | + internal CoinSetup Setup = new CoinSetup |
| 14 | + { |
| 15 | + FileNamePrefix = "city", |
| 16 | + ConfigFileName = "city.conf", |
| 17 | + Magic = "01-59-54-43", |
| 18 | + CoinType = 1926, // SLIP-0044: https://github.com/satoshilabs/slips/blob/master/slip-0044.md, |
| 19 | + PremineReward = 13736000000, |
| 20 | + PoWBlockReward = 2, |
| 21 | + PoSBlockReward = 20, |
| 22 | + LastPowBlock = 2500, |
| 23 | + GenesisText = "July 27, 2018, New Scientiest, Bitcoin’s roots are in anarcho-capitalism", // The New York Times, 2020-04-16 |
| 24 | + TargetSpacing = TimeSpan.FromSeconds(64), |
| 25 | + ProofOfStakeTimestampMask = 0x0000000F, // 0x0000003F // 64 sec |
| 26 | + PoSVersion = 3 |
| 27 | + }; |
28 | 28 |
|
29 | | - internal NetworkSetup Main = new NetworkSetup |
30 | | - { |
31 | | - Name = "CityMain", |
32 | | - RootFolderName = "city", |
33 | | - CoinTicker = "CITY", |
34 | | - DefaultPort = 4333, |
35 | | - DefaultRPCPort = 4334, |
36 | | - DefaultAPIPort = 4335, |
37 | | - DefaultSignalRPort = 4336, |
38 | | - PubKeyAddress = 28, // B https://en.bitcoin.it/wiki/List_of_address_prefixes |
39 | | - ScriptAddress = 88, // b |
40 | | - SecretAddress = 237, |
41 | | - GenesisTime = 1538481600, |
42 | | - GenesisNonce = 1626464, |
43 | | - GenesisBits = 0x1E0FFFFF, |
44 | | - GenesisVersion = 1, |
45 | | - GenesisReward = Money.Zero, |
46 | | - HashGenesisBlock = "00000b0517068e602ed5279c20168cfa1e69884ee4e784909652da34c361bff2", |
47 | | - HashMerkleRoot = "b3425d46594a954b141898c7eebe369c6e6a35d2dab393c1f495504d2147883b", |
48 | | - DNS = new[] { "seed.city-chain.org", "seed.citychain.foundation", "seed.city-coin.org", "seed.liberstad.com", "city.seed.blockcore.net" }, |
49 | | - Nodes = new[] { "23.97.234.230", "13.73.143.193", "89.10.227.34" }, |
50 | | - Checkpoints = new Dictionary<int, CheckpointInfo> |
| 29 | + internal NetworkSetup Main = new NetworkSetup |
| 30 | + { |
| 31 | + Name = "CityMain", |
| 32 | + RootFolderName = "city", |
| 33 | + CoinTicker = "CITY", |
| 34 | + DefaultPort = 4333, |
| 35 | + DefaultRPCPort = 4334, |
| 36 | + DefaultAPIPort = 4335, |
| 37 | + DefaultSignalRPort = 4336, |
| 38 | + PubKeyAddress = 28, // B https://en.bitcoin.it/wiki/List_of_address_prefixes |
| 39 | + ScriptAddress = 88, // b |
| 40 | + SecretAddress = 237, |
| 41 | + GenesisTime = 1538481600, |
| 42 | + GenesisNonce = 1626464, |
| 43 | + GenesisBits = 0x1E0FFFFF, |
| 44 | + GenesisVersion = 1, |
| 45 | + GenesisReward = Money.Zero, |
| 46 | + HashGenesisBlock = "00000b0517068e602ed5279c20168cfa1e69884ee4e784909652da34c361bff2", |
| 47 | + HashMerkleRoot = "b3425d46594a954b141898c7eebe369c6e6a35d2dab393c1f495504d2147883b", |
| 48 | + DNS = new[] { "seed.city-chain.org", "seed.citychain.foundation", "seed.city-coin.org", "seed.liberstad.com", "city.seed.blockcore.net" }, |
| 49 | + Nodes = new[] { "23.97.234.230", "13.73.143.193", "89.10.227.34" }, |
| 50 | + Checkpoints = new Dictionary<int, CheckpointInfo> |
51 | 51 | { |
52 | | - // TODO: Add checkpoints as the network progresses. |
| 52 | + { 0, new CheckpointInfo(new uint256("0x00000b0517068e602ed5279c20168cfa1e69884ee4e784909652da34c361bff2"), new uint256("0x0000000000000000000000000000000000000000000000000000000000000000")) }, |
| 53 | + { 2, new CheckpointInfo(new uint256("0x072227af2fda8ef6a5f7a19ec3a1c6de54ddc537dd407da938766ed460e77982"), new uint256("0xe93eb6c21c65024ca06ac2f89481bdc832cab1607ed2adfeafb6c679b6a4a1f6")) }, |
| 54 | + { 50, new CheckpointInfo(new uint256("0xce58ab37dd5965c3474c5917fcbb59aa342c6754a452e5faf87050bb6015d511"), new uint256("0xb877b17b3d7324ac1a3615a6c245c702282e5be74fd50cf25bb02bc5f2ea7944")) }, |
| 55 | + { 100, new CheckpointInfo(new uint256("0x5edbf09aadfbdb0d74d428b002fcda197debb775955a161f2890ed844a5159da"), new uint256("0x354210eecb7ed3f8df3d384b8d615f789fdffdf3f3d4945c23e5966827010b73")) }, |
| 56 | + { 150000, new CheckpointInfo(new uint256("0x0be1d4fce6a93989025d405292d12aca12c7417494e50c2c633ad2f7bb7cbb53"), new uint256("0xcaafe0d5594c6b12bd0b819ccc22dba5ae7dcea32721cd97df369dbe868e13e9")) }, |
| 57 | + { 800000, new CheckpointInfo(new uint256("0xaf94ebd59507829e82d2e98e75f8777224bf54e2f4ad76ff7bdc2ebebc634cb9"), new uint256("0xbe19a177b90653ee3a654e7fd307e93410db3478dbc28225e24aea9d2087d04b")) }, |
| 58 | + { 1060000, new CheckpointInfo(new uint256("0xea17e88ff533ca71dbaf0a8772d1f680845371e774250e35251671227fdcb699"), new uint256("0xfc4d6eec52900c6623711427d11357afe6becc6aafa71ed3ade3fe3128d9f23f")) }, |
53 | 59 | } |
54 | | - }; |
| 60 | + }; |
55 | 61 |
|
56 | | - internal NetworkSetup RegTest = new NetworkSetup |
57 | | - { |
58 | | - Name = "CityRegTest", |
59 | | - RootFolderName = "cityregtest", |
60 | | - CoinTicker = "TCITY", |
61 | | - DefaultPort = 14333, |
62 | | - DefaultRPCPort = 14334, |
63 | | - DefaultAPIPort = 14335, |
64 | | - DefaultSignalRPort = 14336, |
65 | | - PubKeyAddress = 66, |
66 | | - ScriptAddress = 196, |
67 | | - SecretAddress = 194, |
68 | | - GenesisTime = 1587115302, |
69 | | - GenesisNonce = 5917, |
70 | | - GenesisBits = 0x1F00FFFF, |
71 | | - GenesisVersion = 1, |
72 | | - GenesisReward = Money.Zero, |
73 | | - HashGenesisBlock = "000039df5f7c79084bf96c67ea24761e177d77c24f326eb5294860144301cb68", |
74 | | - HashMerkleRoot = "d382311c9e4a1ec84be1b32eddb33f7f0420544a460754f573d7cb7054566d75", |
75 | | - DNS = new[] { "seedregtest1.city.blockcore.net", "seedregtest2.city.blockcore.net", "seedregtest.city.blockcore.net" }, |
76 | | - Nodes = new[] { "23.97.234.230", "13.73.143.193", "89.10.227.34" }, |
77 | | - Checkpoints = new Dictionary<int, CheckpointInfo> |
78 | | - { |
79 | | - // TODO: Add checkpoints as the network progresses. |
80 | | - } |
81 | | - }; |
| 62 | + internal NetworkSetup RegTest = new NetworkSetup |
| 63 | + { |
| 64 | + Name = "CityRegTest", |
| 65 | + RootFolderName = "cityregtest", |
| 66 | + CoinTicker = "TCITY", |
| 67 | + DefaultPort = 14333, |
| 68 | + DefaultRPCPort = 14334, |
| 69 | + DefaultAPIPort = 14335, |
| 70 | + DefaultSignalRPort = 14336, |
| 71 | + PubKeyAddress = 66, |
| 72 | + ScriptAddress = 196, |
| 73 | + SecretAddress = 194, |
| 74 | + GenesisTime = 1587115302, |
| 75 | + GenesisNonce = 5917, |
| 76 | + GenesisBits = 0x1F00FFFF, |
| 77 | + GenesisVersion = 1, |
| 78 | + GenesisReward = Money.Zero, |
| 79 | + HashGenesisBlock = "000039df5f7c79084bf96c67ea24761e177d77c24f326eb5294860144301cb68", |
| 80 | + HashMerkleRoot = "d382311c9e4a1ec84be1b32eddb33f7f0420544a460754f573d7cb7054566d75", |
| 81 | + DNS = new[] { "seedregtest1.city.blockcore.net", "seedregtest2.city.blockcore.net", "seedregtest.city.blockcore.net" }, |
| 82 | + Nodes = new[] { "23.97.234.230", "13.73.143.193", "89.10.227.34" }, |
| 83 | + Checkpoints = new Dictionary<int, CheckpointInfo> |
| 84 | + { |
| 85 | + // TODO: Add checkpoints as the network progresses. |
| 86 | + } |
| 87 | + }; |
82 | 88 |
|
83 | | - internal NetworkSetup Test = new NetworkSetup |
84 | | - { |
85 | | - Name = "CityTest", |
86 | | - RootFolderName = "citytest", |
87 | | - CoinTicker = "TCITY", |
88 | | - DefaultPort = 24333, |
89 | | - DefaultRPCPort = 24334, |
90 | | - DefaultAPIPort = 24335, |
91 | | - DefaultSignalRPort = 24336, |
92 | | - PubKeyAddress = 66, |
93 | | - ScriptAddress = 196, |
94 | | - SecretAddress = 194, |
95 | | - GenesisTime = 1587115303, |
96 | | - GenesisNonce = 3451, |
97 | | - GenesisBits = 0x1F0FFFFF, |
98 | | - GenesisVersion = 1, |
99 | | - GenesisReward = Money.Zero, |
100 | | - HashGenesisBlock = "00090058f8a37e4190aa341ab9605d74b282f0c80983a676ac44b0689be0fae1", |
101 | | - HashMerkleRoot = "88cd7db112380c4d6d4609372b04cdd56c4f82979b7c3bf8c8a764f19859961f", |
102 | | - DNS = new[] { "seedtest1.city.blockcore.net", "seedtest2.city.blockcore.net", "seedtest.city.blockcore.net" }, |
103 | | - Nodes = new[] { "23.97.234.230", "13.73.143.193", "89.10.227.34" }, |
104 | | - Checkpoints = new Dictionary<int, CheckpointInfo> |
105 | | - { |
106 | | - // TODO: Add checkpoints as the network progresses. |
107 | | - } |
108 | | - }; |
| 89 | + internal NetworkSetup Test = new NetworkSetup |
| 90 | + { |
| 91 | + Name = "CityTest", |
| 92 | + RootFolderName = "citytest", |
| 93 | + CoinTicker = "TCITY", |
| 94 | + DefaultPort = 24333, |
| 95 | + DefaultRPCPort = 24334, |
| 96 | + DefaultAPIPort = 24335, |
| 97 | + DefaultSignalRPort = 24336, |
| 98 | + PubKeyAddress = 66, |
| 99 | + ScriptAddress = 196, |
| 100 | + SecretAddress = 194, |
| 101 | + GenesisTime = 1587115303, |
| 102 | + GenesisNonce = 3451, |
| 103 | + GenesisBits = 0x1F0FFFFF, |
| 104 | + GenesisVersion = 1, |
| 105 | + GenesisReward = Money.Zero, |
| 106 | + HashGenesisBlock = "00090058f8a37e4190aa341ab9605d74b282f0c80983a676ac44b0689be0fae1", |
| 107 | + HashMerkleRoot = "88cd7db112380c4d6d4609372b04cdd56c4f82979b7c3bf8c8a764f19859961f", |
| 108 | + DNS = new[] { "seedtest1.city.blockcore.net", "seedtest2.city.blockcore.net", "seedtest.city.blockcore.net" }, |
| 109 | + Nodes = new[] { "23.97.234.230", "13.73.143.193", "89.10.227.34" }, |
| 110 | + Checkpoints = new Dictionary<int, CheckpointInfo> |
| 111 | + { |
| 112 | + // TODO: Add checkpoints as the network progresses. |
| 113 | + } |
| 114 | + }; |
109 | 115 |
|
110 | | - public bool IsPoSv3() |
111 | | - { |
112 | | - return Setup.PoSVersion == 3; |
113 | | - } |
| 116 | + public bool IsPoSv3() |
| 117 | + { |
| 118 | + return Setup.PoSVersion == 3; |
| 119 | + } |
114 | 120 |
|
115 | | - public bool IsPoSv4() |
116 | | - { |
117 | | - return Setup.PoSVersion == 4; |
118 | | - } |
119 | | - } |
| 121 | + public bool IsPoSv4() |
| 122 | + { |
| 123 | + return Setup.PoSVersion == 4; |
| 124 | + } |
| 125 | + } |
120 | 126 | } |
0 commit comments