Commit Graph

5338 Commits

Author SHA1 Message Date
Varun Khaneja afb9e09ae2
Add '-fno-sanitize=enum' to CXXFLAGS for unrar (#5238) 2021-02-22 12:27:33 -08:00
jonathanmetzman 1b0115eefd
Fix spuriously failing test (#5218) 2021-02-22 10:55:15 -08:00
Catena cyber 90164f397e
Fixes go coverage build with go 1.16 (#5237) 2021-02-22 09:06:53 -08:00
van Hauser b5de0307a7
Fixes for afl++ (#5235)
* output afl++ setup

* update commit id
2021-02-22 07:41:49 -08:00
DavidKorczynski 6fe9d7f01d
libzmq: enable afl and simplify project.yaml. (#5147) 2021-02-21 16:07:31 -08:00
DavidKorczynski a7affd0e27
zeek: enable afl and simplify project.yaml (#5148)
* zeek: enable afl.

* Added whitespace to gtrigger ci.
2021-02-21 16:07:21 -08:00
DavidKorczynski 9c92302ad5
dropbear: enable afl and simplify project yaml (#5150)
* dropbear: enable afl and simplify project yaml.

* dropbear: fixup project yaml and copyrights.
2021-02-21 16:07:11 -08:00
DavidKorczynski 2b4a1cdea5
postgresql: fix fuzzers + build, and enable AFL. (#5164)
* postgresql: fix fuzzers and build, and enable AFL.

* postgresql: fix up main repo.

* postgresql: fix up the patch for postgresql.
2021-02-21 16:07:01 -08:00
DavidKorczynski b793a49934
tesseract-ocr: enable afl and simplify project.yaml. (#5152) 2021-02-21 16:06:49 -08:00
DavidKorczynski ab55c8eeef
infra: update the timeout of AFL (#5223)
* Updated the timeout for AFL.

* Updated the AFL timeout.
2021-02-21 16:06:29 -08:00
Catena cyber 60e9a661f9
Go 1.16 build fix with right parentheses (#5228)
* go: right bash condition for changing directory

* go-json-iterator: uses git clone

So as to copy fuzz target in right directory

* go: uses tags when running go list

* go-redis: uses git clone and builds local fuzz target

* cascadia: uses git clone instead of go get
2021-02-21 07:40:36 -08:00
Todd C. Miller 3a5a485b72
Use sudo's new install-fuzzer Makefile target to install fuzzers. (#5224)
This also builds and installs the seed corpus zip files.
The --disable-leaks option is implied by --enable-sanitizer and
--enable-fuzzer so it is no longer needed either.
2021-02-19 21:18:51 -08:00
jonathanmetzman 28b35e36fe
[CIFuzz] Support languages non-C++ projects (e.g. Python projects) (#5222)
Allow use of non-C++ projects by specifying the language in the workflow file.
Fixes #5195
2021-02-19 11:54:15 -08:00
Sergey Bronnikov bf0720d322
[tarantool] initial integration (#4723) (#4723) 2021-02-19 11:51:46 -08:00
Catena cyber 18500c17d7
golang: compatibility with go 1.16 modules (#5221) 2021-02-19 10:03:22 -08:00
Fabian Meumertzheim 12d7371cf6
[java-example] Don't assume that fuzzer is run from its directory (#5219)
The same speculative fix as in #5217.

The current working directory "." should have no reason to be in the
classpath if it is not equal to "$this_dir", hence it is removed.
2021-02-19 06:29:46 -08:00
Fabian Meumertzheim 9ca45293b3
[jazzer] Add java-example project (#5216)
The java-example project does not pull in any external dependencies, but
rather consists of three basic Java fuzzers that hit a synthetic bug
after a few seconds. The project can be used to verify that ClusterFuzz
correctly handles JVM fuzz targets.

* ExampleFuzzer fails with an assertion.
* ExampleValueProfileFuzzer fails with an exception after a few seconds,
  but only if running in value profile mode.
* ExampleFuzzerNative fails with an ASan report.
2021-02-18 17:53:50 -08:00
van Hauser 4bb61df790
Final afl++ integration (#5191)
* final afl++ integration

* remove afl++ cmplog tests

* update afl++ commit id

* support rebuild

* llvm 13 workaround

* apply fix for llvm 13

* fix nits

* Fix nits.

* Fix name nit.

* update commit id

* update commit id

* update commit id to stable

Co-authored-by: Abhishek Arya <inferno@chromium.org>
2021-02-18 12:55:07 -08:00
Andrea Fioraldi f682792936
[openjpeg] Release cmake build type (#5209)
Seems that some bugs in openjpeg can be triggered only in release mode.
More specifically, I was trying to reproduce https://github.com/uclouvain/openjpeg/issues/1228 using the OSS-Fuzz harness and I failed.
I figured out that the bug is indeed reachable by the harness, but can be uncovered only in Release mode, otherwise, an assertion error blocks it.
I guess that they use assertions only in Debug mode (WTF) and remove them in Release.
So, IMO openjpeg should be fuzzed in Release mode as the configuration used in production is the one relevant for security.
2021-02-18 10:17:18 -08:00
jonathanmetzman e93f222966
[CIFuzz] Fix handling of sanitizer artifacts (#5182)
Fixes #5175
1. Put sanitizer in artifact name.
2. Fix parsing of non-ASAN stacks.
2021-02-18 09:57:34 -08:00
jonathanmetzman d7164ef352
[infra] Remove unneeded binaries, docs from CMake install (#5161)
This should reduce the image layer size from 127 MB to 57 MB
2021-02-18 09:49:41 -08:00
Daiki Ueno 98e9d24579
New project: p11-kit (#5136)
Co-authored-by: David Cook <divergentdave@gmail.com>
2021-02-18 09:06:22 -08:00
jonathanmetzman 346370af46
[json-sanitizer][jazzer] Don't assume that fuzzer is run from its directory (#5217)
This is a speculative fix for an issue we've seen where the class
fails to load.
A simpler approach I did not use is cd-ing into $this_dir. I didn't
use this approach because it will break things if relative paths
are passed to the fuzzer by ClusterFuzz.

The other reason that I think could be responsible for the missing
class issues is not unpacking the zipfile fully.
2021-02-18 08:25:21 -08:00
jonathanmetzman fa46369f1e
[CIFuzz] Note which languages are supported (#5208)
Related #5195
2021-02-18 07:42:40 -08:00
DavidKorczynski 27a234f297
lua: fix auto_ccs email (#5215) 2021-02-18 07:07:12 -08:00
Google AutoFuzz Team 22fbe14bde
Change the primary_contact for bs4 (#5212)
As requested privately by Leonard
2021-02-18 07:06:54 -08:00
Amit Patankar 4f3158373d
Remove manual denylisting in tensorflow (#5210)
* Remove manual denylisting in tensorflow

Remove manual denylisting of fuzzing targets using bazel query via tags.

* Add a space in the bazel query.

* Update the tag we should denylist.

* Update the comment.
2021-02-17 18:30:47 -08:00
Fabian Meumertzheim 587a0bde3f
[jazzer][json-sanitizer] Add json-sanitizer as the first JVM project (#5186)
json-sanitizer uses Maven and has no native dependencies.

The build file is loosely divided into two parts. The first part is
project-specific, the second one can serve as a template for JVM fuzz
targets without native dependencies.

The following three fuzz targets are added to OSS-Fuzz and can later be
moved into the json-sanitizer tree:

* DenylistFuzzer verifies that the output of json-sanitizer never
  contains certain substrings that can lead to HTML or XML injections.
* IdempotenceFuzzer verifies that json-sanitizer is idempotent.
* ValidJsonFuzzer verifies that the output of json-sanitizer is valid
  JSON by passing it into gson.
2021-02-16 10:13:29 -08:00
Fabian Meumertzheim 481280c650
[jazzer] Adapt infra scripting to JVM fuzz targets (#5176)
compile, bad_build_check, and presubmit.py require small tweaks to
support JVM fuzz targets, most of which are similar to those required
for Python. The following additional changes are required:

* Since the Jazzer driver binary already links in libFuzzer, it should
  not be built as a static library.
* It is not clear how to do architecture checks as JVM fuzz targets can
  load their native dependencies dynamically at runtime. For now, the
  check is disabled.
* The Jazzer binaries are moved into $OUT and need to be skipped over in
  find_fuzz_targets.
2021-02-16 07:06:58 -08:00
Fabian Meumertzheim 427f63c93c
Add Jazzer to base-builder and base-runner (#5166)
Jazzer is built from HEAD using Bazel and the clang toolchain provided
by base-clang. While it could be built with OpenJDK 8, which is
available as a package, JVM fuzz targets should not be forced to be
compatible with Java 8. For this reason, the official binary release of
OpenJDK 15 is pulled into both base-builder and base-runner and set as
JAVA_HOME. It is trimmed down in size by removing src.zip and the jmods
directory.

Jazzer consists of the following four components:

* The API (`jazzer_api_deploy.jar`), which is required for fuzz targets
  that use FuzzedDataProvider or custom method hooks, is made available
  in /usr/local/lib in base-builder.
* The driver (`jazzer_driver`), which links in libFuzzer and is reused
  across fuzz targets. Since it is used to run fuzz targets, it is
  included into base-runner.
* The ASanified driver (`jazzer_driver_asan`), which is obtained from
  `jazzer_driver` by linking in ASan.
* The agent (`jazzer_agent_deploy.jar`), which bundles the runtime
  instrumentation agent with the Jazzer API. It is loaded by the driver
  and thus also included into base-runner.

The changes to the infra scripts required by JVM fuzz targets will be
submitted as a separate PR.
2021-02-16 06:56:36 -08:00
jonathanmetzman a98d7f1ca4
[base-runner][NFC] Replace test_one with test_one.py (#5179) 2021-02-16 06:14:53 -08:00
Todd C. Miller 248b4eb797
sudoers: fuzz targets are now integrated into the build system (#5198)
* use configure options to set the compiler/linker flags

 * use make to build the actual fuzz targets
2021-02-15 09:40:12 -08:00
Catena cyber 4540e32368
Use upstream repo for go-sqlite3 project (#5203) 2021-02-15 09:34:54 -08:00
Paul Kehrer 9afe4f5915
add jasper and libxml2 to graphicsmagick container (#5200) 2021-02-15 09:34:35 -08:00
Robert Löhning 198bf3f112
[qt] Have my own copy of afl's dictionaries and testcases (#5201) 2021-02-15 07:22:08 -08:00
Evgeny Vereshchagin ac290e7ed7
[systemd] roll back to meson-0.56.2 (#5199)
Apparently the latest version of meson (0.57.0) somehow broke systemd
OSS-Fuzz builds. Since it was released systemd has been failing to compile
with
```
2021-02-14T21:23:53.3854577Z [481/664] clang++  -o fuzz-compress fuzz-compress.p/src_fuzz_fuzz-compress.c.o -L/usr/lib/clang/12.0.0/lib/linux -Wl,--as-needed -Wl,--allow-shlib-undefined '-Wl,-rpath,$ORIGIN/src/shared' -Wl,-rpath-link,/work/build/src/shared -Wl,--start-group src/shared/libsystemd-shared-247.so -lFuzzingEngine -Wl,--end-group
2021-02-14T21:23:53.3856578Z FAILED: fuzz-compress
2021-02-14T21:23:53.3858714Z clang++  -o fuzz-compress fuzz-compress.p/src_fuzz_fuzz-compress.c.o -L/usr/lib/clang/12.0.0/lib/linux -Wl,--as-needed -Wl,--allow-shlib-undefined '-Wl,-rpath,$ORIGIN/src/shared' -Wl,-rpath-link,/work/build/src/shared -Wl,--start-group src/shared/libsystemd-shared-247.so -lFuzzingEngine -Wl,--end-group
2021-02-14T21:23:53.4160985Z /usr/lib/gcc/x86_64-linux-gnu/5.4.0/../../../libFuzzingEngine.a(FuzzerTracePC.o): In function `size':
2021-02-14T21:23:53.4162332Z /usr/local/bin/../include/c++/v1/set:641: undefined reference to `__asan_report_load8'
2021-02-14T21:23:53.4164959Z /usr/lib/gcc/x86_64-linux-gnu/5.4.0/../../../libFuzzingEngine.a(FuzzerTracePC.o): In function `fuzzer::TracePC::HandleInline8bitCountersInit(unsigned char*, unsigned char*)':
2021-02-14T21:23:53.4166954Z /src/libfuzzer/FuzzerTracePC.cpp:61: undefined reference to `__asan_report_store1'
2021-02-14T21:23:53.4168493Z /src/libfuzzer/FuzzerTracePC.cpp:59: undefined reference to `__asan_report_store1'
2021-02-14T21:23:53.4170699Z /src/libfuzzer/FuzzerTracePC.cpp:59: undefined reference to `__asan_report_store1'
2021-02-14T21:23:53.4172114Z /src/libfuzzer/FuzzerTracePC.cpp:63: undefined reference to `__asan_report_store1'
2021-02-14T21:23:53.4173550Z /src/libfuzzer/FuzzerTracePC.cpp:63: undefined reference to `__asan_report_store1'
2021-02-14T21:23:53.4174876Z /src/libfuzzer/FuzzerTracePC.cpp:54: undefined reference to `__asan_handle_no_return'
2021-02-14T21:23:53.4176322Z /src/libfuzzer/FuzzerTracePC.cpp:64: undefined reference to `__asan_handle_no_return'
2021-02-14T21:23:53.4177521Z /src/libfuzzer/FuzzerTracePC.cpp:65: undefined reference to `__asan_handle_no_return'
2021-02-14T21:23:53.4178936Z /src/libfuzzer/FuzzerTracePC.cpp:66: undefined reference to `__asan_handle_no_return'
2021-02-14T21:23:53.4180439Z /src/libfuzzer/FuzzerTracePC.cpp:67: undefined reference to `__asan_handle_no_return'
2021-02-14T21:23:53.4182667Z /usr/lib/gcc/x86_64-linux-gnu/5.4.0/../../../libFuzzingEngine.a(FuzzerTracePC.o):/src/libfuzzer/FuzzerTracePC.cpp:44: more undefined references to `__asan_handle_no_return' follow
2021-02-14T21:23:53.4185448Z /usr/lib/gcc/x86_64-linux-gnu/5.4.0/../../../libFuzzingEngine.a(FuzzerTracePC.o): In function `fuzzer::TracePC::HandleInline8bitCountersInit(unsigned char*, unsigned char*)':
2021-02-14T21:23:53.4189221Z /src/libfuzzer/FuzzerTracePC.cpp:61: undefined reference to `__asan_report_load8'
2021-02-14T21:23:53.4190419Z /src/libfuzzer/FuzzerTracePC.cpp:61: undefined reference to `__asan_report_store8'
2021-02-14T21:23:53.4191618Z /src/libfuzzer/FuzzerTracePC.cpp:61: undefined reference to `__asan_report_store8'
2021-02-14T21:23:53.4192815Z /src/libfuzzer/FuzzerTracePC.cpp:41: undefined reference to `__asan_report_load8'
2021-02-14T21:23:53.4194218Z /src/libfuzzer/FuzzerTracePC.cpp:46: undefined reference to `__asan_report_store8'
2021-02-14T21:23:53.4195434Z /src/libfuzzer/FuzzerTracePC.cpp:53: undefined reference to `__asan_report_store8'
2021-02-14T21:23:53.4196673Z /src/libfuzzer/FuzzerTracePC.cpp:55: undefined reference to `__asan_report_store8'
2021-02-14T21:23:53.4278293Z /src/libfuzzer/FuzzerTracePC.cpp:61: undefined reference to `__asan_report_store1'
2021-02-14T21:23:53.4279995Z /src/libfuzzer/FuzzerTracePC.cpp:64: undefined reference to `__asan_report_load8'
```
and so on.
2021-02-14 21:04:49 -08:00
jonathanmetzman f3fd5289e9
[NFC][[infra] Remove unnecessary files. (#5177)
These files don't appear to be used anymore.
2021-02-15 11:07:02 +11:00
Alexander Bulekov c12fc5df2c
qemu: Add necessary dependencies for 9p fuzzing (#5197)
In qemu/qemu@fff7111 we added configurations for fuzzing virtio-9p
devices. However, these fuzzers are presently stalled on oss-fuzz,
because the build image doesn't have the necessary libattr, and
libcap-ng libraries. Fix that.

Signed-off-by: Alexander Bulekov <alxndr@bu.edu>
2021-02-13 19:16:55 -08:00
Julien Pivotto e2da2f2675
Prometheus: handle go mod (#5194)
Prometheus has removed the vendor directory, hence we need to force
gomod.

Signed-off-by: Julien Pivotto <roidelapluie@inuits.eu>
2021-02-13 12:02:43 -08:00
Nathan Moinvaziri 0f051b1fbd
Updated zlib-ng project (#5196)
* [zlib-ng] Update project homepage url.

* [zlib-ng] Change linker to use lld due to bug with -fno-semantic-interposition.
2021-02-13 11:59:54 -08:00
wiredfool 38b1953417
[Pillow] Use upstream support for fuzzing build (#5193)
* Don't worry about raqm/fonts for now.

* Current fuzzer doesn't test the font handling
* Upstream (pillow) changes are coming to packaging for raqm/harfbuzz/fribidi

* Use core setup.py options for build linking

explcitly copy libraries in pyinstaller
2021-02-13 11:27:13 -08:00
Alex Gaynor 10083e6746
[graphicsmagick] switch clone to use the new (official) mirror (#5192) 2021-02-12 18:36:09 -08:00
asraa c656631e54
[envoy] Add Yan (#5188)
* Add Yanjun

Signed-off-by: Asra Ali <asraa@google.com>

* add yan

Signed-off-by: Asra Ali <asraa@google.com>
2021-02-12 18:28:01 -08:00
Guido Vranken c65286347d
[cryptofuzz, bignum-fuzzer] Fix AFL++ builds (#5121)
* [cryptofuzz, bignum-fuzzer] Fix AFL++ builds

* [cryptofuzz, bignum-fuzzer] Don't build Golang

Because it's already part of the base image.

* [cryptofuzz, bignum-fuzzer] Retrigger CI
2021-02-12 18:26:00 -08:00
Emmanuel T Odeke 93a898c756
projects/golang: add Emmanuel Odeke as a Go maintainer (#5189) 2021-02-12 18:12:57 -08:00
Frank Denis 27f13eb527
libsodium: don't use the stack for potentially large data (#5190)
* libsodium: don't use the stack for potentially large data

Also check return codes of verification functions, and properly
check the random implementation name.

* Add license headers
2021-02-12 18:10:40 -08:00
DavidKorczynski f26468f501
imageio: initial integration. (#4993)
* imageio: initial integration.

* Updated imageio set up following upstream merges.

* Remove whitespace to trigger CI.
2021-02-12 11:34:07 -08:00
asraa 0c3a9a314a
Add Yanjun (#5187)
Signed-off-by: Asra Ali <asraa@google.com>
2021-02-12 11:33:05 -08:00
Robert Löhning 0eb5d661d2
[qt] Enable i386 again (#5185)
We worked around the __mulodi4 problem in our sources.

This reverts parts of
a23f8971d6 and
008b9bcec6
2021-02-12 11:32:56 -08:00
Frank Denis af1cb300e9
Update contact address for libsodium (#5184)
Access to oss-fuzz requires an exact match, so remove the suffix from the address.

Fixes #5158
2021-02-12 11:32:35 -08:00