64 and 32 bit PowerShell execution policies stored separately

Just stumbled upon this due to some confusion about the version of PowerShell I was running on my 64 bit Vista machine. I ran PowerShell from the start menu, using the context menu to bring it up as Administrator. Then I set the execution policy to RemoteSigned:

Set-ExecutionPolicy RemoteSigned

I ran PowerShell as a normal user (through SlickRun – brought up the 32 bit PowerShell without me noticing at first), tried to run a script and it failed. Get-ExecutionPolicy still showed Restricted. Wtf?

Turns out that the execution policies for 32 and 64 bit PowerShells are stored separately. I don’t know, I can’t figure out any value in this apart from the obvious "let’s fuck with their minds" conspiracy idea. Probably something that wasn’t really done on purpose, but still pretty important to know.

Leave a Comment

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s