Skip to content
  • There are no suggestions because the search field is empty.

User Choice Protection Driver (UCPD) causing Explorer or icon flickering issues.

 

Resolved in May 2025

This issue was resolved in build 3.1.25141.2 released on 22nd May 2025, if you have a newer version of Migration Agent you do not need to do anything.

In May 2025 Microsoft started rolling out a new enhancement into Windows to prevent the default applications being modified, this is called the User Choice Protection Driver or UCPD.

You may have seen the following errors in the logsFailed to process [HKEY_USERS\<user
SiD>\Software\Microsoft\Windows\Shell\Associations\UrlAssociations\<protocol>\UserChoice] Exception:
System.UnauthorizedAccessException: Attempted to perform an unauthorized operation

We had reports of this error causing explorer to crash, or desktop icons to flash. We have also see the error above reported with no impact too.

This will only impact workstations migrations where you need to perform permission updates to the registry.

We have accounted for this in the most recent build of PowerSyncPro Migration Agent released on 22nd May 2025, version 3.1.25141.2 on our downloads and documentation page. PowerSyncPro - Downloads and Documentation

Migrate workstations seamlessly between Microsoft tenants and AD.

PowerSyncPro Migration Agent has

  • Sub-1% failure rate
  • Built-in resiliency
  • Deep logs & reporting
  • Highly configurable, no need for scripting

However, if you have already deployed Migration Agent to your environment and you are about to perform live migrations, you may want to consider the following workaround, running a Start-up (pre) and Complete (post) script to allow Migration Agent to update the registry.

Here is the code you will need to run in a PowerShell.

Pre-Migration Script

cmdline.cmd

start "" /WAIT PowerShell.exe -ExecutionPolicy Bypass -File ".\UCPDStartup.ps1"

UCPDStartup.ps1

Set-ItemProperty -Path "HKLM:\SYSTEM\CurrentControlSet\Services\UCPD" -Name "Start" -Value 4 -Force
Disable-ScheduledTask -TaskName '\Microsoft\Windows\AppxDeploymentClient\UCPD velocity'

Then zip the two files so they are the only files in the root of the zip, and add to your runbook.

Post-Migration Script

cmdline.cmd

start "" /WAIT PowerShell.exe -ExecutionPolicy Bypass -File ".\UCPDComplete.ps1"

UCPDComplete.ps1

Set-ItemProperty -Path "HKLM:\SYSTEM\CurrentControlSet\Services\UCPD" -Name "Start" -Value 1 -Force
Enable-ScheduledTask -TaskName '\Microsoft\Windows\AppxDeploymentClient\UCPD velocity'

Then zip the two files so they are the only files in the root of the zip, and add to your runbook.

Fix workstation which exhibit the issue post migration.

If your machine has been impacted by this issue, we found the following steps resolve the issue in our lab and circumstances.

Note: This is provided without warranty, please ensure you backup your system before running unsupported scripts.

Using administrative PowerShell, disable UCPD

Set-ItemProperty -Path "HKLM:\SYSTEM\CurrentControlSet\Services\UCPD" -Name "Start" -Value 4 -Force
Disable-ScheduledTask -TaskName '\Microsoft\Windows\AppxDeploymentClient\UCPD velocity'

Now restart the machine, it is important to do this before attempting the next steps.

Using administrative regedit delete the following entry and all sub entries

Computer\HKEY_USERS\<the user sid>\Software\Microsoft\Windows\Shell\Associations\UrlAssociations\http
Computer\HKEY_USERS\<the user sid>\Software\Microsoft\Windows\Shell\Associations\UrlAssociations\https
Computer\HKEY_USERS\<the user sid>\Software\Microsoft\Windows\Shell\Associations\UrlAssociations\pdf
Computer\HKEY_USERS\<the user sid>\Software\Microsoft\Windows\CurrentVersion\Explorer\FileExts\.pdf

Then re-enable UCPD using administrative PowerShell

Set-ItemProperty -Path "HKLM:\SYSTEM\CurrentControlSet\Services\UCPD" -Name "Start" -Value 1 -Force
Enable-ScheduledTask -TaskName '\Microsoft\Windows\AppxDeploymentClient\UCPD velocity'

And restart the machine again