runas: Command or Program: Run as other user
RunAs allows to run certain programs or commands as another user. For example, should a computer be logged in as a normal user and should elevated privileges be required for certain actions, such as installing software, "RunAs" can be used to simply run the installation as an administrator user.
Windows dialog: Run as other user
By holding the Shift key and additionally "right-clicking" on a shortcut, an extended dialog with the option: "Run as other user" can be called:
After entering the login information, the application will be started with another user:
Command Prompt
With the following command in the command prompt, a new cmd window (command prompt) can be started as another user:
runas /user:DomainOrComputername\Username "cmd"
Control in the command prompt: whoami
The command "whoami" in the command prompt, prints as response the currently used user:
c:\temp>whoami
Domain\Username
as system
For example, psexec allows commands to be run as "system", see: Localsystem: use local system account - more rights
{{percentage}} % positive