PowerShell.exe is not a Microsoft-Verified App
The error is known to happen on Windows 10 S or Windows 10 in S mode or secure mode, where only verified apps can be installed and executed. If another application is trying to launch a program in PowerShell or another tool that uses PowerShell or needs related applications, Windows will not allow it. In Windows 10 S mode, Windows will only run Microsoft-Verified Apps. So what is the solution for this? The only way is to switch out of Windows 10 S mode.
How to Switch to Windows 10 Pro or Enterprise from S Mode
If you have this on your personal PC, you can use the Microsoft Store. However, if an Enterprise manages your laptop or Windows PC, you can ask your IT admin to use Intune to remove the S mode restriction.
Using Microsoft Store
Using Intune
Can I use any other browser apart from Microsoft Edge in S Mode?
While you can use any browser when in S mode, you cannot set it as the default browser. Another problem is that the browser should be available in the Microsoft Store, and that’s a big problem. Eventually, you are left with the Edge browser.
Do I need antivirus software while in S mode?
Yes, you need it, and it is pre-installed on all Windows PC. Microsoft Security is the default one, and unless your choice of security software is available in the Store.
How do I switch back to S mode?
There is no way to switch back to S-Mode once you switch to normal mode. You will have to keep using the standard version, which is a better option any day.