How to run application under different credentials

J

James

I used the "run as" feature in XP to run applications as a different user.
How can I do this in Vista? I only see "run as administrator" when I right
click on a shortcut. We are in a network environment and I want to run as a
different user but not the local admin user.

Thanks,
James
 
S

Synapse Syndrome

James said:
I used the "run as" feature in XP to run applications as a different user.
How can I do this in Vista? I only see "run as administrator" when I right
click on a shortcut. We are in a network environment and I want to run as a
different user but not the local admin user.

Well, nobody has answered yet, so..

You can try using the RUNAS from the command line. I am not actually sure
if it works as it did in XP, as I no longer have to run from a power user
account now we have this UAC business, so I have not been using RUNAS in
Vista.

But, from my memory, before I understood UAC, I tried using RUNAS when I
started using Vista and it did not work as I expected. I can't actually
check it right now as I am using my XP Thinkpad.

So, until somebody else, or I, can give you a better answer, try using RUNAS
from the command line.

ss.
 
A

Andrew McLaren

James said:
I used the "run as" feature in XP to run applications as a different user.
How can I do this in Vista? I only see "run as administrator" when I right
click on a shortcut. We are in a network environment and I want to run as a
different user but not the local admin user.

Hi James,

Fortunately, runas.exe still works from the command-line. You can run an app
as any arbitrary user (administrator or standard user); for example,

C:\>runas /user:mydomain\bill notepad

to run Notepad as standard user "mydomain\bill".

If you want to run as an administrative user, who is a member of the
Administrators group (but not the built-in Administrator user) you can
choose "Run as .." from the context menu and add any alternative
credentials, as long as the user you enter is an administrator.

The loss of ability to run an app as an alternative standard user in Vista
is a major hassle, in some scenarios (it was great for software testing an
debugging). But apparently the change is "by design". Several bugs were
opened by beta testers during the Vista beta and they were all closed as
"won't fix". The Microsoft Windows developers were apparently guarding
against some specific security threat (I'm not sure which).

You can create batch files for apps you run regularly, to avoid too much
comand-line typing. Main thing to know about runas.exe is that you *must*
type in the user's password interactively, you can't pass it as a command
line parameter, or pipe it in, in a batch file.

Also note that if you run an app from a mapped network drive, the
alternative user context won't necesarily have the same drive mapping. But
this issue also applies to XP, Vista is not especially different in that
regard.

Hope this helps,
 
B

Bruce Chambers

James said:
I used the "run as" feature in XP to run applications as a different
user. How can I do this in Vista?


Pretty much in the exact same way. All of the command-line options
that were available for RUNAS.EXE under WinXP are still abvailable in
Vista. Further, if you feel the need to use the default GUI shortcut,
it'll still work, regardless of whether or not the selected account has
administrative privileges, assuming that the account does have whatever
privilege level is required by the task. From Vista's Help & Support:

========================================================================
Using the Run As command

In previous versions of Windows, you had to use an administrator account
to do certain things, such as changing system settings or installing
software. If you were logged on as a limited user, the Run as command
eliminated the need to log off and then log back on as an administrator.

In this version of Windows, the Run as command has been changed to Run
as administrator. You should rarely have to use the Run as administrator
command because Windows will automatically prompt you for an
administrator password when needed. Some older programs might still
require you to use the Run as administrator command to eliminate the
need to log off and then log back on.

Right-click the program icon or file that you want to open, and then
click Run as administrator.

Select the account that you want to use, and then type the password.

************************************************************************
Tip
You can also use the Run as administrator command to run a program as
another user, even if the user does not have an administrator account.
To do so, select the account after clicking Run as administrator.
************************************************************************



--

Bruce Chambers

Help us help you:



They that can give up essential liberty to obtain a little temporary
safety deserve neither liberty nor safety. -Benjamin Franklin

Many people would rather die than think; in fact, most do. -Bertrand Russell
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top