1

I just created a KMDF Sample driver using Visual Studio 2013 Express with WDK 8.1 on a Windows 7 (64 bit) computer. When I build the solution I get no errors. As I want to check later if my driver is running I inserted the common Debug-Line into my DriverEntry-Routine:

NTSTATUS DriverEntry(...)
{
    DbgPrint("Test\n");
    // ...
}

By the Windows Device Manager I can install the driver manually, by adding a legacy device. Of course Windows will complain about the fact that the driver is not signed. But anyway later I can see the installed driver in the device manager, preceeded by a warning symbol:

a busy cat

With DebugView (from Sysinternals Suite) I am waiting for my debug message to occur, but nothing happens. The only debug messages I get during driver installation is this:

[1768] WdfCoInstaller: [02/07/2018 12:43.22.162] DIF_INSTALLDEVICE: Pre-Processing
[1768] WdfCoInstaller: [02/07/2018 12:43.22.168] ReadComponents:  WdfSection for Driver Service KMDFDriver1 using KMDF lib version Major 1, minor 11 
[1768] WdfCoInstaller: [02/07/2018 12:43.22.177] DIF_INSTALLDEVICE: Coinstaller version: 1.11.0
[1768] WdfCoInstaller: [02/07/2018 12:43.22.185] DIF_INSTALLDEVICE: KMDF in-memory version: 1.11.0
[1768] WdfCoInstaller: [02/07/2018 12:43.22.188] DIF_INSTALLDEVICE: KMDF on-disk version: 1.11.0
[1768] WdfCoInstaller: [02/07/2018 12:43.22.191] Service Wdf01000 is running
[1768] WdfCoInstaller: [02/07/2018 12:43.22.194] DIF_INSTALLDEVICE: Update is not required. The on-disk KMDF version is newer than or same as the version of the coinstaller
[1768] WdfCoInstaller: [02/07/2018 12:43.22.305] DIF_INSTALLDEVICE: Post-Processing

So this leads me to the question why my driver is not running? I guess it has something to do with the signing of the driver, but I also don't know how to sign it. Or maybe DebugView is the wrong tool for this?

user3297416
  • 133
  • 7

1 Answers1

0

Use OSRLOADER to load your device driver for testing purposes. You also may need to perform some registry changes.

You can download OSRLOADER from here: https://www.osronline.com/article.cfm?article=157

Check this question's replies for insight on what to do next regarding DebugView and the registry: No output from DebugView

As for driver signing, go to project properties and choose the Driver Signing tab. You can set the certificate type for testing and then just create a random test certificate. The environment the driver will be tested on however will need to have Test Mode enabled, or be started up with DSE disabled for that session. You can find out more here:

https://learn.microsoft.com/en-us/windows-hardware/drivers/install/how-to-test-sign-a-driver-package

https://learn.microsoft.com/en-us/windows-hardware/drivers/install/the-testsigning-boot-configuration-option

Everything is already documented, all you need to do is a simple Google and you'll have all the information. MSDN alone has quite a lot of content about getting into driver development, driver routine documentation, example source code, even videos sometimes.