aboutsummaryrefslogtreecommitdiff
path: root/src/test/fuzz/integer.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Merge #18413: script: prevent UB when computing abs value for num opcode ↵fanquake2020-05-021-5/+1
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | serialize 2748e8793267126c5b40621d75d1930e358f057e script: prevent UB when computing abs value for num opcode serialize (pierrenn) Pull request description: This was reported by practicalswift here #18046 It seems that the original author of the line used a reference to glibc `abs`: https://github.com/lattera/glibc/blob/master/stdlib/abs.c However depending on some implementation details this can be undefined behavior for unusual values. A detailed explanation of the UB is provided here : https://stackoverflow.com/questions/17313579/is-there-a-safe-way-to-get-the-unsigned-absolute-value-of-a-signed-integer-with (by [Billy O'Neal](https://twitter.com/malwareminigun)) Simple relevant godbolt example : https://godbolt.org/z/yRwtCG Thanks! ACKs for top commit: sipa: ACK 2748e8793267126c5b40621d75d1930e358f057e MarcoFalke: ACK 2748e8793267126c5b40621d75d1930e358f057e, only checked that the bitcoind binary does not change with clang -O2 🎓 practicalswift: ACK 2748e8793267126c5b40621d75d1930e358f057e Tree-SHA512: 539a34c636c2674c66cb6e707d9d0dfdce63f59b5525610ed88da10c9a8d59d81466b111ad63b850660cef3750d732fc7755530c81a2d61f396be0707cd86dec
| * script: prevent UB when computing abs value for num opcode serializepierrenn2020-04-091-5/+1
| |
* | tests: Add fuzzing coverage for CHECK_NONFATAL(...)practicalswift2020-04-261-3/+8
| |
* | scripted-diff: Bump copyright headersMarcoFalke2020-04-161-1/+1
| | | | | | | | | | | | -BEGIN VERIFY SCRIPT- ./contrib/devtools/copyright_header.py update ./ -END VERIFY SCRIPT-
* | tests: Add coverage of {,Incremental}DynamicUsage(const std::set<X, Y>& s) ↵practicalswift2020-04-081-0/+7
| | | | | | | | to existing fuzzer
* | tests: Add coverage of GetVirtualTransactionSize(...) to existing fuzzerpracticalswift2020-04-081-2/+7
|/
* fuzz: Add CScriptNum::getint coverageMarcoFalke2020-04-031-0/+12
|
* util: Replace i64tostr with ToStringMarcoFalke2020-03-271-1/+2
|
* util: Remove unused itostrMarcoFalke2020-03-271-1/+0
|
* tests: Add integer serialization/deserialization fuzzing harnesspracticalswift2020-03-241-0/+40
|
* tests: Add fuzzing harness for count_seconds(...)practicalswift2020-03-151-0/+4
|
* tests: Fuzz HasAllDesirableServiceFlags(...) and MayHaveUsefulAddressDB(...)practicalswift2020-03-111-0/+7
|
* tests: Fuzz additional functions in the integer fuzzing harnesspracticalswift2020-03-071-0/+17
|
* Merge #17996: tests: Add fuzzing harness for serialization/deserialization ↵MarcoFalke2020-03-051-0/+67
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | of floating-points and integrals 9ff41f64198e8ddb969544fc1a5328763f1fa183 tests: Add float to FUZZERS_MISSING_CORPORA (temporarily) (practicalswift) 8f6fb0a85ae6399c8fb4f205ad35c319c42294f1 tests: Add serialization/deserialization fuzzing for integral types (practicalswift) 3c82b92d2e01e409cc46261bffcf3643102f0b94 tests: Add fuzzing harness for functions taking floating-point types as input (practicalswift) c2bd5888607d283a229c9361747a93c83dfea0de Add missing includes (practicalswift) Pull request description: Add simple fuzzing harness for functions with floating-point parameters (such as `ser_double_to_uint64(double)`, etc.). Add serialization/deserialization fuzzing for integral types. Add missing includes. To test this PR: ``` $ make distclean $ ./autogen.sh $ CC=clang CXX=clang++ ./configure --enable-fuzz \ --with-sanitizers=address,fuzzer,undefined $ make $ src/test/fuzz/float … ``` Top commit has no ACKs. Tree-SHA512: 9b5a0c4838ad18d715c7398e557d2a6d0fcc03aa842f76d7a8ed716170a28f17f249eaede4256998aa3417afe2935e0ffdfaa883727d71ae2d2d18a41ced24b5
| * tests: Add serialization/deserialization fuzzing for integral typespracticalswift2020-03-051-0/+67
| |
* | tests: Add amount compression/decompression fuzzing to existing fuzzing ↵practicalswift2020-01-221-1/+9
|/ | | | harness: test compression round-trip
* tests: Add fuzzing harness for various functions consuming only integralspracticalswift2019-12-061-0/+127