From 3d710e2d2ea614b31b1a052bf5f8ad62721be24c Mon Sep 17 00:00:00 2001 From: Tom Butcher Date: Mon, 3 Aug 2026 01:17:35 +0100 Subject: [PATCH] Remove `grant-users-access.nsh` script from Windows installer packaging - Deleted the `grant-users-access.nsh` script as user access permissions are now managed directly within the installer, streamlining the installation process for standard users. --- packaging/windows/grant-users-access.nsh | 31 ------------------------ 1 file changed, 31 deletions(-) delete mode 100644 packaging/windows/grant-users-access.nsh diff --git a/packaging/windows/grant-users-access.nsh b/packaging/windows/grant-users-access.nsh deleted file mode 100644 index 42cead9..0000000 --- a/packaging/windows/grant-users-access.nsh +++ /dev/null @@ -1,31 +0,0 @@ -; Grant standard (non-admin) users read/execute on the install tree. -; Elevated installs into Program Files often create admin-only ACLs, which -; breaks launcher.exe and deeplink handling for normal users. -!macro grantUsersInstallAccess - Push $0 - Push $1 - DetailPrint "Granting standard users read and execute access to $INSTDIR" - StrCpy $1 "$INSTDIR" - InitPluginsDir - FileOpen $0 "$PLUGINSDIR\grant-access.ps1" w - FileWrite $0 '$$path = "' - FileWrite $0 $1 - FileWrite $0 '"$\r$\n' - FileWrite $0 '$$icacls = Join-Path $$env:SystemRoot "System32\icacls.exe"$\r$\n' - FileWrite $0 'function Invoke-Icacls {$\r$\n' - FileWrite $0 ' param([string[]]$$Arguments)$\r$\n' - FileWrite $0 ' $$proc = Start-Process -FilePath $$icacls -ArgumentList $$Arguments -Wait -PassThru -NoNewWindow$\r$\n' - FileWrite $0 ' Write-Host ("icacls " + ($$Arguments -join " ") + " -> " + $$proc.ExitCode)$\r$\n' - FileWrite $0 '}$\r$\n' - FileWrite $0 'Invoke-Icacls @($$path, "/reset", "/T", "/C")$\r$\n' - FileWrite $0 'Invoke-Icacls @($$path, "/inheritance:e", "/T", "/C")$\r$\n' - FileWrite $0 'Invoke-Icacls @($$path, "/grant", "BUILTIN\Users:(OI)(CI)RX", "/T", "/C")$\r$\n' - FileWrite $0 'Invoke-Icacls @($$path, "/grant", "NT AUTHORITY\Authenticated Users:(OI)(CI)RX", "/T", "/C")$\r$\n' - FileWrite $0 'Invoke-Icacls @($$path, "/grant", "ALL APPLICATION PACKAGES:(OI)(CI)RX", "/T", "/C")$\r$\n' - FileClose $0 - ExecWait '"$SYSDIR\WindowsPowerShell\v1.0\powershell.exe" -NoProfile -ExecutionPolicy Bypass -File "$PLUGINSDIR\grant-access.ps1"' $0 - DetailPrint "Granted Users read/execute (exit code: $0)" - Delete "$PLUGINSDIR\grant-access.ps1" - Pop $1 - Pop $0 -!macroend