EventManageris refactored to avoid calling function fromFuzzer, thus we do not evaluate testcases inEventManageranymore.- Now we have
EventReceiverineventsmodule, andEventProcessorinfuzzermodule. EventReceiveris responsible for receiving testcases and delegates its evaluation toEventProcessor.EventProcessoris responsible for evaluating the testcases passed by theEventReceiver.- Since we don't evaluate testcases in the
EventManageranymore.on_fireandpost_exechave been deleted fromEventManagerHook. - Similarly
pre_exechas been renamed topre_receive.
- Now we have
AsanModulenow uses abuilder()method for constructing its instances.Monitoris refactored. Most statistics have been extracted into an individualstatsmodule undermonitors.- There is a
ClientStatsManagerto manage client statistics, and is owned byEventManager. Most of previousMonitor's trait methods have been moved to theClientStatsManager. user_monitorhas been renamed touser_stats,introspection_monitorhas been renamed tointrospection_stats, perf-related structure definitions have been renamed, and all were moved to thestatsmodule.OnDiskTomlMonitor,OnDiskJsonMonitor,OnDiskJsonAggregateMonitorare now no longer takes a base monitor to wrap. If you want to use multiple monitors together, simply use atuple_list.
- There is a
MultipartInputis now implemented as key-value tuples in aListInput. The interface slightly changed, all functionality is maintained.- Instead of names,
MultipartInputuses generickeys (function names were changed accordingly). - If you don't need the keys to identify individual parts, consider using
ListInputdirectly. StdScheduledMutatorhas been renamed toHavocScheduledMutator.
- Instead of names,
MmapShMem::newandMmapShMemProvider::new_shmem_with_idnow takeAsRef<Path>instead of a byte array for the filename/id.- The closure passed to a
DumpToDiskStagenow provides theTestcaseinstead of just theInput. StatsStageis deleted, and it is superceded byAflStatsStage- Renamed and changed mapping mutators to take borrows directly instead of
MappedInputs. Seebaby_fuzzer_custom_inputfor example usage- Related:
MutVecInputis deprecated in favor of directly using&mut Vec<u8> - Related:
MappedInputFunctionMappingMutatorandToMappedInputFunctionMappingMutatorMapperhave been removed as now duplicates ofMappingMutator(previouslyFunctionMappingMutator) andToMappingMutator(previouslyToFunctionMappingMutatorMapper) - Related:
ToOptionMappingMutatorMapperandToFunctionMappingMutatorMapperhave been renamed toToOptionalMutatorandToMappingMutatorrespectively
- Related:
Qemucannot be used to initializeEmulatordirectly anymore. Instead,Qemushould be initialized throughEmulatorsystematically ifEmulatorshould be used.- Related:
EmulatorBuilderuses a single function to provide aQemuinitializer:EmulatorBuilder::qemu_parameters. For now, it can be either aVec<String>or aQemuConfiginstance. - Related: Qemu's
AsanModuledoes not need any special call toQemuinit methods anymore. It is now possible to simply initializeAsanModule(orAsanGuestModule) with a reference to the environment as parameter. CustomBufHandlershas been deleted. Please useEventManagerHooksTuplefrom now on.
- Related:
- Trait restrictions have been simplified
- The
UsesStateandUsesInputtraits have been removed in favor of regular Generics. - For the structs/traits that used to use
UsesState, we bring back the generic for the state. Inputis now only accessible through generic.Inputassociated types have been definitely removed.HasCorpusbound has been removed in many places it was unused before.StdMutationalStage::transformingmust now explicitly state the Inputs types. As a result,StdMutationalStage::transformingmust be writtenStdMutationalStage::<_, _, FirstInputType, SecondInputType, _, _, _>::transforming.- The
Statetrait is now private in favour of individual and more specific traits
- The
- Restrictions from certain schedulers and stages that required their inner observer to implement
MapObserverhave been lifted in favor of requiringHash- Related: removed
hash_simplefromMapObserver
- Related: removed
- Removed
with_observersfromExecutortrait. MmapShMemProvider::new_shmem_persistenthas been removed in favour ofMmapShMem::persist. You probably want to do something like this:let shmem = MmapShMemProvider::new()?.new_shmem(size)?.persist()?;