This commit is contained in:
vanhauser-thc
2023-08-04 09:25:19 +02:00
parent 4a9264444f
commit 79640acbf1
5 changed files with 26 additions and 19 deletions

View File

@ -78,7 +78,7 @@ enum {
};
#define MUT_TXT_ARRAY_SIZE 200
#define MUT_TXT_ARRAY_SIZE 200
u32 text_array[MUT_TXT_ARRAY_SIZE] = {MUT_FLIPBIT,
MUT_FLIPBIT,
MUT_FLIPBIT,
@ -280,7 +280,7 @@ u32 text_array[MUT_TXT_ARRAY_SIZE] = {MUT_FLIPBIT,
MUT_SPLICE_INSERT,
MUT_SPLICE_INSERT};
#define MUT_BIN_ARRAY_SIZE 256
#define MUT_BIN_ARRAY_SIZE 256
u32 binary_array[MUT_BIN_ARRAY_SIZE] = {MUT_FLIPBIT,
MUT_FLIPBIT,
MUT_FLIPBIT,
@ -538,7 +538,7 @@ u32 binary_array[MUT_BIN_ARRAY_SIZE] = {MUT_FLIPBIT,
MUT_SPLICE_INSERT,
MUT_SPLICE_INSERT};
#define MUT_NORMAL_ARRAY_SIZE 77
#define MUT_NORMAL_ARRAY_SIZE 77
u32 normal_splice_array[MUT_NORMAL_ARRAY_SIZE] = {MUT_FLIPBIT,
MUT_FLIPBIT,
MUT_FLIPBIT,
@ -617,7 +617,7 @@ u32 normal_splice_array[MUT_NORMAL_ARRAY_SIZE] = {MUT_FLIPBIT,
MUT_SPLICE_INSERT,
MUT_SPLICE_INSERT};
#define MUT_SPLICE_ARRAY_SIZE 81
#define MUT_SPLICE_ARRAY_SIZE 81
u32 full_splice_array[MUT_SPLICE_ARRAY_SIZE] = {MUT_FLIPBIT,
MUT_FLIPBIT,
MUT_FLIPBIT,

View File

@ -86,7 +86,8 @@ typedef struct {
uint32_t size);
bool (*nyx_remove_work_dir)(const char *workdir);
bool (*nyx_config_set_aux_buffer_size)(void *config, uint32_t aux_buffer_size);
bool (*nyx_config_set_aux_buffer_size)(void *config,
uint32_t aux_buffer_size);
} nyx_plugin_handler_t;

View File

@ -129,7 +129,8 @@ nyx_plugin_handler_t *afl_load_libnyx_plugin(u8 *libnyx_binary) {
plugin->nyx_remove_work_dir = dlsym(handle, "nyx_remove_work_dir");
if (plugin->nyx_remove_work_dir == NULL) { goto fail; }
plugin->nyx_config_set_aux_buffer_size = dlsym(handle, "nyx_config_set_aux_buffer_size");
plugin->nyx_config_set_aux_buffer_size =
dlsym(handle, "nyx_config_set_aux_buffer_size");
if (plugin->nyx_config_set_aux_buffer_size == NULL) { goto fail; }
OKF("libnyx plugin is ready!");
@ -593,10 +594,16 @@ void afl_fsrv_start(afl_forkserver_t *fsrv, char **argv,
}
if (getenv("AFL_NYX_AUX_SIZE") != NULL) {
if(fsrv->nyx_handlers->nyx_config_set_aux_buffer_size(
if (fsrv->nyx_handlers->nyx_config_set_aux_buffer_size(
nyx_config, atoi(getenv("AFL_NYX_AUX_SIZE"))) != 1) {
NYX_PRE_FATAL(fsrv, "Invalid AFL_NYX_AUX_SIZE value set (must be a multiple of 4096) ...");
NYX_PRE_FATAL(fsrv,
"Invalid AFL_NYX_AUX_SIZE value set (must be a multiple "
"of 4096) ...");
}
}
if (getenv("NYX_REUSE_SNAPSHOT") != NULL) {

View File

@ -311,8 +311,8 @@ static void usage(u8 *argv0, int more_help) {
PERSISTENT_MSG
"AFL_POST_PROCESS_KEEP_ORIGINAL: save the file as it was prior post-processing to the queue,\n"
" but execute the post-processed one\n"
"AFL_POST_PROCESS_KEEP_ORIGINAL: save the file as it was prior post-processing to\n"
" the queue, but execute the post-processed one\n"
"AFL_PRELOAD: LD_PRELOAD / DYLD_INSERT_LIBRARIES settings for target\n"
"AFL_TARGET_ENV: pass extra environment variables to target\n"
"AFL_SHUFFLE_QUEUE: reorder the input queue randomly on startup\n"
@ -323,18 +323,17 @@ static void usage(u8 *argv0, int more_help) {
"AFL_STATSD_HOST: change default statsd host (default 127.0.0.1)\n"
"AFL_STATSD_PORT: change default statsd port (default: 8125)\n"
"AFL_STATSD_TAGS_FLAVOR: set statsd tags format (default: disable tags)\n"
" Supported formats are: 'dogstatsd', 'librato',\n"
" 'signalfx' and 'influxdb'\n"
" suported formats: dogstatsd, librato, signalfx, influxdb\n"
"AFL_SYNC_TIME: sync time between fuzzing instances (in minutes)\n"
"AFL_NO_CRASH_README: do not create a README in the crashes directory\n"
"AFL_TESTCACHE_SIZE: use a cache for testcases, improves performance (in MB)\n"
"AFL_TMPDIR: directory to use for input file generation (ramdisk recommended)\n"
"AFL_EARLY_FORKSERVER: force an early forkserver in an afl-clang-fast/\n"
" afl-clang-lto/afl-gcc-fast target\n"
"AFL_PERSISTENT: enforce persistent mode (if __AFL_LOOP is in a shared lib\n"
"AFL_DEFER_FORKSRV: enforced deferred forkserver (__AFL_INIT is in a .so)\n"
"AFL_FUZZER_STATS_UPDATE_INTERVAL: interval to update fuzzer_stats file in seconds, "
"(default: 60, minimum: 1)\n"
"AFL_PERSISTENT: enforce persistent mode (if __AFL_LOOP is in a shared lib)\n"
"AFL_DEFER_FORKSRV: enforced deferred forkserver (__AFL_INIT is in a shared lib)\n"
"AFL_FUZZER_STATS_UPDATE_INTERVAL: interval to update fuzzer_stats file in\n"
" seconds (default: 60, minimum: 1)\n"
"\n"
);