Search code examples
c#windowsdevice-driver

Determining if Windows 8 can install device drivers


I need to install unsigned device drivers on Windows 8 machines (getting the drivers signed is not an option at this point in time). I can make this happen by having the user put the machine in a state where it will allow the installation of unsigned drivers. That process is at this web site. How to disable driver signature verification on 64 bit windows 8.1 so that you can install unsigned drivers. After the system is then rebooted, my install process works.

How can it tell in my C# program if the system is in that state where it will be allowed to install unsigned device drivers?

How can I force the system into that state?


Solution

  • You could just try, and if it fails you know why. However it might be worth trying this way:

    1. Ensure your program is running in admin mode (you need this for drivers anyway)
    2. Run bcdedit and capture the STDOUT
    3. Parse the output for nointegritychecks Yes and testsigning Yes (additional whitespace omitted).

    More information can be found here and here.