• Welcome to TechPowerUp Forums, Guest! Please check out our forum guidelines for info related to our community.

How to sign your own modded drivers

Joined
Dec 8, 2020
Messages
509 (3.89/day)
For those interested in making their own drivers, for any reason, and would like to sign it, allowing them to share it with others.

----

Step 1:

You can create a self-signed Code Signing certificate without using third-party tools by using the PowerShell 5.0 cmdlet – New-SelfSifgnedCertificate:

$Cert = New-SelfSignedCertificate -Subject "SIGNERNAME” -Type CodeSigningCert -CertStoreLocation cert:\LocalMachine\My


Then you need to export this certificate to the pfx file with the password:

$CertPassword = ConvertTo-SecureString -String “P@ssw0rd” -Force –AsPlainText
Export-PfxCertificate -Cert $Cert -FilePath C:\DriverCert\NAME.pfx -Password $CertPassword

----

Step 2:

Download WoSignCode, and its operation manual (its very easy to use), you only need the 'Code Signing' and 'CAB/CAT' options, and internet.
You will need to make a basic powershell and command prompt batch file, and modded shortcut (example here).

Note: The tool requires internet connect for timestamps and file virus scanning.

Now .7z .zip, .rar your signed worked and share!
 

Solaris17

Dainty Moderator
Staff member
Joined
Aug 16, 2005
Messages
22,120 (3.86/day)
Location
Florida
System Name Venslar
Processor I9 7980XE
Motherboard MSI x299 Tomahawk Arctic
Cooling EK Custom
Memory 32GB Corsair DDR4 3000mhz
Video Card(s) Nvidia Titan RTX
Storage 1x 250GB 960 EVO | 1x 500gb Intel 720p | 32TB SAN
Display(s) 3x AOC Q2577PWQ (2k IPS)
Case Inwin 303 White (Thermaltake Ring 120mm Purple accent)
Audio Device(s) Schiit Fulla 3 on Beyerdynamic DT 990 Pros
Power Supply Seasonic 1050W Snow
Mouse Roccat Kone Aimo White
Keyboard Ducky Shine 6 Snow White
Software Windows 10 x64 Pro
What is the example? Its just some audio installer on mega upload.
 
Joined
Dec 8, 2020
Messages
509 (3.89/day)
The install shortcut and batch file. Self elevated with non admin functionality, double click install. No installer method, using official Microsoft commands.

1.png 2.png

This method allows receivers to can scan the files freely, not hidden behind installers, or password bypasses (.zip).
 
Last edited:

Solaris17

Dainty Moderator
Staff member
Joined
Aug 16, 2005
Messages
22,120 (3.86/day)
Location
Florida
System Name Venslar
Processor I9 7980XE
Motherboard MSI x299 Tomahawk Arctic
Cooling EK Custom
Memory 32GB Corsair DDR4 3000mhz
Video Card(s) Nvidia Titan RTX
Storage 1x 250GB 960 EVO | 1x 500gb Intel 720p | 32TB SAN
Display(s) 3x AOC Q2577PWQ (2k IPS)
Case Inwin 303 White (Thermaltake Ring 120mm Purple accent)
Audio Device(s) Schiit Fulla 3 on Beyerdynamic DT 990 Pros
Power Supply Seasonic 1050W Snow
Mouse Roccat Kone Aimo White
Keyboard Ducky Shine 6 Snow White
Software Windows 10 x64 Pro
Code:
@echo

"%CD%\BIN\elevate" powershell Import-PfxCertificate -FilePath '%CD%\BIN\signed.pfx' -Password (ConvertTo-SecureString -String 'P@ss0wrd' -AsPlainText -Force) -CertStoreLocation Cert:\LocalMachine\Root

timeout 6

"%CD%\BIN\elevate" pnputil -i -a "%CD%\WIN10\*.inf"

exit

for those that don't want to download the drivers.

You should also be able to forego the elevate.exe and simply have the batch self elevate like so:

Code:
@echo off

:: Self execute as admin by creating a VBS that calls myself.
SETLOCAL EnableDelayedExpansion
for /F "tokens=1,2 delims=#" %%a in ('"prompt #$H#$E# & Echo on & for %%b in (1) do     rem"') do (
  set "DEL=%%a"
)
title PC Deploy v1.8.4
cls

:checkPrivileges 
NET FILE 1>NUL 2>NUL
if '%errorlevel%' == '0' ( goto main) else ( goto getPrivileges ) 

:getPrivileges 
if '%1'=='ELEV' (shift & goto main)                               
for /f "delims=: tokens=*" %%A in ('findstr /b ::- "%~f0"') do @Echo(%%A
setlocal DisableDelayedExpansion
set "batchPath=%~0"
setlocal EnableDelayedExpansion
Echo Set UAC = CreateObject^("Shell.Application"^) > "%temp%\OEgetPrivileges.vbs" 
Echo UAC.ShellExecute "!batchPath!", "ELEV", "", "runas", 1 >> "%temp%\OEgetPrivileges.vbs" 
"%temp%\OEgetPrivileges.vbs" 
exit /B
echo.

:main
powershell Import-PfxCertificate -FilePath '%CD%\BIN\signed.pfx' -Password (ConvertTo-SecureString -String 'P@ss0wrd' -AsPlainText -Force) -CertStoreLocation Cert:\LocalMachine\Root

timeout 6

pnputil -i -a "%CD%\WIN10\*.inf"

exit
 
Top