libwdi icon indicating copy to clipboard operation
libwdi copied to clipboard

zadig-2.9 silently crashes when pressing "Install Driver"

Open DmitryBondarenko opened this issue 4 months ago • 2 comments

Image

Image shows last message in log window before app silently closes.

DmitryBondarenko avatar Aug 30 '25 00:08 DmitryBondarenko

Can you please download and run DebugView from https://learn.microsoft.com/en-us/sysinternals/downloads/debugview and see if it has more info? Zadig also sends its output there, and it might have some extra data that could explain the crash, as I'm afraid I have exactly nothing to work on to even beging trying to investigate the cause of the crash (which seems linked to your specific environment/device).

You can also take a look at the entries from your C:\Windows\INF\setupapi.dev.log at the time of the crash (if the driver installation process actually starts).

Or, if you really wanna help, the best thing for you to do is follow the steps described at https://github.com/pbatard/libwdi/wiki/Compiling-and-debugging-libwdi-or-Zadig and debug Zadig using Visual Studio 2022, because this will tell us exactly why the crash happens.

pbatard avatar Aug 31 '25 00:08 pbatard

Hi Pete,

Thanks for pointing me to detailed compilation guide. I've compiled libwdi and Zadig using current source tree. Compiled version doesn't hang and print debug output including error:

Zadig 2.9.792
Windows 11 Pro, x64 (Build 26100.5074)
ini file 'zadig.ini' not found in 'C:\Users\dmitry\Desktop\GitHub\libwdi\x64\Debug\examples' - default parameters will be used
default driver set to 'WinUSB'
2 devices found.
libwdi:debug [wdi_create_list] Hardware ID: USB\VID_0BDA&PID_2838&REV_0100&MI_00
libwdi:debug [wdi_create_list] Compatible ID: USB\COMPAT_VID_0bda&Class_ff&SubClass_ff&Prot_ff
libwdi:debug [wdi_create_list] Driverless USB device (0): USB\VID_0BDA&PID_2838&MI_00\6&38A180A5&0&0000
libwdi:debug [wdi_create_list] Device description: 'Bulk-In, Interface (Interface 0)'
libwdi:debug [wdi_create_list] Hardware ID: USB\VID_0BDA&PID_2838&REV_0100&MI_01
libwdi:debug [wdi_create_list] Compatible ID: USB\COMPAT_VID_0bda&Class_ff&SubClass_ff&Prot_ff
libwdi:debug [wdi_create_list] Driverless USB device (3): USB\VID_0BDA&PID_2838&MI_01\6&38A180A5&0&0001
libwdi:debug [wdi_create_list] Device description: 'Bulk-In, Interface (Interface 1)'
Using inf name: Bulk-In_Interface_(Interface_0).inf
Could not extract files
Driver Installation: FAILED (System policy has been modified to reject unsigned drivers)
libwdi:info [extract_binaries] Successfully extracted driver files to 'C:\Users\dmitry\usb_driver'
libwdi:info [wdi_prepare_driver] Successfully created 'C:\Users\dmitry\usb_driver\Bulk-In_Interface_(Interface_0).inf'
libwdi:info [wdi_prepare_driver] Creating and self-signing a .cat file...
libwdi:info [wdi_prepare_driver] Test signing is: Disabled
libwdi:debug [AddFileHash] 'wdfcoinstaller01011.dll': PE type
libwdi:info [ScanDirAndHash] added hash for 'C:\Users\dmitry\usb_driver\amd64\wdfcoinstaller01011.dll'
libwdi:debug [AddFileHash] 'winusbcoinstaller2.dll': PE type
libwdi:info [ScanDirAndHash] added hash for 'C:\Users\dmitry\usb_driver\amd64\winusbcoinstaller2.dll'
libwdi:debug [AddFileHash] 'bulk-in_interface_(interface_0).inf': INF type
libwdi:info [ScanDirAndHash] added hash for 'C:\Users\dmitry\usb_driver\bulk-in_interface_(interface_0).inf'
libwdi:info [CreateCat] Successfully created file 'C:\Users\dmitry\usb_driver\Bulk-In_Interface_(Interface_0).cat'
libwdi:info [RemoveCertFromStore] Deleted existing certificate 'CN=USB\VID_0BDA&PID_2838&MI_00 (libwdi autogenerated)' from 'Root' store
libwdi:info [RemoveCertFromStore] Deleted existing certificate 'CN=USB\VID_0BDA&PID_2838&MI_00 (libwdi autogenerated)' from 'TrustedPublisher' store
libwdi:debug [CreateSelfSignedCert] Set Enhanced Key Usage, URL and CPS
libwdi:debug [CreateSelfSignedCert] Created new key container
libwdi:debug [CreateSelfSignedCert] Generated new keypair...
libwdi:info [CreateSelfSignedCert] Created new self-signed certificate 'CN=USB\VID_0BDA&PID_2838&MI_00 (libwdi autogenerated)'
libwdi:debug [SelfSignFile] Successfully created certificate 'CN=USB\VID_0BDA&PID_2838&MI_00 (libwdi autogenerated)'
libwdi:info [SelfSignFile] Added certificate 'CN=USB\VID_0BDA&PID_2838&MI_00 (libwdi autogenerated)' to 'Root' and 'TrustedPublisher' stores
libwdi:warning [SelfSignFile] SignerSignEx failed: Unknown PKI error 0x80090008
libwdi:info [SelfSignFile] Successfully deleted private key
libwdi:error [wdi_prepare_driver] Could not sign cat file 

DmitryBondarenko avatar Sep 03 '25 00:09 DmitryBondarenko