honggfuzz  2.2
About: honggfuzz is a security oriented, feedback-driven, evolutionary, easy-to-use fuzzer with powerful analysis options.
  Fossies Dox: honggfuzz-2.2.tar.gz  ("unofficial" and yet experimental doxygen-generated source code documentation)  

persistent.c File Reference
#include <errno.h>
#include <fcntl.h>
#include <inttypes.h>
#include <limits.h>
#include <signal.h>
#include <stdbool.h>
#include <stdint.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <sys/mman.h>
#include <sys/stat.h>
#include <sys/types.h>
#include <unistd.h>
#include "honggfuzz.h"
#include "libhfcommon/common.h"
#include "libhfcommon/files.h"
#include "libhfcommon/log.h"
#include "libhfuzz/fetch.h"
#include "libhfuzz/instrument.h"
#include "libhfuzz/libhfuzz.h"
#include "libhfuzz/performance.h"
Include dependency graph for persistent.c:

Go to the source code of this file.

Functions

int LLVMFuzzerInitialize (int *argc, char ***argv)
 
size_t LLVMFuzzerMutate (uint8_t *Data, size_t Size, size_t MaxSize)
 
int LLVMFuzzerTestOneInput (const uint8_t *buf, size_t len)
 
static void initializePersistent (void)
 
void HF_ITER (const uint8_t **buf_ptr, size_t *len_ptr)
 
static void HonggfuzzRunOneInput (const uint8_t *buf, size_t len)
 
static void HonggfuzzPersistentLoop (void)
 
static int HonggfuzzRunFromFile (int argc, char **argv)
 
int HonggfuzzMain (int argc, char **argv)
 
int main (int argc, char **argv)
 

Variables

static const uint8_t * inputFile = NULL
 
const char *const LIBHFUZZ_module_memorycmp
 
const char *const LIBHFUZZ_module_instrument
 

Function Documentation

◆ HF_ITER()

void HF_ITER ( const uint8_t **  buf_ptr,
size_t *  len_ptr 
)

Definition at line 56 of file persistent.c.

References HonggfuzzFetchData().

◆ HonggfuzzMain()

int HonggfuzzMain ( int  argc,
char **  argv 
)

◆ HonggfuzzPersistentLoop()

static void HonggfuzzPersistentLoop ( void  )
static

Definition at line 72 of file persistent.c.

References HonggfuzzFetchData(), HonggfuzzRunOneInput(), len, and performanceCheck().

Referenced by HonggfuzzMain().

◆ HonggfuzzRunFromFile()

static int HonggfuzzRunFromFile ( int  argc,
char **  argv 
)
static

◆ HonggfuzzRunOneInput()

static void HonggfuzzRunOneInput ( const uint8_t *  buf,
size_t  len 
)
static

◆ initializePersistent()

static void initializePersistent ( void  )
static

Definition at line 44 of file persistent.c.

References _HF_INPUT_FD, _HF_INPUT_MAX_SIZE, files_getTmpMapFlags(), inputFile, and PLOG_F.

◆ LLVMFuzzerInitialize()

◆ LLVMFuzzerMutate()

size_t LLVMFuzzerMutate ( uint8_t *  Data,
size_t  Size,
size_t  MaxSize 
)

Definition at line 30 of file persistent.c.

References LOG_F.

◆ LLVMFuzzerTestOneInput()

int LLVMFuzzerTestOneInput ( const uint8_t *  buf,
size_t  len 
)

◆ main()

int main ( int  argc,
char **  argv 
)

Definition at line 132 of file persistent.c.

References HonggfuzzMain().

Variable Documentation

◆ inputFile

const uint8_t* inputFile = NULL
static

Definition at line 43 of file persistent.c.

Referenced by initializePersistent().

◆ LIBHFUZZ_module_instrument

const char* const LIBHFUZZ_module_instrument

Definition at line 31 of file instrument.c.

Referenced by HonggfuzzRunOneInput().

◆ LIBHFUZZ_module_memorycmp

const char* const LIBHFUZZ_module_memorycmp

Definition at line 16 of file memorycmp.c.

Referenced by HonggfuzzRunOneInput().