mirror of
https://github.com/qpdf/qpdf.git
synced 2025-01-02 22:50:20 +00:00
Remove qpdf_read_memory_fuzzer
This commit is contained in:
parent
127859a6d3
commit
616ae15595
@ -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>
|
2019-06-15 Jay Berkenbilt <ejb@ql.org>
|
||||||
|
|
||||||
* Update CI (Azure Pipelines) to run tests with some sanitizers.
|
* Update CI (Azure Pipelines) to run tests with some sanitizers.
|
||||||
|
@ -1,9 +1,7 @@
|
|||||||
# This directory contains support for Google's oss-fuzz project. See
|
# This directory contains support for Google's oss-fuzz project. See
|
||||||
# https://github.com/google/oss-fuzz/tree/master/projects/qpdf
|
# https://github.com/google/oss-fuzz/tree/master/projects/qpdf
|
||||||
|
|
||||||
FUZZERS = \
|
FUZZERS = qpdf_fuzzer
|
||||||
qpdf_fuzzer \
|
|
||||||
qpdf_read_memory_fuzzer
|
|
||||||
|
|
||||||
DEFAULT_FUZZ_RUNNER := standalone_fuzz_target_runner
|
DEFAULT_FUZZ_RUNNER := standalone_fuzz_target_runner
|
||||||
OBJ_DEFAULT_FUZZ := fuzz/$(OUTPUT_DIR)/$(DEFAULT_FUZZ_RUNNER).$(OBJ)
|
OBJ_DEFAULT_FUZZ := fuzz/$(OUTPUT_DIR)/$(DEFAULT_FUZZ_RUNNER).$(OBJ)
|
||||||
|
@ -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;
|
|
||||||
}
|
|
Loading…
Reference in New Issue
Block a user