This is a very simple filter driver. And here are the steps to run it.
(Please note that all mentioned below was done using VirtualBox and Windows10 installed on it in order to prevent main OS crash!)
- OSRLoader (Download it here)
- DbgView (Download it here)
- Visual Studio 2019 (Download it here)
- Do all steps from here to install WDK
- Two hands
- Reboot windows to the mode where it does not check if drivers were signed (Google on it) - otherwise your driver will not start!
- Open VS2019
- Create new project. VS will allow you to choose the type of the project. If you've installed WDK correctly - there will be "KMDF.Empty" type (NOT "KMDF.USB"). Choose it and continue with other steps to create a project
- In 'Sorce Files' copy
main.c
from this repo - Go to Project settings -> C/C++ -> Code creation and disable
Spectre
library - Also in Project settings -> C/C++ -> General set
Warning Level
to1
- Set
Debug
andx64
in VS and build solution (it will create a folder in your project containing.inf
,.sys
and.cat
files) - Run DbgView as administrator. In
Capture
setCapture Kernel
- Run OSRLoader
- In OSRLoader search for
.sys
file created previously Register Service
Run Service
There you go! Now in your DbgView you can see message Random coordinates: ... , ...
(when your've moving the mouse)
That means that the driver is working correctly!