mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 12:17:44 +00:00
Lagom/Fuzzers: Add fuzzer for the LibCrypto PEM parser
This commit is contained in:
parent
4f5d71b4e8
commit
aa118642aa
2 changed files with 16 additions and 0 deletions
|
@ -28,6 +28,7 @@ add_simple_fuzzer(FuzzGzipDecompression LagomCompress)
|
||||||
add_simple_fuzzer(FuzzICOLoader LagomGfx)
|
add_simple_fuzzer(FuzzICOLoader LagomGfx)
|
||||||
add_simple_fuzzer(FuzzJPGLoader LagomGfx)
|
add_simple_fuzzer(FuzzJPGLoader LagomGfx)
|
||||||
add_simple_fuzzer(FuzzMD5 LagomCrypto)
|
add_simple_fuzzer(FuzzMD5 LagomCrypto)
|
||||||
|
add_simple_fuzzer(FuzzPEM LagomCrypto)
|
||||||
add_simple_fuzzer(FuzzPNGLoader LagomGfx)
|
add_simple_fuzzer(FuzzPNGLoader LagomGfx)
|
||||||
add_simple_fuzzer(FuzzPBMLoader LagomGfx)
|
add_simple_fuzzer(FuzzPBMLoader LagomGfx)
|
||||||
add_simple_fuzzer(FuzzPGMLoader LagomGfx)
|
add_simple_fuzzer(FuzzPGMLoader LagomGfx)
|
||||||
|
|
15
Meta/Lagom/Fuzzers/FuzzPEM.cpp
Normal file
15
Meta/Lagom/Fuzzers/FuzzPEM.cpp
Normal file
|
@ -0,0 +1,15 @@
|
||||||
|
/*
|
||||||
|
* Copyright (c) 2021, Brian Gianforcaro <bgianf@serenityos.org>
|
||||||
|
*
|
||||||
|
* SPDX-License-Identifier: BSD-2-Clause
|
||||||
|
*/
|
||||||
|
|
||||||
|
#include <LibCrypto/ASN1/PEM.h>
|
||||||
|
#include <stddef.h>
|
||||||
|
#include <stdint.h>
|
||||||
|
|
||||||
|
extern "C" int LLVMFuzzerTestOneInput(const uint8_t* data, size_t size)
|
||||||
|
{
|
||||||
|
(void)Crypto::decode_pem({ data, size });
|
||||||
|
return 0;
|
||||||
|
}
|
Loading…
Add table
Add a link
Reference in a new issue