Documentation ¶
Index ¶
Constants ¶
View Source
const ( // DeploymentTestDummy defines the rule change deployment ID for testing // purposes. DeploymentTestDummy = iota // DeploymentCSV defines the rule change deployment ID for the CSV // soft-fork package. The CSV package includes the deployment of BIPS // 68, 112, and 113. DeploymentCSV // DeploymentSegwit defines the rule change deployment ID for the // Segregated Witness (segwit) soft-fork package. The segwit package // includes the deployment of BIPS 141, 142, 144, 145, 147 and 173. DeploymentSegwit // DefinedDeployments is the number of currently defined deployments. DefinedDeployments )
Constants that define the deployment offset in the deployments field of the parameters for each deployment. This is useful to be able to get the details of a specific deployment by name.
View Source
const ( // MainNet represents the main litecoin network. LtcMainNet wire.BitcoinNet = 0xdbb6c0fb // TestNet4 represents the test network (version 4). LtcTestNet4 wire.BitcoinNet = 0xf1c8d2fd )
Variables ¶
View Source
var ( // LtcMainNetParams defines the network parameters for the main Litecoin network. LtcMainNetParams = chaincfg.Params{ Name: "mainnet", Net: LtcMainNet, DefaultPort: "9333", DNSSeeds: []chaincfg.DNSSeed{ {"seed-a.litecoin.loshan.co.uk", true}, {"dnsseed.thrasher.io", true}, {"dnsseed.litecointools.com", false}, {"dnsseed.litecoinpool.org", false}, {"dnsseed.koin-project.com", false}, }, GenesisBlock: &genesisBlock, GenesisHash: &genesisHash, PowLimit: mainPowLimit, PowLimitBits: 504365055, BIP0034Height: 710000, BIP0065Height: 918684, BIP0066Height: 811879, CoinbaseMaturity: 100, SubsidyReductionInterval: 840000, TargetTimespan: (time.Hour * 24 * 3) + (time.Hour * 12), TargetTimePerBlock: (time.Minute * 2) + (time.Second * 30), RetargetAdjustmentFactor: 4, ReduceMinDifficulty: false, MinDiffReductionTime: 0, GenerateSupported: false, Checkpoints: []chaincfg.Checkpoint{ {1500, newHashFromStr("841a2965955dd288cfa707a755d05a54e45f8bd476835ec9af4402a2b59a2967")}, {4032, newHashFromStr("9ce90e427198fc0ef05e5905ce3503725b80e26afd35a987965fd7e3d9cf0846")}, {8064, newHashFromStr("eb984353fc5190f210651f150c40b8a4bab9eeeff0b729fcb3987da694430d70")}, {16128, newHashFromStr("602edf1859b7f9a6af809f1d9b0e6cb66fdc1d4d9dcd7a4bec03e12a1ccd153d")}, {23420, newHashFromStr("d80fdf9ca81afd0bd2b2a90ac3a9fe547da58f2530ec874e978fce0b5101b507")}, {50000, newHashFromStr("69dc37eb029b68f075a5012dcc0419c127672adb4f3a32882b2b3e71d07a20a6")}, {80000, newHashFromStr("4fcb7c02f676a300503f49c764a89955a8f920b46a8cbecb4867182ecdb2e90a")}, {120000, newHashFromStr("bd9d26924f05f6daa7f0155f32828ec89e8e29cee9e7121b026a7a3552ac6131")}, {161500, newHashFromStr("dbe89880474f4bb4f75c227c77ba1cdc024991123b28b8418dbbf7798471ff43")}, {179620, newHashFromStr("2ad9c65c990ac00426d18e446e0fd7be2ffa69e9a7dcb28358a50b2b78b9f709")}, {240000, newHashFromStr("7140d1c4b4c2157ca217ee7636f24c9c73db39c4590c4e6eab2e3ea1555088aa")}, {383640, newHashFromStr("2b6809f094a9215bafc65eb3f110a35127a34be94b7d0590a096c3f126c6f364")}, {409004, newHashFromStr("487518d663d9f1fa08611d9395ad74d982b667fbdc0e77e9cf39b4f1355908a3")}, {456000, newHashFromStr("bf34f71cc6366cd487930d06be22f897e34ca6a40501ac7d401be32456372004")}, {638902, newHashFromStr("15238656e8ec63d28de29a8c75fcf3a5819afc953dcd9cc45cecc53baec74f38")}, {721000, newHashFromStr("198a7b4de1df9478e2463bd99d75b714eab235a2e63e741641dc8a759a9840e5")}, }, RuleChangeActivationThreshold: 6048, MinerConfirmationWindow: 8064, Deployments: [DefinedDeployments]chaincfg.ConsensusDeployment{ DeploymentTestDummy: { BitNumber: 28, StartTime: 1199145601, ExpireTime: 1230767999, }, DeploymentCSV: { BitNumber: 0, StartTime: 1485561600, ExpireTime: 1517356801, }, DeploymentSegwit: { BitNumber: 1, StartTime: 1485561600, ExpireTime: 1517356801, }, }, RelayNonStdTxs: false, Bech32HRPSegwit: "ltc", PubKeyHashAddrID: 0x30, ScriptHashAddrID: 0x32, PrivateKeyID: 0xB0, WitnessPubKeyHashAddrID: 0x06, WitnessScriptHashAddrID: 0x0A, HDPrivateKeyID: [4]byte{0x01, 0x9d, 0x9c, 0xfe}, HDPublicKeyID: [4]byte{0x01, 0x9d, 0xa4, 0x62}, HDCoinType: 2, } )
View Source
var LtcTestNet4Params = chaincfg.Params{ Name: "testnet4", Net: LtcTestNet4, DefaultPort: "19335", DNSSeeds: []chaincfg.DNSSeed{ {"testnet-seed.litecointools.com", false}, {"seed-b.litecoin.loshan.co.uk", true}, {"dnsseed-testnet.thrasher.io", true}, }, GenesisBlock: &testNet4GenesisBlock, GenesisHash: &testNet4GenesisHash, PowLimit: testNet4PowLimit, PowLimitBits: 504365055, BIP0034Height: 76, BIP0065Height: 76, BIP0066Height: 76, CoinbaseMaturity: 100, SubsidyReductionInterval: 840000, TargetTimespan: (time.Hour * 24 * 3) + (time.Hour * 12), TargetTimePerBlock: (time.Minute * 2) + (time.Second * 30), RetargetAdjustmentFactor: 4, ReduceMinDifficulty: true, MinDiffReductionTime: time.Minute * 5, GenerateSupported: false, Checkpoints: []chaincfg.Checkpoint{ {26115, newHashFromStr("817d5b509e91ab5e439652eee2f59271bbc7ba85021d720cdb6da6565b43c14f")}, {43928, newHashFromStr("7d86614c153f5ef6ad878483118ae523e248cd0dd0345330cb148e812493cbb4")}, {69296, newHashFromStr("66c2f58da3cfd282093b55eb09c1f5287d7a18801a8ff441830e67e8771010df")}, {99949, newHashFromStr("8dd471cb5aecf5ead91e7e4b1e932c79a0763060f8d93671b6801d115bfc6cde")}, {159256, newHashFromStr("ab5b0b9968842f5414804591119d6db829af606864b1959a25d6f5c114afb2b7")}, }, RuleChangeActivationThreshold: 1512, MinerConfirmationWindow: 2016, Deployments: [DefinedDeployments]chaincfg.ConsensusDeployment{ DeploymentTestDummy: { BitNumber: 28, StartTime: 1199145601, ExpireTime: 1230767999, }, DeploymentCSV: { BitNumber: 0, StartTime: 1483228800, ExpireTime: 1517356801, }, DeploymentSegwit: { BitNumber: 1, StartTime: 1483228800, ExpireTime: 1517356801, }, }, RelayNonStdTxs: true, Bech32HRPSegwit: "tltc", PubKeyHashAddrID: 0x6f, ScriptHashAddrID: 0x3a, WitnessPubKeyHashAddrID: 0x52, WitnessScriptHashAddrID: 0x31, PrivateKeyID: 0xef, HDPrivateKeyID: [4]byte{0x04, 0x36, 0xef, 0x7d}, HDPublicKeyID: [4]byte{0x04, 0x36, 0xf6, 0xe1}, HDCoinType: 1, }
LtcTestNet4Params defines the network parameters for the test Litecoin network (version 4). Not to be confused with the regression test network, this network is sometimes simply called "testnet".
Functions ¶
This section is empty.
Types ¶
type ConsensusDeployment ¶
type ConsensusDeployment struct { // BitNumber defines the specific bit number within the block version // this particular soft-fork deployment refers to. BitNumber uint8 // StartTime is the median block time after which voting on the // deployment starts. StartTime uint64 // ExpireTime is the median block time after which the attempted // deployment expires. ExpireTime uint64 }
ConsensusDeployment defines details related to a specific consensus rule change that is voted in. This is part of BIP0009.
Click to show internal directories.
Click to hide internal directories.