Page 1 of 1

Run as administrator

Posted: 2008-09-02, 18:15 UTC
by MVV
Hi to all again. Today I want to say about Vista's UAC. Normally, programs started with user rights, while it is enough. But sometimes we need to start a program with administrator rights. In Windows we can use right-click menu. But if we have a program on toolbar or in TC menu, we can't.

So I suggest to add an option "Run as administrator" or "Run elevated".

Also this option may be useful while packing/unpacking. For example, if I use Alt+F9 to unpacking a CAB archive within TC and target folder is write-protected for user profile, TC "unpacks" it but no files are placed into target folder. No rights-required dialog appear.

Posted: 2008-09-02, 19:01 UTC
by sqa_wizard
So I suggest to add an option "Run as administrator"
Already suggested, see: Optional run as administrator in button bar

Posted: 2008-09-03, 01:05 UTC
by MVV
Eh, I miss it again... But it is an easy-to-make feature - just one call of ShellExecute[Ex] with "runas" verb. So, I think this feature will be useful.

Posted: 2008-09-04, 16:29 UTC
by ghisler(Author)
For the button bar, you can create a shortcut (lnk) with Ctrl+Shift+F5, and then use Alt+Enter to set Options like "Run as administrator". Then add this lnk file to the TC buttonbar.

Re: Run as administrator

Posted: 2008-09-04, 18:58 UTC
by HolgerK
MVV wrote:... But sometimes we need to start a program with administrator rights. In Windows we can use right-click menu. But if we have a program on toolbar or in TC menu, we can't.

So I suggest to add an option "Run as administrator" or "Run elevated".
Download and install the Elevation PowerToys for Windows Vista.

After this, you can simply add "elevate" in front of the program or script you want to start with UAC "prompt for consent" dialog.
For example:

Code: Select all

elevate %COMMANDER_PATH%\TOTALCMD.EXE
HTH,
Holger

Posted: 2008-09-18, 15:13 UTC
by MVV
For now, if TC needs to perform an operation which requires admin rights, it asks user to perform operation as admin. Operating system asks elevate confirmation not every time but after some time elapsed.

But not all operations can be performed in TC user-mode. For example, launching editor to edit a file (or create a file on Shift+F4) in folder, which is read-only for user but fully accessible for admin.

I think it will be useful if user can elevate running TC not only for current operation, but on a few time (some minutes for example) for performing more operations which requre admin rights (editing documents in protected folders from users, launching archivers or other external programs) without elevation asks or restarting TC in admin mode which is unsafe.

Posted: 2009-04-18, 11:55 UTC
by urlwolf
I think it will be useful if user can elevate running TC not only for current operation, but on a few time (some minutes for example) for performing more operations which requre admin rights (editing documents in protected folders from users, launching archivers or other external programs) without elevation asks or restarting TC in admin mode which is unsafe.
Agreed. Is this possible? I end up typing admin passwd dozens of times a day. On ubuntu, it's 2-3 times a day at most.

Would it be a horrible security breach to run TC as admin? (then all spawned processes would be admin).

The problem with this is that if you create new folders with TC they will be read-only for users (pain!).

Thanks

Posted: 2009-04-18, 13:50 UTC
by MVV
urlwolf wrote: Would it be a horrible security breach to run TC as admin? (then all spawned processes would be admin).

The problem with this is that if you create new folders with TC they will be read-only for users (pain!).
I don't wanna to run TC as admin, so I've created this topic. :)
I just wanna to have possibility to perform some actions in close time w/o elevation reminds and troubles with unpacking/moving/deleting files to/from write-protected folders.

Posted: 2009-04-18, 14:02 UTC
by fenix_productions
2MVV
It would be nice to have elevation command with timer. DirectoryOpus has something like that:
http://www.pretentiousname.com/opus9/page4.html#vistaadminmode

Similar solution could be great. Maybe even more advanced "Run as" - not limited to admin only.

Posted: 2009-04-18, 15:01 UTC
by MVV
TC has many actions that may require admin rights but for now TCMAdmin can't do all of this things. I think it would be great if we can choose elevated actions (for example, while in such elevated mode not to run sub-applications elevated).

It is more difficult to integrate new features than to plan it at the design time. It will be great if Christian paid attention to our topic's subject. :)

Posted: 2009-04-18, 16:35 UTC
by urlwolf
another solution is to get a cmd prompt in current dir with admin rights. Not ideal, but if you are used to cmd, ... at least it doesn't ask you for a passwd every move you make.

Honestly, the way it works in ubuntu makes windows look like a real pain. More secure, but borderline stupid.

Posted: 2009-04-18, 16:59 UTC
by MVV
urlwolf wrote:another solution is to get a cmd prompt in current dir with admin rights. Not ideal, but if you are used to cmd, ... at least it doesn't ask you for a passwd every move you make.

Honestly, the way it works in ubuntu makes windows look like a real pain. More secure, but borderline stupid.
It's not a solution because in cmd you can't list/unpack archives, can't select files and so on. It is just NOT a TC.

Posted: 2009-04-18, 17:30 UTC
by urlwolf
anyway, I'd be happy to know if one can spawn a cmd with admin privs from TC.
I now do: alt + c, alt + d = run dos, but I'd like to get this dos as admin. Even better, call console instead of CMD.exe.