about summary refs log tree commit diff
path: root/include/afl-fuzz.h
diff options
context:
space:
mode:
authorvanhauser-thc <vh@thc.org>2022-11-11 10:46:45 +0100
committervanhauser-thc <vh@thc.org>2022-11-11 10:46:45 +0100
commitc5f8869778b237f89cc4c12c1961a9ef559179b8 (patch)
tree9582e14e72faf720b3e2c599cecc09530a56a227 /include/afl-fuzz.h
parentb2f12c37120e6529d1bab83976db009263dedc97 (diff)
downloadafl++-c5f8869778b237f89cc4c12c1961a9ef559179b8.tar.gz
afl_custom_fuzz_send added
Diffstat (limited to 'include/afl-fuzz.h')
-rw-r--r--include/afl-fuzz.h13
1 files changed, 13 insertions, 0 deletions
diff --git a/include/afl-fuzz.h b/include/afl-fuzz.h
index c8ca8e9b..a63b7493 100644
--- a/include/afl-fuzz.h
+++ b/include/afl-fuzz.h
@@ -969,6 +969,19 @@ struct custom_mutator {
   u8 (*afl_custom_queue_get)(void *data, const u8 *filename);
 
   /**
+   * This method can be used if you want to send data to the target yourself,
+   * e.g. via IPC. This replaces some usage of utils/afl_proxy but requires
+   * that you start the target with afl-fuzz.
+   *
+   * (Optional)
+   *
+   * @param data pointer returned in afl_custom_init by this custom mutator
+   * @param buf Buffer containing the test case
+   * @param buf_size Size of the test case
+   */
+  void (*afl_custom_fuzz_send)(void *data, const u8 *buf, size_t buf_size);
+
+  /**
    * Allow for additional analysis (e.g. calling a different tool that does a
    * different kind of coverage and saves this for the custom mutator).
    *