Run tab with admin privileges

  • Stephan

    Stephan - 2010-02-11


    Is there a way to run individual tabs with elevated privileges? I'd like to have tabs without admin rights and tabs with admin rights (with a different background color) in the same Console2 window. I tried (on Win 7) starting cmd.exe with runas.exe or the hstart utility, but that only triggers an assert in Console2 - no matter whether I try to run a non-elevated shell from an elevated Console2 or the other way around.

    Thanks in advance for any hint.

    - Stephan

  • Derell Licht

    Derell Licht - 2010-02-17

    I would also be interested in this capability.  Right now, I run a separate, stand-alone tcc/le session when I need to run an admin console, but it would be nice if I could do this within C2.

    However, I'd like to expand on the OP's comments about visually differentiating admin/non-admin consoles in this situation.  If they *cannot* be clearly differentiated (by tab color, icon, or some other means), then this feature should *not* be implemented (IMHO); it would be potentially disastrous to have an admin console floating around and not realize it.

  • Stephan

    Stephan - 2010-02-17

    You can set the background color under Settings -> Tabs -> Background, so that shouldn't be an issue.

  • stinos

    stinos - 2010-02-19

    funny I was just looking for the same and this was the first thread I ancountered..

    also tried with runas, but when entering 'runas /savecred /noprofile /user:administrator cmd' as shell for a tab, Console simply launches a seperate cmd window, weird.

  • Atomhrt

    Atomhrt - 2010-03-01

    This was discussed a long time ago, and to my knowledge there is no way to do this on a per tab basis. Instead, I have a bat file that launches two copies of console.exe, with one running as a regular account and another running as a admin account.

  • stinos

    stinos - 2010-03-02

    ok that's a pitty; I guess the reason is launching with elevated permissions in C++ is done using shellexecute, whereas Console uses CreateProcess to spawn the tab's process ? (really just guessing here)


Log in to post a comment.