PSWindowsUpdate icon indicating copy to clipboard operation
PSWindowsUpdate copied to clipboard

access denied for windows server 2025

Open octavmarius opened this issue 1 month ago • 2 comments

i get this error only for remote computers with windows server 2025. for any other operating system version it works just fain (2022, 2019, 2016).

Get-WindowsUpdate -ComputerName computername
Get-WindowsUpdate : Access is denied. (Exception from HRESULT: 0x80070005 (E_ACCESSDENIED))
At line:1 char:1
+ Get-WindowsUpdate -ComputerName computername
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : NotSpecified: (:) [Get-WindowsUpdate], UnauthorizedAccessException
    + FullyQualifiedErrorId : System.UnauthorizedAccessException,PSWindowsUpdate.GetWindowsUpdate

for the same computers (with windows server 2025) other remote powershell command works ok. so it's not related with user permissions (i use a domain admin account), firewall permissions, powershell remoting....

is this happend only for me ?

thanks for looking into this.

octavmarius avatar Dec 08 '25 14:12 octavmarius

PS> $Error[0] | format-list * -Force


PSMessageDetails      :
Exception             : System.UnauthorizedAccessException: Access is denied. (Exception from HRESULT: 0x80070005 (E_ACCESSDENIED))
                           at WUApiLib.IUpdateSession3.CreateUpdateSearcher()
                           at PSWindowsUpdate.GetWindowsUpdate.CoreProcessing()
                           at PSWindowsUpdate.GetWindowsUpdate.ProcessRecord()
                           at System.Management.Automation.CommandProcessor.ProcessRecord()
TargetObject          :
CategoryInfo          : NotSpecified: (:) [Get-WindowsUpdate], UnauthorizedAccessException
FullyQualifiedErrorId : System.UnauthorizedAccessException,PSWindowsUpdate.GetWindowsUpdate
ErrorDetails          :
InvocationInfo        : System.Management.Automation.InvocationInfo
ScriptStackTrace      : at <ScriptBlock>, <No file>: line 1
PipelineIterationInfo : {}

octavmarius avatar Dec 08 '25 14:12 octavmarius

Experiencing the same issue.

Since October CU 2025 updates, also unable to remotely run any commands from the PSWindowsUpdate module for Windows Server 2025. Our script, which uses the Invoke-WUJob to remotely install updates across our server estate is now failing on Windows 2025 servers but working successfully on 2016, 2019, 2022. In fact, none of the PSWindowsUpdate commands are working and give the same Access denied error.

nikkiparker avatar Dec 18 '25 09:12 nikkiparker

Same issue here, since installing these two patches (on Windows Server 2025), it no longer works:

KB5066131 (71MB) 2025-10 Cumulative Update for .NET Framework 3.5 and 4.8.1 for Microsoft se ... KB5068861 (12GB) 2025-11 Cumulative Update for Microsoft server operating system version 24H ...

(Edit: I tried uninstalling KB5066131 and the issue still persists, so the culprit appears to be KB5068861)

Same error that @octavmarius , Ps Module version: 2.2.1.5

I have already run Reset-WUComponents, rebooted the system, and executed Enable-WURemoting. None of these steps have resolved the issue so far.

I am unable to remotely call Get-WUList, either using Get-WUList -ComputerName XXX or Invoke-Command XXX { Get-WUList }. However, running it locally works without errors, using the same administrative credentials.

Please let us know if there is any additional feedback or diagnostics we can provide.

misejoh avatar Dec 30 '25 18:12 misejoh