winafl
winafl copied to clipboard
Warning: post-fuzz handler was never reached.
Hi @ivanfratric! I was trying to fuzz ffmpeg on Windows. First, I used drrun.exe to find correct target_offset, I set the offset of main as the target_offset, but there was waring as title, what caused this problem, I made sure that the the "exit" function is called in main.
The target function must not call exit as this causes the process to be terminated and post-fuzz handler not being reached. The target function should use return
instead of exit
.
Thanks for replying, the main function of ffmpeg is end with "call exit_program" instead of return, the main function is the direct parent caller function of opening file and closing file. So, in this case, how to choose the target_offset?
you need to choose a function which returns.
or you can patch the binary to jump on return