fork server handshake failed

1,914 views
Skip to first unread message

abhi spark

unread,
Jan 24, 2017, 12:00:13 AM1/24/17
to afl-users
i crosscompiled a c program to arm using arm-linux-gnueabi-gcc , then build the afl-qemu setting CPU_TARGET=arm ./bashscript . when i run the command afl-fuzz -i in/ -o out/ -Q --/path /to/fuzz/app @@ i get the fork server handshake failed , detailing memory insufficient . even i gave -m 6000 its the same replicating .
can some one say did i do anything wrong while executing?

thanks in advance

Michal Zalewski

unread,
Jan 24, 2017, 12:05:32 AM1/24/17
to afl-users
> can some one say did i do anything wrong while executing?

Try running the program under afl-showmap, like so:

afl-showmap -o- -Q /path/to/target/binary [...params...]

It should allow you to see any error messages from QEMU or the target
program itself. Likely a cross-compilation or target arch issue, but
hard to tell.

/mz

abhi spark

unread,
Jan 24, 2017, 12:43:18 AM1/24/17
to afl-users
i have ran afl-showmap and got output as no instrument detected.
Capture.JPG

Michal Zalewski

unread,
Jan 24, 2017, 1:41:51 AM1/24/17
to afl-users
Well, the QEMU error message complains about not having enough memory.
Looks like it's trying to allocate a ton, so maybe just try '-m none'
to the afl-showmap command line (and if that works, also use it with
afl-fuzz)?
> --
> You received this message because you are subscribed to the Google Groups
> "afl-users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to afl-users+...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
Message has been deleted

abhi spark

unread,
Jan 24, 2017, 2:07:17 AM1/24/17
to afl-users
Thanks , it worked  and found few crashes. but after some time it pops out error stating unable to communicate with fork server (00M?)  location run_target , i attached the screen shot.
Screenshot from 2017-01-24 12-35-41.png

Michal Zalewski

unread,
Jan 24, 2017, 2:23:46 AM1/24/17
to afl-users
> Thanks , it worked and found few crashes. but after some time it pops out
> error stating unable to communicate with fork server (00M?) location
> run_target , i attached the screen shot.

You likely run out of memory when the program tries to allocate too
much of it due to some sort of a coding error (a consequence of
lifting the memory limit with -m none).

You could try to fine-tune the -m value so that the program runs but
can't crash other programs. There may be some other workarounds, but
they would be application-specific.

/mz

abhi spark

unread,
Jan 24, 2017, 2:31:06 AM1/24/17
to afl-users
Thanks , yup now everything is working fine  setting AFL_NO_FORKSRV=1 solved my issue . thanks a lot lcamtuf :)

Gen Zhang

unread,
Apr 27, 2017, 5:36:32 AM4/27/17
to afl-users
How to set  AFL_NO_FORKSRV=1?
Any specific steps?
Thanks

在 2017年1月24日星期二 UTC+8下午3:31:06,abhi spark写道:
Reply all
Reply to author
Forward
0 new messages