nvidia-kvm-patcher icon indicating copy to clipboard operation
nvidia-kvm-patcher copied to clipboard

Syntax Error?

Open Zebouski opened this issue 6 years ago • 5 comments

When running the script from master, like: .\patcher.ps1 "C:\NVIDIA\DisplayDriver\430.64\Win10_64\International\Display.Driver\" I get the following error:

Certificate Path:  C:\Users\zebou\nvidia-kvm-patcher\TestSign.cer
Certificate Found In Root Store                                                                                  
    [+] Signing Catalog File                                                                                 
The expression after '&' in a pipeline element produced an object that was not valid. It must result in a    command name, a script block, or a CommandInfo object.                                                       
At C:\Users\zebou\nvidia-kvm-patcher\patcher.ps1:156 char:3                                                  
+ & $signtool sign /v /n SKSoftware /t http://timestamp.verisign.com/sc ...                                  
+   ~~~~~~~~~                                                                                                    
    + CategoryInfo          : InvalidOperation: (:String) [], RuntimeException                                   
    + FullyQualifiedErrorId : BadExpression                                                                                                                                                                               
The expression after '&' in a pipeline element produced an object that was not valid. It must result in a    command name, a script block, or a CommandInfo object.                                                       
At C:\Users\zebou\nvidia-kvm-patcher\patcher.ps1:157 char:3                                                  
+ & $signtool sign /v /n SKSOftware /t http://timestamp.verisign.com/sc ...                                  
+   ~~~~~~~~~                                                                                                    
    + CategoryInfo          : InvalidOperation: (:String) [], RuntimeException                                   
    + FullyQualifiedErrorId : BadExpression                                                                                                                                                                               
PS C:\Users\zebou\nvidia-kvm-patcher>

I'm getting this when running on files from the latest "430.64-desktop-win10-64bit-international-whql.exe" and also the older version I saw you tested on "419.67-desktop-win10-64bit-international-whql.exe"

Test Mode down at the bottom right says Build 17763.rs5_release.180914-1434

Zebouski avatar May 14 '19 07:05 Zebouski

Same here. 149.34-nview-desktop-win10-win7-64bit-international-whql Build 17134.rs4_release.180410-1804

goulimis avatar May 16 '19 12:05 goulimis

Same here:

Certificate Path:  C:\Users\tristank\Downloads\nvidia-kvm-patcher-master\TestSign.cer
Certificate Found In Root Store
    [+] Signing Catalog File
Der Ausdruck nach "&" in einem Pipelineelement hat ein ungültiges Objekt erzeugt. Der Ausdruck muss einen Befehlsnamen, Skriptblock oder ein CommandInfo-Objekt ergeben.
In C:\Users\tristank\Downloads\nvidia-kvm-patcher-master\patcher.ps1:156 Zeichen:3
+ & $signtool sign /v /n SKSoftware /t http://timestamp.verisign.com/sc ...
+   ~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:String) [], RuntimeException
    + FullyQualifiedErrorId : BadExpression

Der Ausdruck nach "&" in einem Pipelineelement hat ein ungültiges Objekt erzeugt. Der Ausdruck muss einen Befehlsnamen, Skriptblock oder ein CommandInfo-Objekt ergeben.
In C:\Users\tristank\Downloads\nvidia-kvm-patcher-master\patcher.ps1:157 Zeichen:3
+ & $signtool sign /v /n SKSOftware /t http://timestamp.verisign.com/sc ...
+   ~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:String) [], RuntimeException
    + FullyQualifiedErrorId : BadExpression

tristan-k avatar May 16 '19 20:05 tristan-k

I was also looking into this; I ended up resolving it through a 2 step process.

First, while I had installed Visual Studio 2019, I failed to install the Windows SDK and also the SDK tools (not certain the whole SDK is required). I had to go back to the installer and modify my install as shown below:

Annotation 2019-05-19 181343

After that installed, and I restarted for good measure, I also modified the signtool_paths in the script on line 91 to add this string in the first position, as it seems to be the new location for signtool.exe:

'C:\Program Files (x86)\Windows Kits\10\App Certification Kit\signtool.exe'

The script ran successfully after that, but I do not yet know if the modified driver will work.

Addendum: I also had to install the Windows Driver Kit using the instructions provided here to provide the Inf2Cat executable

warrenpw avatar May 20 '19 01:05 warrenpw

I was also looking into this; I ended up resolving it through a 2 step process.

First, while I had installed Visual Studio 2019, I failed to install the Windows SDK and also the SDK tools (not certain the whole SDK is required). I had to go back to the installer and modify my install as shown below:

Annotation 2019-05-19 181343

After that installed, and I restarted for good measure, I also modified the signtool_paths in the script on line 91 to add this string in the first position, as it seems to be the new location for signtool.exe:

'C:\Program Files (x86)\Windows Kits\10\App Certification Kit\signtool.exe'

The script ran successfully after that, but I do not yet know if the modified driver will work.

Addendum: I also had to install the Windows Driver Kit using the instructions provided here to provide the Inf2Cat executable

Hey -

Did you ever get this to run properly on your end? I was able to get the driver to run and install, but on my end its still showing error 43. Running ESXI 6.7u2

fosser2 avatar Jun 12 '19 00:06 fosser2

Unfortunately, while I was able to get the patching script running, I was unable to prevent the driver from throwing error code 43.

warrenpw avatar Jun 12 '19 21:06 warrenpw