mirror of
https://github.com/bitcoin/bitcoin.git
synced 2026-06-11 15:19:19 +02:00
test: add fuzz harness for CDBWrapper
Introduces a libFuzzer harness that exercises CDBWrapper operations against a std::map oracle, with a DeterministicEnv that captures LevelDB background compaction for single-threaded determinism. A sibling dbwrapper_threaded target uses a bare memenv so LevelDB's real background thread runs, exercising force_compact and threaded compaction paths that the deterministic variant cannot reach. Adds an implicit-integer-sign-change suppression for BytewiseComparatorImpl::FindShortSuccessor (leveldb/util/comparator.cc:58) to the test ubsan suppressions list. LevelDB's bytewise comparator implicitly converts a signed `char` byte to `uint8_t` there. The path is only reached when compaction picks an SST boundary key, so it requires a small enough max_file_size for compaction to fire during the fuzz run. Co-authored-by: l0rinc <pap.lorinc@gmail.com>
This commit is contained in:
@@ -19,6 +19,7 @@ implicit-integer-sign-change:*/include/c++/
|
||||
implicit-integer-sign-change:*/new_allocator.h
|
||||
implicit-integer-sign-change:*/qarraydata.h
|
||||
implicit-integer-sign-change:crc32c/
|
||||
implicit-integer-sign-change:BytewiseComparatorImpl::FindShortSuccessor
|
||||
implicit-integer-sign-change:minisketch/
|
||||
implicit-integer-sign-change:secp256k1/
|
||||
implicit-signed-integer-truncation:*/include/c++/
|
||||
|
||||
Reference in New Issue
Block a user