Stefan Krueger of the InstallSite Blog links to two posts describing how to elevate scripts, that is to run them with administrator rights. One has an example for VBScript and the other one is for JScript. Both solutions use a wrapper script that launches the main script. Note that they don't circumvent UAC. If an admin is running this script, she will get the UAC prompt if this feature is not disabled. Under Windows XP, you only had the problem of running scripts with sufficient privileges, while under Vista you have the additional problem of telling UAC that a script will need admin privileges. So you have to take two lines of defense now before actually getting things done.
Latest posts by Michael Pietroforte (see all)
- Results of the 4sysops member and author competition in 2018 - Tue, Jan 8 2019
- Why Microsoft is using Windows customers as guinea pigs - Reply to Tim Warner - Tue, Dec 18 2018
- PowerShell remoting with SSH public key authentication - Thu, May 3 2018