Remove qpdf_read_memory_fuzzer

This commit is contained in:
Jay Berkenbilt 2019-06-18 08:40:18 -04:00
parent 127859a6d3
commit 616ae15595
3 changed files with 6 additions and 18 deletions

View File

@ -1,3 +1,8 @@
2019-06-18 Jay Berkenbilt <ejb@ql.org>
* Remove previously submitted qpdf_read_memory_fuzzer as it is a
small subset of qpdf_fuzzer.
2019-06-15 Jay Berkenbilt <ejb@ql.org>
* Update CI (Azure Pipelines) to run tests with some sanitizers.

View File

@ -1,9 +1,7 @@
# This directory contains support for Google's oss-fuzz project. See
# https://github.com/google/oss-fuzz/tree/master/projects/qpdf
FUZZERS = \
qpdf_fuzzer \
qpdf_read_memory_fuzzer
FUZZERS = qpdf_fuzzer
DEFAULT_FUZZ_RUNNER := standalone_fuzz_target_runner
OBJ_DEFAULT_FUZZ := fuzz/$(OUTPUT_DIR)/$(DEFAULT_FUZZ_RUNNER).$(OBJ)

View File

@ -1,15 +0,0 @@
#include "qpdf/qpdf-c.h"
#include <algorithm>
#include <cstddef>
#include <cstdlib>
extern "C" int LLVMFuzzerTestOneInput(const unsigned char* data, size_t size) {
const size_t kMaxSize = 64 * 1024; // 64 KiB
size = std::min(size, kMaxSize);
_qpdf_data* qpdf = qpdf_init();
const char* buffer = reinterpret_cast<const char*>(data);
qpdf_read_memory(qpdf, /*description=*/"", buffer, size, /*password=*/"");
qpdf_cleanup(&qpdf);
return 0;
}