Why is Windows asking for system administrator privileges for running executables with "install" in their name?

This is part of the heuristics present in Windows Vista and later. From here if the file contains the words "install", "setup", "update" or "patch" - installer is assumed.

You can prevent this by adding the following to your manifest

<requestedExecutionLevel level="asInvoker" />

I've found a working solution here: https://github.com/bmatzelle/gow/issues/156

Quote:

The solution is to write a manifest file listed below for the executables, in order to persuade UAC that it does not require administrative privilege.

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0">
  <trustInfo xmlns="urn:schemas-microsoft-com:asm.v3">
    <security>
      <requestedPrivileges>
        <!-- Make sure that UAC believes
        that it does not require administrative privilege -->
        <requestedExecutionLevel level="asInvoker" uiAccess="false"/>
      </requestedPrivileges>
    </security>
  </trustInfo>
</assembly>

The filenames of the manifest files should be install.exe.manifest and patch.exe.manifest, and then put them in the same folder as install.exe and patch.exe.

If the UAC prompt still pops up, change the timestamp of install.exe and patch.exe to persuade Windows to pick up the new manifest file.


If I remember correctly you can disable this behaviour the following way (quoted from Technet):

  1. Click Start, click All Programs, click Accessories, click Run, type secpol.msc in the Open text box, and then click OK.

  2. From the Local Security Settings console tree, click Local Policies, and then click Security Options.

  3. Scroll down and double-click User Account Control: Detect application installations and prompt for elevation.

  4. Select the Disabled option, and then click OK.

  5. Close the Local Security Settings window.

You may need to re-logon for the setting to take effect.