fuzz: Avoid timeout in utxo_total_supply #27780

pull maflcko wants to merge 1 commits into bitcoin:master from maflcko:2305-fuzz-timeout-block- changing 1 files +8 −6
  1. maflcko commented at 12:20 PM on May 30, 2023: member

    Looks like for high block counts it may be better to mock the chain, otherwise a high limit will lead to fuzz input bloat and timeouts, see #17860 (comment).

    It can be checked that the fuzz target can still find the CVE, see #17860#pullrequestreview-1410594057 with a diff of:

    diff --git a/src/consensus/tx_check.cpp b/src/consensus/tx_check.cpp
    index f949655909..6f4cfb5f51 100644
    --- a/src/consensus/tx_check.cpp
    +++ b/src/consensus/tx_check.cpp
    @@ -39,8 +39,6 @@ bool CheckTransaction(const CTransaction& tx, TxValidationState& state)
         // the underlying coins database.
         std::set<COutPoint> vInOutPoints;
         for (const auto& txin : tx.vin) {
    -        if (!vInOutPoints.insert(txin.prevout).second)
    -            return state.Invalid(TxValidationResult::TX_CONSENSUS, "bad-txns-inputs-duplicate");
         }
     
         if (tx.IsCoinBase())
    

    Also, fix a nit, see #17860 (review)

  2. fuzz: Avoid timeout in utxo_total_supply fafb4da121
  3. DrahtBot commented at 12:21 PM on May 30, 2023: contributor

    <!--e57a25ab6845829454e8d69fc972939a-->

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

    <!--021abf342d371248e50ceaed478a90ca-->

    Reviews

    See the guideline for information on the review process.

    Type Reviewers
    ACK dergoegge

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

  4. DrahtBot added the label Tests on May 30, 2023
  5. DrahtBot added the label CI failed on May 30, 2023
  6. dergoegge approved
  7. dergoegge commented at 10:10 AM on May 31, 2023: member

    ACK fafb4da121b19ba1b7bd173e25651c64d1982fb4

    Verified that the target still finds the CVE with the patch applied.

  8. fanquake merged this on May 31, 2023
  9. fanquake closed this on May 31, 2023

  10. maflcko deleted the branch on May 31, 2023
  11. sidhujag referenced this in commit 2f06d5bef1 on May 31, 2023
  12. fanquake referenced this in commit 2026301405 on Jun 7, 2023
  13. sidhujag referenced this in commit 21c16ecde3 on Jun 7, 2023
  14. fanquake referenced this in commit 2b3f43b96e on Nov 7, 2023
  15. bitcoin locked this on May 30, 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: 2026-04-20 18:13 UTC

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