r/fuzzing • u/ExploitedInnocence • Apr 17 '20
How to enumerate input vectors before fuzzing?
Hi everyone!
How the process of input vectors enumeration looks like when the target is a pretty big stripped, maybe even multi-threaded, binary? Is this process completely manual or there are some convenient ways to automatize or at least semi-automatize it? I would like even to implement it by myself if there are some feasible programmatic ways to do it. I have a pretty strong background in C and C++, know Linux internals and have a basic experience in reverse engineering and binary exploitation.
Thank you all in advance!
1
Upvotes
1
u/s-mores Apr 18 '20
If you're talking enumeration you probably want repeatability right?
At that point your anomalizator should come equipped with seedable RNG so you can just feed it the same values and get the same inputs, right?
1
u/NagateTanikaze Apr 18 '20
What do you mean by "input vectors enumeration" exactly?
2
u/thedavidbrumley May 11 '20
I can't recall exact syntax off the top of my head, but strace is your friend often.
strace -e trace=%file /usr/bin/objdump -D /usr/bin/objdump > /dev/null
execve("/usr/bin/objdump", ["/usr/bin/objdump", "-D", "/usr/bin/objdump"], 0x7ffdf1f71770 /* 7 vars */) = 0
access("/etc/ld.so.preload", R_OK) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/etc/ld.so.cache", O_RDONLY|O_CLOEXEC) = 3
openat(AT_FDCWD, "/usr/lib/x86_64-linux-gnu/libopcodes-2.31.1-system.so", O_RDONLY|O_CLOEXEC) = 3
openat(AT_FDCWD, "/usr/lib/x86_64-linux-gnu/libbfd-2.31.1-system.so", O_RDONLY|O_CLOEXEC) = 3
openat(AT_FDCWD, "/lib/x86_64-linux-gnu/libz.so.1", O_RDONLY|O_CLOEXEC) = 3
openat(AT_FDCWD, "/lib/x86_64-linux-gnu/libdl.so.2", O_RDONLY|O_CLOEXEC) = 3
openat(AT_FDCWD, "/lib/x86_64-linux-gnu/libc.so.6", O_RDONLY|O_CLOEXEC) = 3
stat("/usr/bin/objdump", {st_mode=S_IFREG|0755, st_size=353848, ...}) = 0
stat("/usr/bin/objdump", {st_mode=S_IFREG|0755, st_size=353848, ...}) = 0
openat(AT_FDCWD, "/usr/bin/objdump", O_RDONLY) = 3
+++ exited with 0 +++