Update nMinimumChainWork and defaultAssumeValid. #9779

pull gmaxwell wants to merge 1 commits into bitcoin:master from gmaxwell:update_chainparams changing 1 files +4 −4
  1. gmaxwell commented at 7:33 PM on February 16, 2017: contributor

    No description provided.

  2. Update nMinimumChainWork and defaultAssumeValid. 3f78e460ba
  3. petertodd commented at 7:44 PM on February 16, 2017: contributor
    -----BEGIN PGP SIGNED MESSAGE-----
    Hash: SHA256
    
    utACK 3f78e460ba980d38149ee50ff5dfd75741aad9f2
    
    I believe 0000000000000000000000000000000000000000003f94d1ad391682fe038bf5 to a valid Bitcoin blockchain.
    
    -----BEGIN PGP SIGNATURE-----
    
    iQEcBAEBCAAGBQJYpgDFAAoJECSBQD2l8JH7xgEH/2n5BSrLNBkUrZthOeBYdXa+
    ntmjRzhZaMmlRgCTVnVJR0PN8e3FHEhdeWz+LxAwAlefOTehGqlqjxmaI1VQnqGq
    8a3LLvmZdQ5WD5fN4wGA4wDU1DjRPdG0k8O0W/p9BK/ABMgWiV0wyx1pDXvvn6V/
    I9r8CGNlxUd1VqT9x6T3rxSkEZIPZcYWkVSEfp930348Dz6W7wC9qFKw8+pZ95h0
    YVX/KUgFmq2+5ufuzBCW9irzwC1QrEcp1DO3Lg2myjYqqHJ2Z4wKN+zA2tNUpB+d
    8NxVbqBdyKdD0SbJMYYOV3byJwPBiiejZzFZgp5fu3obEOSS0JA8r+dMxLrxUl4=
    =Jkyt
    -----END PGP SIGNATURE-----
  4. jtimon commented at 8:47 PM on February 16, 2017: contributor

    utACK 3f78e46 for mainnet. For testnet, getblock "0x00000000000128796ee387cf110ccb9d2f36cffaf7f73079c995377c65ac0dcc" tells me that the minimum chain work should be 0x00000000000000000000000000000000000000000000001dcfc5dbe39283e519 instead of 0x00000000000000000000000000000000000000000000001f057509eba81aed91

  5. MarcoFalke commented at 9:17 PM on February 16, 2017: member

    @jtimon The minimum chain work is not required to match the work of the block that is assumed to be valid.

    On Thu, Feb 16, 2017 at 9:47 PM, Jorge Timón notifications@github.com wrote:

    utACK 3f78e46 for mainnet. For testnet, getblock "0x00000000000128796ee387cf110ccb9d2f36cffaf7f73079c995377c65ac0dcc" tells me that the minimum chain work should be 0x00000000000000000000000000000000000000000000001dcfc5dbe39283e519 instead of 0x00000000000000000000000000000000000000000000001f057509eba81aed91

    — You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub, or mute the thread.

  6. jtimon commented at 9:40 PM on February 16, 2017: contributor

    Right, but any reason for not having them matching? EDIT: (specially when you're updating both)

  7. MarcoFalke commented at 9:49 PM on February 16, 2017: member

    I assume the rationale is that testnet is super flaky and it is better to be conservative in what block to assume valid, as it has to be part of a valid chain to have any effect.

    ... In theory you could even "pre-date" the minimum chain work to the minimum chain work you expect at the earliest expected time of release.

  8. fanquake added the label Validation on Feb 17, 2017
  9. gmaxwell commented at 3:01 AM on February 17, 2017: contributor

    @jtimon we only set the assumevalid back because the chain might reorg. But even if the chain reorgs the work will be strictly equal or better. So the chainwork should be set as far forward as possible, but assumevalid may need to be set back to avoid reorgs. (I submitted this PR only after looking to see that there was no visible fork at the bitcoin height there and checked that the block was a couple minutes old at least, otherwise I would have set it one block back-- but I still would have had chainwork at the highest point currently available)

    And yes, as Marco says: we could even set minimum chain work into the future (except for the fact that doing so might confuse testing!)

  10. sipa added this to the milestone 0.14.0 on Feb 17, 2017
  11. laanwj merged this on Feb 17, 2017
  12. laanwj closed this on Feb 17, 2017

  13. laanwj referenced this in commit 3c02b95740 on Feb 17, 2017
  14. MarcoFalke commented at 1:11 AM on February 18, 2017: member
    -----BEGIN PGP SIGNED MESSAGE-----
    Hash: SHA512
    
    Post merge utACK 3f78e460ba980d38149ee50ff5dfd75741aad9f
    -----BEGIN PGP SIGNATURE-----
    
    iQEcBAEBCgAGBQJYp58IAAoJEC1/I3LlD+E3lnMH/RYgl3ENy05TRDGxY8PMVkav
    NVGIQCqgrsffHBQw62bCH66gSxpPnBLf5bOw8ZYhiHaiCMgw3ODx9DTc5GL/2v0V
    m4F/Sr9PW4GQUKzVxTYZTGL+HkwYHplUtPr5yc9++pP8PkXHy/JzVp+4I6IwYAOr
    qXEmGLrbNUfzvaUe9I+0SZYD/H+lFifg3b2FmX/i0hXJZMSqJ9sBQjCyHLGMBqU5
    Do0eHAlp5kxtq0Dc4I+dzF22P5mOZ11xS6AtWUcD0o4MKQOq+1/gYh62jnWBuxHE
    YbtVYaBg0gFZBFNLP8u4vi4LHbFPs6+DLuCQnO3ehXOcgOyOTMooZCFyxyF2Y08=
    =eIBQ
    -----END PGP SIGNATURE-----
    
  15. in src/chainparams.cpp:None in 3f78e460ba
      96 | @@ -97,10 +97,10 @@ class CMainParams : public CChainParams {
      97 |          consensus.vDeployments[Consensus::DEPLOYMENT_SEGWIT].nTimeout = 1510704000; // November 15th, 2017.
      98 |  
      99 |          // The best chain should have at least this much work.
     100 | -        consensus.nMinimumChainWork = uint256S("0x0000000000000000000000000000000000000000002cb971dd56d1c583c20f90");
     101 | +        consensus.nMinimumChainWork = uint256S("0x0000000000000000000000000000000000000000003f94d1ad391682fe038bf5");
     102 |  
     103 |          // By default assume that the signatures in ancestors of this block are valid.
     104 | -        consensus.defaultAssumeValid = uint256S("0x0000000000000000030abc968e1bd635736e880b946085c93152969b9a81a6e2"); //447235
     105 | +        consensus.defaultAssumeValid = uint256S("0x00000000000000000013176bf8d7dfeab4e1db31dc93bc311b436e82ab226b90"); //453354
    


    sdaftuar commented at 7:52 PM on February 27, 2017:

    ACK 0x00000000000000000013176bf8d7dfeab4e1db31dc93bc311b436e82ab226b90

  16. in src/chainparams.cpp:None in 3f78e460ba
     200 | @@ -201,10 +201,10 @@ class CTestNetParams : public CChainParams {
     201 |          consensus.vDeployments[Consensus::DEPLOYMENT_SEGWIT].nTimeout = 1493596800; // May 1st 2017
     202 |  
     203 |          // The best chain should have at least this much work.
     204 | -        consensus.nMinimumChainWork = uint256S("0x0000000000000000000000000000000000000000000000198b4def2baa9338d6");
     205 | +        consensus.nMinimumChainWork = uint256S("0x00000000000000000000000000000000000000000000001f057509eba81aed91");
     206 |  
     207 |          // By default assume that the signatures in ancestors of this block are valid.
     208 | -        consensus.defaultAssumeValid = uint256S("0x000000000871ee6842d3648317ccc8a435eb8cc3c2429aee94faff9ba26b05a0"); //1043841
     209 | +        consensus.defaultAssumeValid = uint256S("0x00000000000128796ee387cf110ccb9d2f36cffaf7f73079c995377c65ac0dcc"); //1079274
    


    sdaftuar commented at 7:52 PM on February 27, 2017:

    ACK 0x00000000000128796ee387cf110ccb9d2f36cffaf7f73079c995377c65ac0dcc

  17. sdaftuar commented at 7:52 PM on February 27, 2017: member

    post-merge ACK

  18. DrahtBot locked this on Sep 8, 2021

Milestone
0.14.0


github-metadata-mirror

This is a metadata mirror of the GitHub repository bitcoin/bitcoin. This site is not affiliated with GitHub. Content is generated from a GitHub metadata backup.
generated: 2026-04-18 21:15 UTC

This site is hosted by @0xB10C
More mirrored repositories can be found on mirror.b10c.me