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!

1 Answer

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.

Your Answer

Sign up or log in

Sign up using Google Sign up using Facebook Sign up using Email and Password

Post as a guest

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

You Might Also Like