Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I am well versed in the ways of

Set-ExecutionPolicy RemoteSigned

etc. But for some reason, my machine resets the policy every so often. I have not been able to figure out the pattern, but every week or two I go to run a script and get the dreaded error

foo.ps1 is not digitally signed. The script will not execute on the system.

Is there any way to audit what might be triggering this?

share|improve this question

I am not sure how to go about tracking/auditing what may be causing it - though it sounds a lot like a group policy object has been set to control that and it is getting refreshed every week or so.

I would suggest using rsop.msc or gpresult to view the complete set of policies that are being applied. You could also test this theory by issuing a gpupdate /force from the command line to force a policy refresh.

share|improve this answer
gpupdate /force did not cause the execution policy to revert. I'm on Win7 Home Premium, in a Workgroup, and don't have gpedit.mmc or rsop.mmc. Good theory, though, I really expected gpupdate to cause the issue. – Travis Pettijohn Feb 12 '11 at 14:40
I was able to set the GP in the registry by inspecting the ADM in a text editor: HKLM\Software\Policies\Microsoft\Windows\PowerShell, dword EnableScripts=1, string ExecutionPolicy=RemoteSigned. Setting those to 0, AllSigned and running gpupdate /force I was able to break the execution policy, so these reg values do "something." Hopefully this fixes the problem. – Travis Pettijohn Feb 12 '11 at 15:15

You might check which version of PowerShell is running as well. The policies are different for the 32 and 64 bit versions of PowerShell

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.