5 ms·
So far I have avoided Powershell in anything distributed to end users, because execution of unsigned scripts is disabled by default in Windows. It has been easi
by unnah 2y ago
So far I have avoided Powershell in anything distributed to end users, because execution of unsigned scripts is disabled by default in Windows. It has been easier to use VBScript or BAT files to automate basic tasks, since those scripts can be run unsigned... I suppose it is too much to hope for that Microsoft would now reconsider enabling Powershell script execution by default.
- workingdog 2y agoWhatever you have that's calling the Powershell script just has to tell the Powershell system that it's ok to run the unsigned script. The default is just to keep people from double-clicking rando Powershell script files and all hell breaking loose.
- lowleveldesign 2y agoI haven't considered the execution policy such a blocker since you may change it on the powershell.exe command line (for example, run "powershell.exe -ExecutionPolicy RemoteSigned -File script.ps1" from a bat file). Also, the default execution policies changed between PowerShell 5.x, shipped with Windows, and modern PowerShell 7.x, which you need to install separately. In 7.x RemoteSigned is the default in the server environment.