aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorvanhauser-thc <vh@thc.org>2022-11-14 21:26:17 +0100
committervanhauser-thc <vh@thc.org>2022-11-14 21:26:17 +0100
commit4a7cd53f64abf4eac311621220afc927574fdcea (patch)
treee9f919a6ba83f55d42fc5de74d63e5a8cc61467e /src
parentc5f8869778b237f89cc4c12c1961a9ef559179b8 (diff)
downloadafl++-4a7cd53f64abf4eac311621220afc927574fdcea.tar.gz
custom_send example
Diffstat (limited to 'src')
-rw-r--r--src/afl-fuzz-mutators.c58
1 files changed, 57 insertions, 1 deletions
diff --git a/src/afl-fuzz-mutators.c b/src/afl-fuzz-mutators.c
index f3d0bc96..ef30b993 100644
--- a/src/afl-fuzz-mutators.c
+++ b/src/afl-fuzz-mutators.c
@@ -211,8 +211,16 @@ struct custom_mutator *load_custom_mutator(afl_state_t *afl, const char *fn) {
WARNF("Symbol 'afl_custom_mutator' not found.");
+ } else {
+
+ OKF("Found 'afl_custom_mutator'.");
+
}
+ } else {
+
+ OKF("Found 'afl_custom_mutator'.");
+
}
/* "afl_custom_introspection", optional */
@@ -222,6 +230,10 @@ struct custom_mutator *load_custom_mutator(afl_state_t *afl, const char *fn) {
ACTF("optional symbol 'afl_custom_introspection' not found.");
+ } else {
+
+ OKF("Found 'afl_custom_introspection'.");
+
}
#endif
@@ -232,6 +244,10 @@ struct custom_mutator *load_custom_mutator(afl_state_t *afl, const char *fn) {
ACTF("optional symbol 'afl_custom_fuzz_count' not found.");
+ } else {
+
+ OKF("Found 'afl_custom_fuzz_count'.");
+
}
/* "afl_custom_deinit", optional for backward compatibility */
@@ -248,6 +264,10 @@ struct custom_mutator *load_custom_mutator(afl_state_t *afl, const char *fn) {
ACTF("optional symbol 'afl_custom_post_process' not found.");
+ } else {
+
+ OKF("Found 'afl_custom_post_process'.");
+
}
u8 notrim = 0;
@@ -258,6 +278,10 @@ struct custom_mutator *load_custom_mutator(afl_state_t *afl, const char *fn) {
notrim = 1;
ACTF("optional symbol 'afl_custom_init_trim' not found.");
+ } else {
+
+ OKF("Found 'afl_custom_init_trim'.");
+
}
/* "afl_custom_trim", optional */
@@ -267,6 +291,10 @@ struct custom_mutator *load_custom_mutator(afl_state_t *afl, const char *fn) {
notrim = 1;
ACTF("optional symbol 'afl_custom_trim' not found.");
+ } else {
+
+ OKF("Found 'afl_custom_trim'.");
+
}
/* "afl_custom_post_trim", optional */
@@ -276,6 +304,10 @@ struct custom_mutator *load_custom_mutator(afl_state_t *afl, const char *fn) {
notrim = 1;
ACTF("optional symbol 'afl_custom_post_trim' not found.");
+ } else {
+
+ OKF("Found 'afl_custom_post_trim'.");
+
}
if (notrim) {
@@ -295,6 +327,10 @@ struct custom_mutator *load_custom_mutator(afl_state_t *afl, const char *fn) {
ACTF("optional symbol 'afl_custom_havoc_mutation' not found.");
+ } else {
+
+ OKF("Found 'afl_custom_havoc_mutation'.");
+
}
/* "afl_custom_havoc_mutation", optional */
@@ -304,6 +340,10 @@ struct custom_mutator *load_custom_mutator(afl_state_t *afl, const char *fn) {
ACTF("optional symbol 'afl_custom_havoc_mutation_probability' not found.");
+ } else {
+
+ OKF("Found 'afl_custom_havoc_mutation_probability'.");
+
}
/* "afl_custom_queue_get", optional */
@@ -312,6 +352,10 @@ struct custom_mutator *load_custom_mutator(afl_state_t *afl, const char *fn) {
ACTF("optional symbol 'afl_custom_queue_get' not found.");
+ } else {
+
+ OKF("Found 'afl_custom_queue_get'.");
+
}
/* "afl_custom_fuzz_send", optional */
@@ -320,6 +364,10 @@ struct custom_mutator *load_custom_mutator(afl_state_t *afl, const char *fn) {
ACTF("optional symbol 'afl_custom_fuzz_send' not found.");
+ } else {
+
+ OKF("Found 'afl_custom_fuzz_send'.");
+
}
/* "afl_custom_queue_new_entry", optional */
@@ -328,13 +376,21 @@ struct custom_mutator *load_custom_mutator(afl_state_t *afl, const char *fn) {
ACTF("optional symbol 'afl_custom_queue_new_entry' not found");
+ } else {
+
+ OKF("Found 'afl_custom_queue_new_entry'.");
+
}
/* "afl_custom_describe", optional */
mutator->afl_custom_describe = dlsym(dh, "afl_custom_describe");
if (!mutator->afl_custom_describe) {
- ACTF("Symbol 'afl_custom_describe' not found.");
+ ACTF("optional symbol 'afl_custom_describe' not found.");
+
+ } else {
+
+ OKF("Found 'afl_custom_describe'.");
}