Skip to content

Conversation

practicalswift
Copy link
Contributor

Pass fuzzing inputs as constant references.

Split out from #17009 as suggested by MarcoFalke in #17009 (comment).

@maflcko
Copy link
Member

maflcko commented Oct 7, 2019

ACK ffa2221

This is just stylistic refactoring, because a copy is created either way. Though, it seems fine to do this change, even if we were to switch to a different class (like https://cs.chromium.org/chromium/src/third_party/libFuzzer/src/utils/FuzzedDataProvider.h?rcl=b9f51dc8c98065df0c8da13c051046f5bab833db), the input data remains read-only.

maflcko pushed a commit that referenced this pull request Oct 7, 2019
ffa2221 tests: Pass fuzzing inputs as constant references (practicalswift)

Pull request description:

  Pass fuzzing inputs as constant references.

  Split out from #17009 as suggested by MarcoFalke in #17009 (comment).

ACKs for top commit:
  MarcoFalke:
    ACK ffa2221

Tree-SHA512: c1e3d6658a0b45cece2ed7e7c2ba1b78cdb71a03767231de7e5c212575117a4e2b70079265c745963480d7fcd4d9706561a2325b8c993b94eec33268ad4b293c
@maflcko maflcko merged commit ffa2221 into bitcoin:master Oct 7, 2019
sidhujag pushed a commit to syscoin/syscoin that referenced this pull request Oct 7, 2019
ffa2221 tests: Pass fuzzing inputs as constant references (practicalswift)

Pull request description:

  Pass fuzzing inputs as constant references.

  Split out from bitcoin#17009 as suggested by MarcoFalke in bitcoin#17009 (comment).

ACKs for top commit:
  MarcoFalke:
    ACK ffa2221

Tree-SHA512: c1e3d6658a0b45cece2ed7e7c2ba1b78cdb71a03767231de7e5c212575117a4e2b70079265c745963480d7fcd4d9706561a2325b8c993b94eec33268ad4b293c
deadalnix pushed a commit to Bitcoin-ABC/bitcoin-abc that referenced this pull request Jun 26, 2020
Summary:
ffa22212560c9e7a8692cb8982d9b3b507ee9af1 tests: Pass fuzzing inputs as constant references (practicalswift)

Pull request description:

  Pass fuzzing inputs as constant references.

  Split out from #17009 as suggested by MarcoFalke in bitcoin/bitcoin#17009 (comment).

---

Backport of Core [[bitcoin/bitcoin#17069 | PR17069]]

Test Plan:
  export CC=clang CXX=clang++
  ../configure --enable-fuzz --with-sanitizers=fuzzer,address \
    --disable-wallet \
    --disable-bench \
    --with-utils=no \
    --with-daemon=no \
    --with-libs=no \
    --with-gui=no \
    --with-seeder=no
  make
  mkdir -p test/fuzz
  cp ../test/fuzz/test_runner.py test/fuzz/
  ./test/fuzz/test_runner.py -l DEBUG <path_to_corpus>

  cmake -GNinja .. -DENABLE_SANITIZERS="address;fuzzer" -DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++
  ninja bitcoin-fuzzers link-fuzz-test_runner.py
  ./test/fuzz/test_runner.py -l DEBUG <path_to_corpus>

Reviewers: #bitcoin_abc, Fabien

Reviewed By: #bitcoin_abc, Fabien

Differential Revision: https://reviews.bitcoinabc.org/D6740
@practicalswift practicalswift deleted the readonly-fuzzer-inputs branch April 10, 2021 19:38
kwvg added a commit to kwvg/dash that referenced this pull request Aug 2, 2021
kwvg added a commit to kwvg/dash that referenced this pull request Aug 5, 2021
kwvg added a commit to kwvg/dash that referenced this pull request Aug 5, 2021
kwvg added a commit to kwvg/dash that referenced this pull request Aug 5, 2021
PastaPastaPasta pushed a commit to PastaPastaPasta/dash that referenced this pull request Aug 6, 2021
kwvg added a commit to kwvg/dash that referenced this pull request Aug 8, 2021
kwvg added a commit to kwvg/dash that referenced this pull request Aug 11, 2021
5tefan pushed a commit to 5tefan/dash that referenced this pull request Aug 12, 2021
@bitcoin bitcoin locked as resolved and limited conversation to collaborators Aug 18, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants