microsoft / winget-pkgs

The Microsoft community Windows Package Manager manifest repository
MIT License
8.69k stars 4.53k forks source link

Disable mandatory ASLR for Everything installer #18906

Closed NN--- closed 3 years ago

NN--- commented 3 years ago

Create issues related to the winget.exe client here

Brief description of your issue

Steps to reproduce

Enable Mandatory ASLR for all progras. Install Everything using winget install voidtools.Everything

Expected behavior

Installation works

Actual behavior

Installation crashes due to mandatory ASLR.

The solution should be to disable for mandatory ASLR for Everything installer and then run it.

quhxl commented 3 years ago

Maybe we should switch to the MSI installer. https://www.voidtools.com/forum/viewtopic.php?t=6689

OfficialEsco commented 3 years ago

Didn't even notice the MSI, do you know of any custom switches for the exe or msi?

quhxl commented 3 years ago

This is what the installer shows.


Windows ® Installer. V 5.0.21996.1 

msiexec /Option <Required Parameter> [Optional Parameter]

Install Options
    </package | /i> <Product.msi>
        Installs or configures a product
    /a <Product.msi>
        Administrative install - Installs a product on the network
    /j<u|m> <Product.msi> [/t <Transform List>] [/g <Language ID>]
        Advertises a product - m to all users, u to current user
    </uninstall | /x> <Product.msi | ProductCode>
        Uninstalls the product
Display Options
    /quiet
        Quiet mode, no user interaction
    /passive
        Unattended mode - progress bar only
    /q[n|b|r|f]
        Sets user interface level
        n - No UI
        b - Basic UI
        r - Reduced UI
        f - Full UI (default)
    /help
        Help information
Restart Options
    /norestart
        Do not restart after the installation is complete
    /promptrestart
        Prompts the user for restart if necessary
    /forcerestart
        Always restart the computer after installation
Logging Options
    /l[i|w|e|a|r|u|c|m|o|p|v|x|+|!|*] <LogFile>
        i - Status messages
        w - Nonfatal warnings
        e - All error messages
        a - Start up of actions
        r - Action-specific records
        u - User requests
        c - Initial UI parameters
        m - Out-of-memory or fatal exit information
        o - Out-of-disk-space messages
        p - Terminal properties
        v - Verbose output
        x - Extra debugging information
        + - Append to existing log file
        ! - Flush each line to the log
        * - Log all information, except for v and x options
    /log <LogFile>
        Equivalent of /l* <LogFile>
Update Options
    /update <Update1.msp>[;Update2.msp]
        Applies update(s)
    /uninstall <PatchCodeGuid>[;Update2.msp] /package <Product.msi | ProductCode>
        Remove update(s) for a product
Repair Options
    /f[p|e|c|m|s|o|d|a|u|v] <Product.msi | ProductCode>
        Repairs a product
        p - only if file is missing
        o - if file is missing or an older version is installed (default)
        e - if file is missing or an equal or older version is installed
        d - if file is missing or a different version is installed
        c - if file is missing or checksum does not match the calculated value
        a - forces all files to be reinstalled
        u - all required user-specific registry entries (default)
        m - all required computer-specific registry entries (default)
        s - all existing shortcuts (default)
        v - runs from source and recaches local package
Setting Public Properties
    [PROPERTY=PropertyValue]

Consult the Windows ® Installer SDK for additional documentation on the
command line syntax.

Copyright © Microsoft Corporation. All rights reserved.
Portions of this software are based in part on the work of the Independent JPEG Group.

I tried it with /passive only and it worked fine with the MSI installer.

quhxl commented 3 years ago

@OfficialEsco If we do this: Should we remove the EXE installer completely and switch to the MSI or should we create a new manifest, like with Anydesk?

OfficialEsco commented 3 years ago

Thats just the standard MSI switches, the software can have custom switches which is not listed on that.

18969 should make MSI the default one, the EXE needs to be there for upgrade purposes.

AnyDesk is only split because it have a different PackageName between the exe and msi which is dumb on AnyDesk's part..

quhxl commented 3 years ago

@OfficialEsco Is this what you are looking for? https://www.voidtools.com/support/everything/command_line_options

OfficialEsco commented 3 years ago

@OfficialEsco Is this what you are looking for? https://www.voidtools.com/support/everything/command_line_options

Yup 🙄 So according to https://www.voidtools.com/forum/viewtopic.php?t=6689 we can't fix this And according to https://www.voidtools.com/support/everything/command_line_options the switches we can use is

-app-data
-noapp-data
-choose-language
-choose-volumes
-service-port <port>
-service-pipe-name <name>
-enable-run-as-admin
-disable-run-as-admin
-enable-update-notification
-disable-update-notification
-install <location>
-install-client-service
-install-config <filename>
-install-desktop-shortcut (One or the other)
-install-all-users-desktop-shortcut (One or the other)
-install-efu-association (Useful?)
-uninstall-efu-association
-install-folder-context-menu (Useful)
-install-options <command line options>
-install-quick-launch-shortcut (Useful i guess?)
-install-run-on-system-startup (Useful)
-install-service
-uninstall-service
-install-service-port <port>
-install-service-pipe-name <name>
-install-start-menu-shortcuts (One or the other)
-install-all-users-start-menu-shortcuts (One or the other)
-install-url-protocol
-language <langID>
-create-usn-journal <volume> <max-size-bytes> <allocation-delta-bytes>
-install-language <langID>
-save-install-options <user-install-option-flags>
quhxl commented 3 years ago

@OfficialEsco What do you mean with "we can't fix this"?

quhxl commented 3 years ago

The solution to the problem is to use the MSI installer instead of the EXE installer.

OfficialEsco commented 3 years ago

Ahh i see hes giving workaround methods I just saw the No guys, its the W10 Mandatory ASLR scheme of device defense. and expected a request for a command to prompt Windows Defender for permission to change ASLR setting 🤦‍♂️

quhxl commented 3 years ago

@NN--- Does it work now?

NN--- commented 3 years ago
>winget install voidtools.Everything
Found Everything [voidtools.Everything]
This application is licensed to you by its owner.
Microsoft is not responsible for, nor does it grant any licenses to, third-party packages.
Downloading https://www.voidtools.com/Everything-1.4.1.1009.x64-Setup.exe
Package download canceled.

WinGet still downloads the exe installer, not MSI.

OfficialEsco commented 3 years ago

The PR is not merged yet. Gonna be a few more hours until another moderator comes around…

quhxl commented 3 years ago

@NN--- Now it merged.

NN--- commented 3 years ago

Now it is installed. Thanks.

If this is possible, please test all packages with mandatory ASLR and mandatory DEP for all applications.

quhxl commented 3 years ago

This should be considered. You can close this issue now.