nDPI/fuzz/fuzz_common_code.h
Ivan Nardi 9fc724de5a
Add some fuzzers to test other data structures. (#1870)
Start using a dictionary for fuzzing (see:
https://llvm.org/docs/LibFuzzer.html#dictionaries).
Remove some dead code.
Fuzzing with debug enabled is not usually a great idea (from performance
POV). Keep the code since it might be useful while debugging.
2023-01-25 11:44:59 +01:00

22 lines
415 B
C

#ifndef __FUZZ_COMMON_CODE_H__
#define __FUZZ_COMMON_CODE_H__
#include "ndpi_api.h"
#ifdef __cplusplus
extern "C"
{
#endif
void fuzz_init_detection_module(struct ndpi_detection_module_struct **ndpi_info_mod);
/* To allow memory allocation failures */
void fuzz_set_alloc_callbacks(void);
void fuzz_set_alloc_seed(int seed);
void fuzz_set_alloc_callbacks_and_seed(int seed);
#ifdef __cplusplus
}
#endif
#endif