You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When the field ElevationRequirement: elevationRequired is set, MSI installers don't work properly. The issue appears to be that ShellExecute does not know how to use the verb runas for an MSI.
Steps to reproduce
For details and a screenshot of the issue occurring, see:
Windows Package Manager (Preview) v1.3.1391-preview
Copyright (c) Microsoft Corporation. All rights reserved.
Windows: Windows.Desktop v10.0.22808.1000
System Architecture: X64
Package: Microsoft.DesktopAppInstaller v1.18.1391.0
The text was updated successfully, but these errors were encountered:
As for fixing this, the biggest issue is that we want the details from the MSI to be used for the UAC prompt. msiexec does today somehow, but I think that is only in response to some details in the MSI indicating that it needs to be run as administrator. If we attempt to invoke a process as administrator, I don't expect that we can do the same kind of "hey use the details from this file instead" as that seems very insecure.
It is possible that there is some way for us to request that the MSI install service do the elevation via the MSI install APIs. That is the most likely path for making this work while still showing the user the proper information in the UAC.
In the interim, we could fail the attempt before downloading.
In case an MSI has been authored such that it can be installed either per-machine or per-user, you can select it by setting the following properties: https://docs.microsoft.com/en-us/windows/win32/msi/msiinstallperuser.
Maybe those could be used to enforce the manifest's elevationRequired?
Brief description of your issue
When the field
ElevationRequirement: elevationRequired
is set, MSI installers don't work properly. The issue appears to be thatShellExecute
does not know how to use the verbrunas
for an MSI.Steps to reproduce
For details and a screenshot of the issue occurring, see:
Expected behavior
The installer should be run as administrator, with the UAC prompt showing details from the MSI.
Actual behavior
Windows reports not knowing how to handle the file. For details and a screenshot of the issue occurring, see:
Environment
The text was updated successfully, but these errors were encountered: