It seems like there is a curse on this package.
Now the entry is created under HKLM, but it is not transferred to HKCU.
Or it is transferred, but not completely. It copies the “Version” entry but not the one for “StubPath”
And this only happens if the user is not a Local Admin. Which is the case for most users in our environment.
In addition, the following message appears when installing with a non-admin account:
“Access to Windows Script Host has been disabled for this computer. Please contact your administrator for further details”
With an admin account, the installation runs indefinitely and is not completed.
With a little testing I was able to ensure that it is this call:
Set-ActiveSetup -StubExePath "C:\Program Files\obs-studio\config.ps1" -Description $installTitle -Key $installName -Arguments "-NoProfile -ExecutionPolicy Bypass -WindowStyle Hidden"
The Log File instead looks fine
<![LOG[[Post-Installation] :: Copying global.ini To User Profiles to Suppress Auto-Configuration Wizard & Disable Auto Updates]LOG]!><time="11:52:10.613120" date="04-03-2024" component="Deploy-Application" context="NT-AUTORITĂ„T\SYSTEM" type="1" thread="14468" file="Deploy-Application.ps1">
<![LOG[[Post-Installation] :: Copying file(s) recursively in path [C:\WINDOWS\ccmcache\42\SupportFiles\config.ps1] to destination [C:\Program Files\obs-studio\].]LOG]!><time="11:52:10.668120" date="04-03-2024" component="Copy-File" context="NT-AUTORITĂ„T\SYSTEM" type="1" thread="14468" file="Deploy-Application.ps1">
<![LOG[[Post-Installation] :: File copy completed successfully.]LOG]!><time="11:52:10.672120" date="04-03-2024" component="Copy-File" context="NT-AUTORITĂ„T\SYSTEM" type="1" thread="14468" file="Deploy-Application.ps1">
<![LOG[[Post-Installation] :: Adding Active Setup Key for local machine: [Registry::HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Active Setup\Installed Components\OBSStudio].]LOG]!><time="11:52:10.721120" date="04-03-2024" component="Set-ActiveSetup" context="NT-AUTORITĂ„T\SYSTEM" type="1" thread="14468" file="Deploy-Application.ps1">
<![LOG[[Post-Installation] :: Creating registry key [Registry::HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Active Setup\Installed Components\OBSStudio].]LOG]!><time="11:52:10.730120" date="04-03-2024" component="Set-RegistryKey" context="NT-AUTORITĂ„T\SYSTEM" type="1" thread="14468" file="Deploy-Application.ps1">
<![LOG[[Post-Installation] :: Setting registry key value: [Registry::HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Active Setup\Installed Components\OBSStudio] [(Default) = OBS Studio].]LOG]!><time="11:52:10.741120" date="04-03-2024" component="Set-RegistryKey" context="NT-AUTORITĂ„T\SYSTEM" type="1" thread="14468" file="Deploy-Application.ps1">
<![LOG[[Post-Installation] :: Setting registry key value: [Registry::HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Active Setup\Installed Components\OBSStudio] [Version = 2404,0311,5210].]LOG]!><time="11:52:10.751120" date="04-03-2024" component="Set-RegistryKey" context="NT-AUTORITĂ„T\SYSTEM" type="1" thread="14468" file="Deploy-Application.ps1">
<![LOG[[Post-Installation] :: Setting registry key value: [Registry::HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Active Setup\Installed Components\OBSStudio] [StubPath = "C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe" -ExecutionPolicy Bypass -NoProfile -NoLogo -WindowStyle Hidden -Command "& {& \"C:\Program Files\obs-studio\config.ps1\"}" -ExecutionPolicy Bypass -WindowStyle Hidden].]LOG]!><time="11:52:10.757120" date="04-03-2024" component="Set-RegistryKey" context="NT-AUTORITĂ„T\SYSTEM" type="1" thread="14468" file="Deploy-Application.ps1">
<![LOG[[Post-Installation] :: Setting registry key value: [Registry::HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Active Setup\Installed Components\OBSStudio] [IsInstalled = 1].]LOG]!><time="11:52:10.764120" date="04-03-2024" component="Set-RegistryKey" context="NT-AUTORITĂ„T\SYSTEM" type="1" thread="14468" file="Deploy-Application.ps1">
<![LOG[[Post-Installation] :: Registry key [Registry::HKEY_USERS\S-1-5-21-1316840750-1972572835-1851928258-36436\Software\Microsoft\Active Setup\Installed Components\OBSStudio] does not exist. Return $null.]LOG]!><time="11:52:10.780120" date="04-03-2024" component="Get-RegistryKey" context="NT-AUTORITĂ„T\SYSTEM" type="2" thread="14468" file="Deploy-Application.ps1">
<![LOG[[Post-Installation] :: Getting registry key [Registry::HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Active Setup\Installed Components\OBSStudio] and all property values.]LOG]!><time="11:52:10.784120" date="04-03-2024" component="Get-RegistryKey" context="NT-AUTORITĂ„T\SYSTEM" type="1" thread="14468" file="Deploy-Application.ps1">
<![LOG[[Post-Installation] :: HKLM active setup entry is present. HKCU active setup entry is not present.]LOG]!><time="11:52:10.789120" date="04-03-2024" component="Set-ActiveSetup" context="NT-AUTORITĂ„T\SYSTEM" type="1" thread="14468" file="Deploy-Application.ps1">
<![LOG[[Post-Installation] :: Session 0 detected: Executing Active Setup StubPath file for currently logged in user [MYDOMAIN.DE\MYUSER].]LOG]!><time="11:52:10.790120" date="04-03-2024" component="Set-ActiveSetup" context="NT-AUTORITĂ„T\SYSTEM" type="1" thread="14468" file="Deploy-Application.ps1">
<![LOG[[Post-Installation] :: Creating [C:\WINDOWS\TEMP\PSAppDeployToolkit\ExecuteAsUser].]LOG]!><time="11:52:10.807120" date="04-03-2024" component="Execute-ProcessAsUser" context="NT-AUTORITĂ„T\SYSTEM" type="1" thread="14468" file="Deploy-Application.ps1">
<![LOG[[Post-Installation] :: Preparing a VBScript that will start [C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe -ExecutionPolicy Bypass -NoProfile -NoLogo -WindowStyle Hidden -Command "& {& \"C:\Program Files\obs-studio\config.ps1\"}" -ExecutionPolicy Bypass -WindowStyle Hidden] as the logged-on user [MYDOMAIN.DE\MYUSER] and suppress the console window...]LOG]!><time="11:52:10.817120" date="04-03-2024" component="Execute-ProcessAsUser" context="NT-AUTORITĂ„T\SYSTEM" type="1" thread="14468" file="Deploy-Application.ps1">
<![LOG[[Post-Installation] :: Setting permissions [Permissions:Read, InheritanceFlags:None, PropagationFlags:None, AccessControlType:Allow, Method:Add] on path [C:\WINDOWS\TEMP\PSAppDeployToolkit\ExecuteAsUser\PSAppDeployToolkit-ExecuteAsUser.vbs] for user [MYDOMAIN.DE\MYUSER].]LOG]!><time="11:52:10.878120" date="04-03-2024" component="Set-ItemPermission" context="NT-AUTORITĂ„T\SYSTEM" type="1" thread="14468" file="Deploy-Application.ps1">
<![LOG[[Post-Installation] :: Setting permissions [Permissions:Read, InheritanceFlags:None, PropagationFlags:None, AccessControlType:Allow, Method:Add] on path [C:\WINDOWS\TEMP\PSAppDeployToolkit\PSAppDeployToolkit-ExecuteAsUser.xml] for user [MYDOMAIN.DE\MYUSER].]LOG]!><time="11:52:10.889120" date="04-03-2024" component="Set-ItemPermission" context="NT-AUTORITĂ„T\SYSTEM" type="1" thread="14468" file="Deploy-Application.ps1">
<![LOG[[Post-Installation] :: Creating scheduled task to run the process [C:\WINDOWS\System32\wscript.exe /e:vbscript "C:\WINDOWS\TEMP\PSAppDeployToolkit\ExecuteAsUser\PSAppDeployToolkit-ExecuteAsUser.vbs"] as the logged-on user [MYDOMAIN.DE\MYUSER]...]LOG]!><time="11:52:10.892120" date="04-03-2024" component="Execute-ProcessAsUser" context="NT-AUTORITĂ„T\SYSTEM" type="1" thread="14468" file="Deploy-Application.ps1">
<![LOG[[Post-Installation] :: [C:\WINDOWS\System32\schtasks.exe] is a valid fully qualified path, continue.]LOG]!><time="11:52:10.897120" date="04-03-2024" component="Execute-Process" context="NT-AUTORITĂ„T\SYSTEM" type="1" thread="14468" file="Deploy-Application.ps1">
<![LOG[[Post-Installation] :: Working Directory is [C:\WINDOWS\System32].]LOG]!><time="11:52:10.899120" date="04-03-2024" component="Execute-Process" context="NT-AUTORITĂ„T\SYSTEM" type="1" thread="14468" file="Deploy-Application.ps1">
<![LOG[[Post-Installation] :: Executing [C:\WINDOWS\System32\schtasks.exe /create /f /tn PSAppDeployToolkit-ExecuteAsUser /xml "C:\WINDOWS\TEMP\PSAppDeployToolkit\PSAppDeployToolkit-ExecuteAsUser.xml"]...]LOG]!><time="11:52:10.901120" date="04-03-2024" component="Execute-Process" context="NT-AUTORITĂ„T\SYSTEM" type="1" thread="14468" file="Deploy-Application.ps1">
<![LOG[[Post-Installation] :: PassThru parameter specified, returning execution results object.]LOG]!><time="11:52:10.989120" date="04-03-2024" component="Execute-Process" context="NT-AUTORITĂ„T\SYSTEM" type="1" thread="14468" file="Deploy-Application.ps1">
<![LOG[[Post-Installation] :: Execution completed successfully with exit code [0].]LOG]!><time="11:52:10.993120" date="04-03-2024" component="Execute-Process" context="NT-AUTORITĂ„T\SYSTEM" type="1" thread="14468" file="Deploy-Application.ps1">
<![LOG[[Post-Installation] :: Triggering execution of scheduled task with command [C:\WINDOWS\System32\wscript.exe /e:vbscript "C:\WINDOWS\TEMP\PSAppDeployToolkit\ExecuteAsUser\PSAppDeployToolkit-ExecuteAsUser.vbs"] as the logged-on user [MYDOMAIN.DE\MYUSER]...]LOG]!><time="11:52:10.997120" date="04-03-2024" component="Execute-ProcessAsUser" context="NT-AUTORITĂ„T\SYSTEM" type="1" thread="14468" file="Deploy-Application.ps1">
<![LOG[[Post-Installation] :: [C:\WINDOWS\System32\schtasks.exe] is a valid fully qualified path, continue.]LOG]!><time="11:52:11.000120" date="04-03-2024" component="Execute-Process" context="NT-AUTORITĂ„T\SYSTEM" type="1" thread="14468" file="Deploy-Application.ps1">
<![LOG[[Post-Installation] :: Working Directory is [C:\WINDOWS\System32].]LOG]!><time="11:52:11.002120" date="04-03-2024" component="Execute-Process" context="NT-AUTORITĂ„T\SYSTEM" type="1" thread="14468" file="Deploy-Application.ps1">
<![LOG[[Post-Installation] :: Executing [C:\WINDOWS\System32\schtasks.exe /run /i /tn PSAppDeployToolkit-ExecuteAsUser]...]LOG]!><time="11:52:11.003120" date="04-03-2024" component="Execute-Process" context="NT-AUTORITĂ„T\SYSTEM" type="1" thread="14468" file="Deploy-Application.ps1">
<![LOG[[Post-Installation] :: PassThru parameter specified, returning execution results object.]LOG]!><time="11:52:11.091120" date="04-03-2024" component="Execute-Process" context="NT-AUTORITĂ„T\SYSTEM" type="1" thread="14468" file="Deploy-Application.ps1">
<![LOG[[Post-Installation] :: Execution completed successfully with exit code [0].]LOG]!><time="11:52:11.094120" date="04-03-2024" component="Execute-Process" context="NT-AUTORITĂ„T\SYSTEM" type="1" thread="14468" file="Deploy-Application.ps1">
<![LOG[[Post-Installation] :: Waiting for the process launched by the scheduled task [PSAppDeployToolkit-ExecuteAsUser] to complete execution (this may take some time)...]LOG]!><time="11:52:11.097120" date="04-03-2024" component="Execute-ProcessAsUser" context="NT-AUTORITĂ„T\SYSTEM" type="1" thread="14468" file="Deploy-Application.ps1">
<![LOG[[Post-Installation] :: Exit code from process launched by scheduled task [1].]LOG]!><time="11:53:47.329120" date="04-03-2024" component="Execute-ProcessAsUser" context="NT-AUTORITĂ„T\SYSTEM" type="1" thread="14468" file="Deploy-Application.ps1">
<![LOG[[Post-Installation] :: Deleting scheduled task [PSAppDeployToolkit-ExecuteAsUser].]LOG]!><time="11:53:47.338120" date="04-03-2024" component="Execute-ProcessAsUser" context="NT-AUTORITĂ„T\SYSTEM" type="1" thread="14468" file="Deploy-Application.ps1">
<![LOG[[Post-Installation] :: [C:\WINDOWS\System32\schtasks.exe] is a valid fully qualified path, continue.]LOG]!><time="11:53:47.350120" date="04-03-2024" component="Execute-Process" context="NT-AUTORITĂ„T\SYSTEM" type="1" thread="14468" file="Deploy-Application.ps1">
<![LOG[[Post-Installation] :: Working Directory is [C:\WINDOWS\System32].]LOG]!><time="11:53:47.374120" date="04-03-2024" component="Execute-Process" context="NT-AUTORITĂ„T\SYSTEM" type="1" thread="14468" file="Deploy-Application.ps1">
<![LOG[[Post-Installation] :: Executing [C:\WINDOWS\System32\schtasks.exe /delete /tn PSAppDeployToolkit-ExecuteAsUser /f]...]LOG]!><time="11:53:47.377120" date="04-03-2024" component="Execute-Process" context="NT-AUTORITĂ„T\SYSTEM" type="1" thread="14468" file="Deploy-Application.ps1">
<![LOG[[Post-Installation] :: Execution completed successfully with exit code [0].]LOG]!><time="11:53:47.438120" date="04-03-2024" component="Execute-Process" context="NT-AUTORITĂ„T\SYSTEM" type="1" thread="14468" file="Deploy-Application.ps1">
<![LOG[[Post-Installation] :: Deleting file in path [C:\WINDOWS\TEMP\PSAppDeployToolkit\PSAppDeployToolkit-ExecuteAsUser.xml]...]LOG]!><time="11:53:47.463120" date="04-03-2024" component="Remove-File" context="NT-AUTORITĂ„T\SYSTEM" type="1" thread="14468" file="Deploy-Application.ps1">
<![LOG[[Post-Installation] :: Deleting folder [C:\WINDOWS\TEMP\PSAppDeployToolkit\ExecuteAsUser] recursively...]LOG]!><time="11:53:47.480120" date="04-03-2024" component="Remove-Folder" context="NT-AUTORITĂ„T\SYSTEM" type="1" thread="14468" file="Deploy-Application.ps1">
<![LOG[[Post-Installation] :: Adding Active Setup Key for the current user: [Registry::HKEY_CURRENT_USER\Software\Microsoft\Active Setup\Installed Components\OBSStudio].]LOG]!><time="11:53:47.487120" date="04-03-2024" component="Set-ActiveSetup" context="NT-AUTORITĂ„T\SYSTEM" type="1" thread="14468" file="Deploy-Application.ps1">
<![LOG[[Post-Installation] :: Creating registry key [Registry::HKEY_USERS\S-1-5-21-1316840750-1972572835-1851928258-36436\Software\Microsoft\Active Setup\Installed Components\OBSStudio].]LOG]!><time="11:53:47.493120" date="04-03-2024" component="Set-RegistryKey" context="NT-AUTORITĂ„T\SYSTEM" type="1" thread="14468" file="Deploy-Application.ps1">
<![LOG[[Post-Installation] :: Setting registry key value: [Registry::HKEY_USERS\S-1-5-21-1316840750-1972572835-1851928258-36436\Software\Microsoft\Active Setup\Installed Components\OBSStudio] [(Default) = OBS Studio].]LOG]!><time="11:53:47.496120" date="04-03-2024" component="Set-RegistryKey" context="NT-AUTORITĂ„T\SYSTEM" type="1" thread="14468" file="Deploy-Application.ps1">
<![LOG[[Post-Installation] :: Setting registry key value: [Registry::HKEY_USERS\S-1-5-21-1316840750-1972572835-1851928258-36436\Software\Microsoft\Active Setup\Installed Components\OBSStudio] [Version = 2404,0311,5210].]LOG]!><time="11:53:47.502120" date="04-03-2024" component="Set-RegistryKey" context="NT-AUTORITĂ„T\SYSTEM" type="1" thread="14468" file="Deploy-Application.ps1">
<![LOG[[Post-Installation] :: Setting registry key value: [Registry::HKEY_USERS\S-1-5-21-1316840750-1972572835-1851928258-36436\Software\Microsoft\Active Setup\Installed Components\OBSStudio] [StubPath = "C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe" -ExecutionPolicy Bypass -NoProfile -NoLogo -WindowStyle Hidden -Command "& {& \"C:\Program Files\obs-studio\config.ps1\"}" -ExecutionPolicy Bypass -WindowStyle Hidden].]LOG]!><time="11:53:47.509120" date="04-03-2024" component="Set-RegistryKey" context="NT-AUTORITĂ„T\SYSTEM" type="1" thread="14468" file="Deploy-Application.ps1">
<![LOG[[Post-Installation] :: Creating registry key [Registry::HKEY_LOCAL_MACHINE\SOFTWARE\SCCM_Software\OBS Project\OBS Studio].]LOG]!><time="11:53:47.515120" date="04-03-2024" component="Set-RegistryKey" context="NT-AUTORITĂ„T\SYSTEM" type="1" thread="14468" file="Deploy-Application.ps1">
<![LOG[[Post-Installation] :: Setting registry key value: [Registry::HKEY_LOCAL_MACHINE\SOFTWARE\SCCM_Software\OBS Project\OBS Studio] [Install = 01].]LOG]!><time="11:53:47.518120" date="04-03-2024" component="Set-RegistryKey" context="NT-AUTORITĂ„T\SYSTEM" type="1" thread="14468" file="Deploy-Application.ps1">
<![LOG[[Post-Installation] :: Setting registry key value: [Registry::HKEY_LOCAL_MACHINE\SOFTWARE\SCCM_Software\OBS Project\OBS Studio] [PackageDate = 27.03.2024].]LOG]!><time="11:53:47.524120" date="04-03-2024" component="Set-RegistryKey" context="NT-AUTORITĂ„T\SYSTEM" type="1" thread="14468" file="Deploy-Application.ps1">
<![LOG[[Post-Installation] :: Setting registry key value: [Registry::HKEY_LOCAL_MACHINE\SOFTWARE\SCCM_Software\OBS Project\OBS Studio] [Publisher = ME].]LOG]!><time="11:53:47.529120" date="04-03-2024" component="Set-RegistryKey" context="NT-AUTORITĂ„T\SYSTEM" type="1" thread="14468" file="Deploy-Application.ps1">
<![LOG[[Post-Installation] :: Setting registry key value: [Registry::HKEY_LOCAL_MACHINE\SOFTWARE\SCCM_Software\OBS Project\OBS Studio] [Version = 30.1.1].]LOG]!><time="11:53:47.535120" date="04-03-2024" component="Set-RegistryKey" context="NT-AUTORITĂ„T\SYSTEM" type="1" thread="14468" file="Deploy-Application.ps1">
<![LOG[[Post-Installation] :: Setting registry key value: [Registry::HKEY_LOCAL_MACHINE\SOFTWARE\SCCM_Software\OBS Project\OBS Studio] [InstallDate = 03.04.2024].]LOG]!><time="11:53:47.542120" date="04-03-2024" component="Set-RegistryKey" context="NT-AUTORITĂ„T\SYSTEM" type="1" thread="14468" file="Deploy-Application.ps1">
<![LOG[[Post-Installation] :: The installation progress dialog does not exist. Waiting up to 5 seconds...]LOG]!><time="11:53:47.557120" date="04-03-2024" component="Close-InstallationProgress" context="NT-AUTORITĂ„T\SYSTEM" type="1" thread="14468" file="Deploy-Application.ps1">
<![LOG[[Post-Installation] :: The installation progress dialog was not created within 5 seconds.]LOG]!><time="11:53:52.599120" date="04-03-2024" component="Close-InstallationProgress" context="NT-AUTORITĂ„T\SYSTEM" type="2" thread="14468" file="Deploy-Application.ps1">
<![LOG[[Post-Installation] :: OBSStudio Installation completed with exit code [0].]LOG]!><time="11:53:52.633120" date="04-03-2024" component="Exit-Script" context="NT-AUTORITĂ„T\SYSTEM" type="1" thread="14468" file="Deploy-Application.ps1">
<![LOG[[Post-Installation] :: Checking if PowerPoint is in either fullscreen slideshow mode or presentation mode...]LOG]!><time="11:53:52.660120" date="04-03-2024" component="Test-PowerPoint" context="NT-AUTORITĂ„T\SYSTEM" type="1" thread="14468" file="Deploy-Application.ps1">
<![LOG[[Post-Installation] :: PowerPoint application is not running.]LOG]!><time="11:53:52.680120" date="04-03-2024" component="Test-PowerPoint" context="NT-AUTORITĂ„T\SYSTEM" type="1" thread="14468" file="Deploy-Application.ps1">
<![LOG[[Post-Installation] :: PowerPoint is running in fullscreen mode [False].]LOG]!><time="11:53:52.685120" date="04-03-2024" component="Test-PowerPoint" context="NT-AUTORITĂ„T\SYSTEM" type="1" thread="14468" file="Deploy-Application.ps1">
<![LOG[[Post-Installation] :: Displaying balloon tip notification asynchronously with message [Installation abgeschlossen.].]LOG]!><time="11:53:52.692120" date="04-03-2024" component="Show-BalloonTip" context="NT-AUTORITĂ„T\SYSTEM" type="1" thread="14468" file="Deploy-Application.ps1">
<![LOG[[Post-Installation] :: [C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe] is a valid fully qualified path, continue.]LOG]!><time="11:53:52.700120" date="04-03-2024" component="Execute-Process" context="NT-AUTORITĂ„T\SYSTEM" type="1" thread="14468" file="Deploy-Application.ps1">
<![LOG[[Post-Installation] :: Working Directory is [C:\Windows\System32\WindowsPowerShell\v1.0].]LOG]!><time="11:53:52.704120" date="04-03-2024" component="Execute-Process" context="NT-AUTORITĂ„T\SYSTEM" type="1" thread="14468" file="Deploy-Application.ps1">
<![LOG[[Post-Installation] :: Executing [C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe [PowerShell ScriptBlock]]...]LOG]!><time="11:53:52.707120" date="04-03-2024" component="Execute-Process" context="NT-AUTORITĂ„T\SYSTEM" type="1" thread="14468" file="Deploy-Application.ps1">
<![LOG[[Post-Installation] :: NoWait parameter specified. Continuing without waiting for exit code...]LOG]!><time="11:53:52.719120" date="04-03-2024" component="Execute-Process" context="NT-AUTORITĂ„T\SYSTEM" type="1" thread="14468" file="Deploy-Application.ps1">
<![LOG[[Post-Installation] :: -------------------------------------------------------------------------------]LOG]!><time="11:53:52.726120" date="04-03-2024" component="Exit-Script" context="NT-AUTORITĂ„T\SYSTEM" type="1" thread="14468" file="Deploy-Application.ps1">
Problem only occurs if the application is deployed via SCCM