SimonS
SimonS

Reputation: 1973

Set-ExecutionPolicy which is the right one?

I have a Powershell script which is stored in a shared Folder on a machine in my Domain. Now I want to run this script on a Server which is in DMZ. What ExecutionPolicy must de domain server and the dmz server have to run this script? "Everyone" has "full rights" to run the script, but It doesn't work.

can I do that with set-executionpolicy?

thanks!

Upvotes: 3

Views: 29681

Answers (1)

Ansgar Wiechers
Ansgar Wiechers

Reputation: 200483

For running remote scripts you either need Set-ExecutionPolicy Unrestricted, run the script with powershell.exe -ExecutionPolicy Bypass, or sign the scripts.

Note that bypassing or changing the execution policy will only work if it's not enforced with a local or group policy.

Upvotes: 7

Related Questions