mirror of
https://github.com/AFLplusplus/AFLplusplus.git
synced 2025-06-15 19:38:09 +00:00
minimum sync time
This commit is contained in:
@ -35,6 +35,7 @@ sending a mail to <afl-users+subscribe@googlegroups.com>.
|
|||||||
- fixed a few crashes
|
- fixed a few crashes
|
||||||
- switched to an even faster RNG
|
- switched to an even faster RNG
|
||||||
- added hghwng's patch for faster trace map analysis
|
- added hghwng's patch for faster trace map analysis
|
||||||
|
- added minimum SYNC_TIME to include/config.h (30 minutes default)
|
||||||
- afl-cc
|
- afl-cc
|
||||||
- allow instrumenting LLVMFuzzerTestOneInput
|
- allow instrumenting LLVMFuzzerTestOneInput
|
||||||
- fixed endless loop for allow/blocklist lines starting with a
|
- fixed endless loop for allow/blocklist lines starting with a
|
||||||
|
@ -570,6 +570,7 @@ typedef struct afl_state {
|
|||||||
blocks_eff_total, /* Blocks subject to effector maps */
|
blocks_eff_total, /* Blocks subject to effector maps */
|
||||||
blocks_eff_select, /* Blocks selected as fuzzable */
|
blocks_eff_select, /* Blocks selected as fuzzable */
|
||||||
start_time, /* Unix start time (ms) */
|
start_time, /* Unix start time (ms) */
|
||||||
|
last_sync_time, /* Time of last sync */
|
||||||
last_path_time, /* Time for most recent path (ms) */
|
last_path_time, /* Time for most recent path (ms) */
|
||||||
last_crash_time, /* Time for most recent crash (ms) */
|
last_crash_time, /* Time for most recent crash (ms) */
|
||||||
last_hang_time; /* Time for most recent hang (ms) */
|
last_hang_time; /* Time for most recent hang (ms) */
|
||||||
|
@ -280,6 +280,11 @@
|
|||||||
|
|
||||||
#define SYNC_INTERVAL 8
|
#define SYNC_INTERVAL 8
|
||||||
|
|
||||||
|
/* Sync time (minimum time between syncing in ms, time is halfed for -M main
|
||||||
|
nodes): */
|
||||||
|
|
||||||
|
#define SYNC_TIME 18000000LLU /* 18000000 = 30 minutes */
|
||||||
|
|
||||||
/* Output directory reuse grace period (minutes): */
|
/* Output directory reuse grace period (minutes): */
|
||||||
|
|
||||||
#define OUTPUT_GRACE 25
|
#define OUTPUT_GRACE 25
|
||||||
|
@ -707,6 +707,8 @@ void sync_fuzzers(afl_state_t *afl) {
|
|||||||
|
|
||||||
if (afl->foreign_sync_cnt) read_foreign_testcases(afl, 0);
|
if (afl->foreign_sync_cnt) read_foreign_testcases(afl, 0);
|
||||||
|
|
||||||
|
afl->last_sync_time = get_cur_time();
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Trim all new test cases to save cycles when doing deterministic checks. The
|
/* Trim all new test cases to save cycles when doing deterministic checks. The
|
||||||
|
@ -1986,18 +1986,27 @@ int main(int argc, char **argv_orig, char **envp) {
|
|||||||
|
|
||||||
if (unlikely(afl->is_main_node)) {
|
if (unlikely(afl->is_main_node)) {
|
||||||
|
|
||||||
|
if (unlikely(get_cur_time() >
|
||||||
|
(SYNC_TIME >> 1) + afl->last_sync_time)) {
|
||||||
|
|
||||||
if (!(sync_interval_cnt++ % (SYNC_INTERVAL / 3))) {
|
if (!(sync_interval_cnt++ % (SYNC_INTERVAL / 3))) {
|
||||||
|
|
||||||
sync_fuzzers(afl);
|
sync_fuzzers(afl);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
|
|
||||||
|
if (unlikely(get_cur_time() > SYNC_TIME + afl->last_sync_time)) {
|
||||||
|
|
||||||
if (!(sync_interval_cnt++ % SYNC_INTERVAL)) { sync_fuzzers(afl); }
|
if (!(sync_interval_cnt++ % SYNC_INTERVAL)) { sync_fuzzers(afl); }
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
|
|
||||||
sync_fuzzers(afl);
|
sync_fuzzers(afl);
|
||||||
|
Reference in New Issue
Block a user