Now Sitecore PowerShell Extensions provides a User Account Control (UAC) feature akin to that of Microsoft Windows. Security is very important but can be annoying. An elevated session state is required to run the script. Each time when elevated session state expires then you will be prompt for credentials.
Fortunately, there are settings in the file ‘Cognifide.PowerShell.config’, where default settings can be changed. For me, the most inconvenience is that I need to edit the file. Sometimes I do not have access to the server but only to the Sitecore client. Powershell will help a little 🙂
You can use this function to change default security settings. You can do this from a SPE console in Sitecore, but remember that this script will change a config file and Sitecore will be restarted.
# Session expires after 30 minutes Set-UAC4SPE -Token ISE -Expiration '00:30:00'