hacksysteam / HackSysExtremeVulnerableDriver

HackSys Extreme Vulnerable Driver (HEVD) - Windows & Linux
https://hacksys.io
GNU General Public License v3.0
2.42k stars 525 forks source link

Cannot compile HEVD using .SLN file - Errors with Self Signing Certificate #29

Open tekwizz123 opened 5 years ago

tekwizz123 commented 5 years ago

When attempting to compile HEVD using the .SLN file (Visual Studio Project Solution file), the following error is returned:

Invalid argument <HEVD.crt> for property <TestCertificate>. HackSysExtremeVulnerableDriver C:\Program Files (x86)\Windows Kits\10\build\WindowsDriver.common.targets 1422

This is due to the .SLN file still using the HEVD.crt file rather than the HEVD.pfx file which is included.

After testing it appears this doesn't affect the .BAT files as they have already been altered to use the HEVD.pfx file, so only the .SLN file is affected. Discussions about this matter revealed that the issue can likely be fixed by altering the .SLN file to use the HEVD.pfx file and then supplying a valid password in the .SLN file so that HEVD.pfx can be opened and utilized by Visual Studio to sign the driver.

hacksysteam commented 4 years ago

Trying to figure out how to specify a password. Changing it to pfx it pops a dialog box to enter password. I have found that tag works. But it's not accepting the password.

Looking into it currently.

hacksysteam commented 4 years ago

I have changed the CRT to PFX in the project file and also provided Password. Visual Studio still says "Invalid certificate or password". I'm trying to debug the issue.

mailler0xa commented 3 years ago

This is coming in pretty late, but to self-sign it, in the properties page for the project,

Set the Configuration to All Configurations, select either x64 or x86/win32 Paltforms(optional) At the Driver Settings > General, set the Target OS Version as desired (optional) At the Driver Signing > General, set the Test Certificate option to be blank [remove the HEVD.pfx populated there, leaving it blank]

Apply the changes.

Compiling the solution should be successful now. Tested this for win32/x86 and x64 builds for Windows 7-10 platforms, on Visual Studio 2019

reference: https://docs.microsoft.com/en-us/windows-hardware/drivers/develop/signing-a-driver-during-development-and-testing