diff --git a/Meta/Lagom/Fuzzers/CMakeLists.txt b/Meta/Lagom/Fuzzers/CMakeLists.txt index 4a7d4a9654..4b88ba08a9 100644 --- a/Meta/Lagom/Fuzzers/CMakeLists.txt +++ b/Meta/Lagom/Fuzzers/CMakeLists.txt @@ -32,6 +32,7 @@ add_simple_fuzzer(FuzzPNGLoader) add_simple_fuzzer(FuzzPBMLoader) add_simple_fuzzer(FuzzPGMLoader) add_simple_fuzzer(FuzzPPMLoader) +add_simple_fuzzer(FuzzQuotedPrintableParser) add_simple_fuzzer(FuzzHebrewDecoder) add_simple_fuzzer(FuzzHttpRequest) add_simple_fuzzer(FuzzIMAPParser) diff --git a/Meta/Lagom/Fuzzers/FuzzQuotedPrintableParser.cpp b/Meta/Lagom/Fuzzers/FuzzQuotedPrintableParser.cpp new file mode 100644 index 0000000000..ad85fcb9de --- /dev/null +++ b/Meta/Lagom/Fuzzers/FuzzQuotedPrintableParser.cpp @@ -0,0 +1,16 @@ +/* + * Copyright (c) 2021, Luke Wilde + * + * SPDX-License-Identifier: BSD-2-Clause + */ + +#include +#include +#include + +extern "C" int LLVMFuzzerTestOneInput(uint8_t const* data, size_t size) +{ + auto quoted_printable_string = StringView(static_cast(data), size); + IMAP::decode_quoted_printable(quoted_printable_string); + return 0; +}