Win32 Keylogging

By Dag, on December 30th, 2016

Win32 Keylogging code. Sends logs to external listening server. Posted for the illustration of
GetAsyncKeyState which is the heart of the program and can be used for any key listening
application across programs, as it doesn't need focus. All keyboard input in Windows gets
filtered by it. Useful for game overlays, background listeners etc. Further down I've also posted
the C# .NET version, where I've P/Invoked the necessary DLLs to use much of the Win32 code.
If you want to see what kind of logs it generates, you can see and download a working client/server version
here.