about summary refs log tree commit diff
path: root/utils
diff options
context:
space:
mode:
Diffstat (limited to 'utils')
-rw-r--r--utils/afl_untracer/afl-untracer.c4
-rw-r--r--utils/argv_fuzzing/Makefile2
-rw-r--r--utils/argv_fuzzing/argvfuzz.c2
-rw-r--r--utils/libdislocator/README.md4
-rw-r--r--utils/libtokencap/README.md2
5 files changed, 9 insertions, 5 deletions
diff --git a/utils/afl_untracer/afl-untracer.c b/utils/afl_untracer/afl-untracer.c
index d2cb4bcf..fd4c3b8c 100644
--- a/utils/afl_untracer/afl-untracer.c
+++ b/utils/afl_untracer/afl-untracer.c
@@ -65,6 +65,7 @@
 #elif defined(__FreeBSD__)
   #include <sys/sysctl.h>
   #include <sys/user.h>
+  #include <sys/procctl.h>
 #else
   #error "Unsupported platform"
 #endif
@@ -685,6 +686,9 @@ int main(int argc, char *argv[]) {
 
 #if defined(__linux__)
   (void)personality(ADDR_NO_RANDOMIZE);  // disable ASLR
+#elif defined(__FreeBSD__) && __FreeBSD_version >= 1200000
+  int no_randomize = PROC_ASLR_FORCE_DISABLE;
+  (void)procctl(P_PID, 0, PROC_ASLR_CTL, &no_randomize);
 #endif
 
   pid = getpid();
diff --git a/utils/argv_fuzzing/Makefile b/utils/argv_fuzzing/Makefile
index 5a0ac6e6..183f6bf8 100644
--- a/utils/argv_fuzzing/Makefile
+++ b/utils/argv_fuzzing/Makefile
@@ -2,7 +2,7 @@
 # american fuzzy lop++ - argvfuzz
 # --------------------------------
 #
-# Copyright 2019-2020 Kjell Braden <afflux@pentabarf.de>
+# Copyright 2019-2022 Kjell Braden <afflux@pentabarf.de>
 #
 # Licensed under the Apache License, Version 2.0 (the "License");
 # you may not use this file except in compliance with the License.
diff --git a/utils/argv_fuzzing/argvfuzz.c b/utils/argv_fuzzing/argvfuzz.c
index 4251ca4c..e7cc6b72 100644
--- a/utils/argv_fuzzing/argvfuzz.c
+++ b/utils/argv_fuzzing/argvfuzz.c
@@ -2,7 +2,7 @@
    american fuzzy lop++ - LD_PRELOAD for fuzzing argv in binaries
    ------------------------------------------------------------
 
-   Copyright 2019-2020 Kjell Braden <afflux@pentabarf.de>
+   Copyright 2019-2022 Kjell Braden <afflux@pentabarf.de>
 
    Licensed under the Apache License, Version 2.0 (the "License");
    you may not use this file except in compliance with the License.
diff --git a/utils/libdislocator/README.md b/utils/libdislocator/README.md
index 116a22ba..68ac9143 100644
--- a/utils/libdislocator/README.md
+++ b/utils/libdislocator/README.md
@@ -27,9 +27,9 @@ heap-related security bugs in several ways:
     AFL_LD_HARD_FAIL).
 
   - Optionally, in platforms supporting it, huge pages can be used by passing
-    USEHUGEPAGE=1 to make.
+    `USEHUGEPAGE=1` to make.
 
-  - Size alignment to `max_align_t` can be enforced with AFL_ALIGNED_ALLOC=1. In
+  - Size alignment to `max_align_t` can be enforced with `AFL_ALIGNED_ALLOC=1`. In
     this case, a tail canary is inserted in the padding bytes at the end of the
     allocated zone. This reduce the ability of libdislocator to detect
     off-by-one bugs but also it make slibdislocator compliant to the C standard.
diff --git a/utils/libtokencap/README.md b/utils/libtokencap/README.md
index 4e7ed1d1..50104291 100644
--- a/utils/libtokencap/README.md
+++ b/utils/libtokencap/README.md
@@ -31,7 +31,7 @@ require AFL-instrumented binaries to work.
 
 To use the library, you *need* to make sure that your fuzzing target is compiled
 with -fno-builtin and is linked dynamically. If you wish to automate the first
-part without mucking with CFLAGS in Makefiles, you can set AFL_NO_BUILTIN=1
+part without mucking with CFLAGS in Makefiles, you can set `AFL_NO_BUILTIN=1`
 when using afl-gcc. This setting specifically adds the following flags:
 
 ```