libwdi
libwdi copied to clipboard
install_driver_internal UAC elevation does not work correctly
I noticed that while deploying libwdi inside a custom application (not using the Zadig frontend), the UAC elevation logic does not correctly detect if the user is an administrator already. This leads to failed installation due to missing privileges.
Inverting the result of IsUserAnAdmin in install_driver_internal seems to fix the issue.
Relevant PR is #300.
Thanks for submitting this. This indeed looks like an error in the code, and I'll apply the PR when I get a chance...
Fixed in bd17edc3e23d1c7c67dbf78daecc7d3012cae048.