LLVM  6.0.0svn
Public Member Functions | Static Public Member Functions | List of all members
fuzzer::Fuzzer Class Reference

#include "Fuzzer/FuzzerInternal.h"

Public Member Functions

 Fuzzer (UserCallback CB, InputCorpus &Corpus, MutationDispatcher &MD, FuzzingOptions Options)
 
 ~Fuzzer ()
 
void Loop ()
 
void MinimizeCrashLoop (const Unit &U)
 
void ShuffleAndMinimize (UnitVector *V)
 
void RereadOutputCorpus (size_t MaxSize)
 
size_t secondsSinceProcessStartUp ()
 
bool TimedOut ()
 
size_t execPerSec ()
 
size_t getTotalNumberOfRuns ()
 
void ExecuteCallback (const uint8_t *Data, size_t Size)
 
bool RunOne (const uint8_t *Data, size_t Size, bool MayDeleteFile=false, InputInfo *II=nullptr)
 
void Merge (const std::vector< std::string > &Corpora)
 
void CrashResistantMerge (const std::vector< std::string > &Args, const std::vector< std::string > &Corpora, const char *CoverageSummaryInputPathOrNull, const char *CoverageSummaryOutputPathOrNull)
 
void CrashResistantMergeInternalStep (const std::string &ControlFilePath)
 
MutationDispatcherGetMD ()
 
void PrintFinalStats ()
 
void SetMaxInputLen (size_t MaxInputLen)
 
void SetMaxMutationLen (size_t MaxMutationLen)
 
void RssLimitCallback ()
 
bool InFuzzingThread () const
 
size_t GetCurrentUnitInFuzzingThead (const uint8_t **Data) const
 
void TryDetectingAMemoryLeak (const uint8_t *Data, size_t Size, bool DuringInitialCorpusExecution)
 
void HandleMalloc (size_t Size)
 
void AnnounceOutput (const uint8_t *Data, size_t Size)
 

Static Public Member Functions

static void StaticAlarmCallback ()
 
static void StaticCrashSignalCallback ()
 
static void StaticExitCallback ()
 
static void StaticInterruptCallback ()
 
static void StaticFileSizeExceedCallback ()
 

Detailed Description

Definition at line 32 of file FuzzerInternal.h.

Constructor & Destructor Documentation

◆ Fuzzer()

fuzzer::Fuzzer::Fuzzer ( UserCallback  CB,
InputCorpus Corpus,
MutationDispatcher MD,
FuzzingOptions  Options 
)

◆ ~Fuzzer()

fuzzer::Fuzzer::~Fuzzer ( )

Member Function Documentation

◆ AnnounceOutput()

void fuzzer::Fuzzer::AnnounceOutput ( const uint8_t *  Data,
size_t  Size 
)

◆ CrashResistantMerge()

void fuzzer::Fuzzer::CrashResistantMerge ( const std::vector< std::string > &  Args,
const std::vector< std::string > &  Corpora,
const char CoverageSummaryInputPathOrNull,
const char CoverageSummaryOutputPathOrNull 
)

◆ CrashResistantMergeInternalStep()

void fuzzer::Fuzzer::CrashResistantMergeInternalStep ( const std::string &  ControlFilePath)

◆ execPerSec()

size_t fuzzer::Fuzzer::execPerSec ( )
inline

Definition at line 54 of file FuzzerInternal.h.

Referenced by PrintFinalStats(), and RssLimitCallback().

◆ ExecuteCallback()

void fuzzer::Fuzzer::ExecuteCallback ( const uint8_t *  Data,
size_t  Size 
)

◆ GetCurrentUnitInFuzzingThead()

size_t fuzzer::Fuzzer::GetCurrentUnitInFuzzingThead ( const uint8_t **  Data) const

◆ GetMD()

MutationDispatcher& fuzzer::Fuzzer::GetMD ( )
inline

Definition at line 78 of file FuzzerInternal.h.

Referenced by LLVMFuzzerMutate().

◆ getTotalNumberOfRuns()

size_t fuzzer::Fuzzer::getTotalNumberOfRuns ( )
inline

◆ HandleMalloc()

void fuzzer::Fuzzer::HandleMalloc ( size_t  Size)

Definition at line 98 of file FuzzerLoop.cpp.

References fuzzer::EF, fuzzer::GetPid(), and fuzzer::Printf().

Referenced by fuzzer::MallocHook().

◆ InFuzzingThread()

bool fuzzer::Fuzzer::InFuzzingThread ( ) const
inline

◆ Loop()

void fuzzer::Fuzzer::Loop ( )

◆ Merge()

void fuzzer::Fuzzer::Merge ( const std::vector< std::string > &  Corpora)

◆ MinimizeCrashLoop()

void fuzzer::Fuzzer::MinimizeCrashLoop ( const Unit U)

◆ PrintFinalStats()

void fuzzer::Fuzzer::PrintFinalStats ( )

◆ RereadOutputCorpus()

void fuzzer::Fuzzer::RereadOutputCorpus ( size_t  MaxSize)

◆ RssLimitCallback()

void fuzzer::Fuzzer::RssLimitCallback ( )

◆ RunOne()

bool fuzzer::Fuzzer::RunOne ( const uint8_t *  Data,
size_t  Size,
bool  MayDeleteFile = false,
InputInfo II = nullptr 
)

◆ secondsSinceProcessStartUp()

size_t fuzzer::Fuzzer::secondsSinceProcessStartUp ( )
inline

Definition at line 43 of file FuzzerInternal.h.

References llvm::count(), and now().

Referenced by fuzzer::FuzzerDriver(), and ShuffleAndMinimize().

◆ SetMaxInputLen()

void fuzzer::Fuzzer::SetMaxInputLen ( size_t  MaxInputLen)

Definition at line 312 of file FuzzerLoop.cpp.

References assert(), and fuzzer::Printf().

Referenced by fuzzer::FuzzerDriver().

◆ SetMaxMutationLen()

void fuzzer::Fuzzer::SetMaxMutationLen ( size_t  MaxMutationLen)

◆ ShuffleAndMinimize()

void fuzzer::Fuzzer::ShuffleAndMinimize ( UnitVector V)

◆ StaticAlarmCallback()

void fuzzer::Fuzzer::StaticAlarmCallback ( )
static

Definition at line 168 of file FuzzerLoop.cpp.

References assert().

◆ StaticCrashSignalCallback()

void fuzzer::Fuzzer::StaticCrashSignalCallback ( )
static

Definition at line 173 of file FuzzerLoop.cpp.

References assert().

◆ StaticExitCallback()

void fuzzer::Fuzzer::StaticExitCallback ( )
static

Definition at line 178 of file FuzzerLoop.cpp.

References assert().

◆ StaticFileSizeExceedCallback()

void fuzzer::Fuzzer::StaticFileSizeExceedCallback ( )
static

◆ StaticInterruptCallback()

void fuzzer::Fuzzer::StaticInterruptCallback ( )
static

Definition at line 183 of file FuzzerLoop.cpp.

References assert().

◆ TimedOut()

bool fuzzer::Fuzzer::TimedOut ( )
inline

Definition at line 48 of file FuzzerInternal.h.

References fuzzer::FuzzingOptions::MaxTotalTimeSec.

Referenced by Loop(), and MinimizeCrashLoop().

◆ TryDetectingAMemoryLeak()

void fuzzer::Fuzzer::TryDetectingAMemoryLeak ( const uint8_t *  Data,
size_t  Size,
bool  DuringInitialCorpusExecution 
)

The documentation for this class was generated from the following files: