PowerShell CTP3 is out. It is so excited. But after I installed it in my XP sp3, the Execution-Policy is set to “AllSigned” by default. Even my login has the Administrator rights on my computer, when I tried to run “Set-ExecutionPolicy Unrestricted”, it came out like:
Set-ExecutionPolicy : Windows PowerShell updated your execution policy successfully, but the setting is overridden by a
policy defined at a more specific scope. Due to the override, your shell will retain its current effective execution
policy of “AllSigned”. For more information, please see “Get-Help Set-ExecutionPolicy.”
At line:1 char:20
+ Set-ExecutionPolicy <<<< Unrestricted
+ CategoryInfo : PermissionDenied: (:) [Set-ExecutionPolicy], SecurityException
+ FullyQualifiedErrorId : ExecutionPolicyOverride,Microsoft.PowerShell.Commands.SetExecutionPolicyCommand
The way to fix I found out is change in the registry:
<strong>[HKEY_CURRENT_USERSoftwareMicrosoftPowerShell1ShellIdsMicrosoft.PowerShell]
</strong>