winafl icon indicating copy to clipboard operation
winafl copied to clipboard

Windows 10 [Version 10.0.19042.1348] x64 - DynamoRIO-Windows-9.0.19216 - VS 2019

Open callax2030 opened this issue 2 months ago • 6 comments

Hello,

I've really tried everything to get this working, and I'm starting to lose my mind. My setup is: Windows 10 [Version 10.0.19042.1348] x64, DynamoRIO-Windows-9.0.19216, and VS 2019. I first tried using the latest version of DynamoRIO, but the winafl.dll file never compiled and ended with errors.

With DynamoRIO 9.0.19216, the compilation works fine, though I get an ASLR warning. So, I have DynamoRIO 9.0.19216 and the Winafl fork compiled with the same version of DynamoRIO, and it should be working.

When I run drrun.exe -c ..\samples\bin64\bbsize.dll -- notepad, it runs fine with no error messages. However, when I try a simple command like c:\DynamoRIO\bin64\drrun.exe -c winafl.dll -- notepad, I always get the same error message: [3488] Unable to load client library: winafl.dll: library initializer failed.

I’ve tried copying winafl.dll into the same directory as c:\DynamoRIO\bin64, and I’ve also tried specifying the full path c:\winafl\build64\bin\Release\winafl.dll. I’ve tried all possible combinations, but the message is always the same. I’m getting really frustrated and upset. I don’t want to bother anyone, so I’ve tried to read and research everything I can.

Bitdefender and Windows 10 security are all Off and no Antivirus on my VM ...

Could someone please help me with this issue? I’d really appreciate it. :(

Cheers, callaX

callax2030 avatar Nov 05 '25 15:11 callax2030

C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise>dumpbin /headers c:\winafl\build64\bin\Release\winafl.dll | find "x64" 8664 machine (x64)

C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise>dumpbin /headers C:\DynamoRIO\bin64\drrun.exe | find "x64" 8664 machine (x64)

callax2030 avatar Nov 05 '25 16:11 callax2030

Image

callax2030 avatar Nov 05 '25 16:11 callax2030

I am getting the error too.

. "C:\Users\MakotoEmura\Documents\fuzz-test\DynamoRIO-Windows-10.0.19692\bin64\drrun.exe" `
	-c "C:\Users\MakotoEmura\Documents\fuzz-test\winafl\build64\bin\Release\winafl.dll" `
	-debug `
	-target_module eesimdFuzz.exe `
	-target_method Fuzz `
	-nargs 1 `
	-fuzz_iterations 2 `
	-- '..\x64\Release\eesimdFuzz.exe' "C:\Users\MakotoEmura\Documents\emeditor\EmEditor\eesimdFuzz\input\0.txt"
<Application C:\Users\MakotoEmura\Documents\emeditor\EmEditor\x64\Release\eesimdFuzz.exe (42284). Unable to load client library: winafl.dll: library initializer failed..>

I'm on windows 11, using visual studio 2022.

Compiled with:

cmake -G"Visual Studio 17 2022" -A x64 .. -DDynamoRIO_DIR=C:\Users\MakotoEmura\Documents\fuzz-test\DynamoRIO-Windows-10.0.19692\cmake -DUSE_COLOR=1 -DUSE_DRSYMS=1

I wish the error message was more specific so we know where and what failed.

MakotoE avatar Nov 12 '25 00:11 MakotoE

Hello MakotoE,

Give a try to this and let me know, it works for me.

Microsoft Windows [Version 10.0.19045.6466] DynamoRIO-Windows-9.93.19557 WinAFL (latest version) cmake -G"Visual Studio 17 2022" -A x64 .. -DDynamoRIO_DIR=C:\DynamoRIO\cmake -DUSE_COLOR=1

I'll try to setup a Win11 box shortly and I'll put my comments here.

Good LuckRegards,

callax2030 avatar Nov 13 '25 14:11 callax2030

It is also important to lauch the fuzz from Release (your system build version) too. You have to setup your binary environnement, dll's and other needed files to your .exe to run: cd C:\Users\fuzz\Desktop\winafl\build64\bin\Release C:\DynamoRIO\bin64\drrun.exe -c winafl.dll -debug -target_module test_gdiplus.exe -target_offset 0x1100 -fuzz_iterations 5 -nargs 2 -- test_gdiplus.exe not_kitty.bmp

Module loaded, dynamorio.dll Module loaded, winafl.dll Module loaded, drx.dll Module loaded, drreg.dll Module loaded, drmgr.dll Module loaded, drwrap.dll Module loaded, test_gdiplus.exe Module loaded, gdiplus.dll Module loaded, VCRUNTIME140.dll Module loaded, msvcp_win.dll .. Module loaded, MSCTF.dll In pre_fuzz_handler In post_fuzz_handler In pre_fuzz_handler Everything appears to be running normally. Coverage map follows:

callax2030 avatar Nov 13 '25 14:11 callax2030

Image

The Issue resolved.

callax2030 avatar Nov 13 '25 21:11 callax2030