[26.x] backports and final changes for v26.1rc2 #29509

pull glozow wants to merge 16 commits into bitcoin:26.x from glozow:2024-02-26-backports changing 19 files +525 −64
  1. glozow commented at 10:25 pm on February 28, 2024: member

    Includes:

    Also does:

    • update to release notes
    • bump to rc2
    • manpages
    • (no changes to bitcoin.conf)
  2. test: Drop `x` modifier in `fsbridge::fopen` call for mingw builds
    The MinGW-w64 toolchain links executables to the old msvcrt C Runtime
    Library that does not support the `x` modifier for the _wfopen()
    function.
    
    Github-Pull: #29357
    Rebased-From: d2fe90571e98e02617682561ea82acb1e2647827
    4ac0eb543d
  3. glozow added the label Backport on Feb 28, 2024
  4. DrahtBot commented at 10:25 pm on February 28, 2024: contributor

    The following sections might be updated with supplementary metadata relevant to reviewers and maintainers.

    Code Coverage

    For detailed information about the code coverage, see the test coverage report.

    Reviews

    See the guideline for information on the review process.

    Type Reviewers
    ACK achow101
    Stale ACK hebasto

    If your review is incorrectly listed, please react with 👎 to this comment and the bot will ignore it on the next update.

  5. fanquake added this to the milestone 26.1 on Feb 28, 2024
  6. achow101 commented at 0:01 am on February 29, 2024: member
    I think #29510 should be backported too, once it’s merged.
  7. DrahtBot added the label CI failed on Feb 29, 2024
  8. hebasto approved
  9. hebasto commented at 10:24 am on February 29, 2024: member
    ACK 4ac0eb543d028379bb2b86ab08bbbb2f9f48d5b1.
  10. [validation] Isolate merkle root checks
    Github-Pull: #29412
    Rebased-From: 95bddb930aa72edd40fdff52cf447202995b0dce
    97a1d0a459
  11. [refactor] Cleanup merkle root checks
    Github-Pull: #29412
    Rebased-From: e7669e1343aec4298fd30d539847963e6fa5619c
    076c67c3aa
  12. [validation] Introduce IsBlockMutated
    Github-Pull: #29412
    Rebased-From: 66abce1d98115e41f394bc4f4f52341960ddc839
    aff368fa81
  13. [validation] Merkle root malleation should be caught by IsBlockMutated
    Github-Pull: #29412
    Rebased-From: 2d8495e0800f5332748cd50eaad801ff77671bba
    50c0b61a9d
  14. [net processing] Don't process mutated blocks
    We preemptively perform a block mutation check before further processing
    a block message (similar to early sanity checks on other messsage
    types). The main reasons for this change are as follows:
    
    - `CBlock::GetHash()` is a foot-gun without a prior mutation check, as
      the hash returned only commits to the header but not to the actual
      transactions (`CBlock::vtx`) contained in the block.
    - We have observed attacks that abused mutated blocks in the past, which
      could have been prevented by simply not processing mutated blocks
      (e.g. https://github.com/bitcoin/bitcoin/pull/27608).
    
    Github-Pull: #29412
    Rebased-From: 49257c0304828a185c273fcb99742c54bbef0c8e
    24736350e9
  15. [test] Add regression test for #27608
    Github-Pull: #29412
    Rebased-From: 5bf4f5ba32da4627f152b54d266df9b2aa930457
    0c5c5962cb
  16. [validation] Cache merkle root and witness commitment checks
    Slight performance improvement by avoiding duplicate work.
    
    Github-Pull: #29412
    Rebased-From: 1ec6bbeb8d27d31647d1433ccb87b362f6d81f90
    8141498f3a
  17. [test] IsBlockMutated unit tests
    Github-Pull: #29412
    Rebased-From: d8087adc7ebd4ea05dd3843e5a92e8115fd7bbcc
    0535c253fe
  18. p2p: Don't consider blocks mutated if they don't connect to known prev block
    Github-Pull: #29524
    Rebased-From: a1fbde0ef7cf6c94d4a5181f8ceb327096713160
    b5419ce6b6
  19. wallet: Avoid updating `ReserveDestination::nIndex` when `GetReservedDestination` fails
    Github-Pull: #29510
    Rebased-From: 367bb7a80cc71130995672c853d4a6e0134721d6
    7c82b2758c
  20. test: make sure keypool sizes do not change on `getrawchangeaddress`/`getnewaddress` failures
    Github-Pull: #29510
    Rebased-From: e073f1dfda7a2a2cb2be9fe2a1d576f122596021
    40c56a4d13
  21. glozow commented at 10:58 am on March 5, 2024: member

    Noting changes for #29412:

    • LogDebug to LogPrint
    • GetSerializeSize(TX_NO_WITNESS(tx)) to GetSerializeSize(tx, PROTOCOL_VERSION | SERIALIZE_TRANSACTION_NO_WITNESS)
    • Didn’t add 1ed2c9829700054526156297552bb47230406098, modified validation_tests to convert transaction hash data as needed. (26.x doesn’t have transaction_identifier.h)
  22. fanquake commented at 12:45 pm on March 6, 2024: member
    Can you also add #29529.
  23. fuzz: restrict fopencookie usage to Linux & FreeBSD
    Should fix the GCC compilation portion of #29517:
    https://github.com/bitcoin/bitcoin/issues/29517#issuecomment-1973573314.
    
    See also:
    https://www.gnu.org/software/gnulib/manual/html_node/fopencookie.html
    but note that FreeBSD has supported this function since 11.x.
    
    Github-Pull: #29529
    Rebased-From: 312f3381a2d3a7afb7c81b4662214d4d67b4e84a
    fce992b38e
  24. update release notes 26.1 b6d006d2a2
  25. glozow force-pushed on Mar 7, 2024
  26. [build] bump version to v26.1rc2 bd715bfb30
  27. [doc] update manual pages for v26.1rc2 c68d4d0ac5
  28. glozow renamed this:
    [26.x] even more backports
    [26.x] backports and final changes for v26.1rc2
    on Mar 7, 2024
  29. glozow commented at 10:53 am on March 7, 2024: member
    Added #29529. Also updated release notes and added final changes for rc2.
  30. glozow requested review from hebasto on Mar 8, 2024
  31. achow101 commented at 5:36 pm on March 8, 2024: member
    ACK c68d4d0ac5b8537ba5e1c0c512b807768e1c5c1f
  32. glozow merged this on Mar 11, 2024
  33. glozow closed this on Mar 11, 2024

  34. glozow deleted the branch on Mar 21, 2024

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: 2024-12-26 12:12 UTC

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