LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Security
User Name
Password
Linux - Security This forum is for all security related questions.
Questions, tips, system compromises, firewalls, etc. are all included here.

Notices


Reply
  Search this Thread
Old 03-17-2006, 10:29 AM   #1
Wheat_Thins
Member
 
Registered: Nov 2005
Location: Michigan
Distribution: Primary: Ubuntu 8.10
Posts: 94

Rep: Reputation: 15
Possible to Query for Root Password with Shortcuts?


Does anybody know if it is possible to be queried when trying to open up programs that require root permissions to run correctly when trying to launch them from a shortcut on the launcher panel? I was just curious because it has this feature built in for all the administrative things on the menu like configuring network ETC. (Where it asks you for the root password before it launches) Is there any way to pass parameters through a custom launcher that could also do the same thing so I can actually launch programs from the launch panel as opposed to opening a terminal SU'ing and launching it?

Thank in Advance!
 
Old 03-17-2006, 12:55 PM   #2
DrEwMoNeY
Member
 
Registered: Jan 2006
Location: Vulcan
Distribution: *buntu - Slackware - Anything on USB
Posts: 254

Rep: Reputation: 30
Do you mean to lock people out from using certain applications? Requiring the root password to use, say, Firefox, or some other application, that doesn't normally request the root password?
 
Old 03-17-2006, 04:16 PM   #3
Wheat_Thins
Member
 
Registered: Nov 2005
Location: Michigan
Distribution: Primary: Ubuntu 8.10
Posts: 94

Original Poster
Rep: Reputation: 15
Quote:
Originally Posted by DrEwMoNeY
Do you mean to lock people out from using certain applications? Requiring the root password to use, say, Firefox, or some other application, that doesn't normally request the root password?
Not so much, I have some network tools like a nmap front end that require root access to be fully functional, but I like to launch the nmap front end from a launcher shortcut off the launcher panel on the top of the screen. Is there anyway to have it come up with a dialog box that asks for root access instead, this way I don't have to open a terminal, do a SU, then type the command to launch the GUI. I am really just looking for a way to make it ask me for the root password so I have fully functionality out of the programs that need root access, all while just being able to launch it off the launcher bar
 
Old 03-17-2006, 04:21 PM   #4
DrEwMoNeY
Member
 
Registered: Jan 2006
Location: Vulcan
Distribution: *buntu - Slackware - Anything on USB
Posts: 254

Rep: Reputation: 30
I'm not sure if this is true in your case, but if I add a program to the kicker, and it needs a root password, that box will pop up automatically.

Just try adding it to your kicker or desktop and then click on it and see if it asks for your password.
 
Old 03-17-2006, 07:53 PM   #5
PTrenholme
Senior Member
 
Registered: Dec 2004
Location: Olympia, WA, USA
Distribution: Fedora, (K)Ubuntu
Posts: 4,187

Rep: Reputation: 354Reputation: 354Reputation: 354Reputation: 354
There is the kdesu command (for use with KDE) that prompts to the root password, and then runs the rest of the line as root. Is this the sort of thing you need? (GNOME has a similar command and, I believe, can also run the kdesu command.
 
Old 03-17-2006, 10:38 PM   #6
mrclisdue
Senior Member
 
Registered: Dec 2005
Distribution: Slackware
Posts: 1,134

Rep: Reputation: 277Reputation: 277Reputation: 277
kdesu -c <command> works, and gives you the 'nicer' dialog.

su -c <command> also works, and a terminal window pops up (and stays up as long as the command is open) prompting for pw.

there are older strictly gnome variations around:

gnomesu.sf.net

and you might be able to find a dusty gsu (officially 'unreleased' and as valuable as a beatles' basement tape (or not)) around.

or even gksu

but i can't vouch for their veracity.......

EDIT: i've been thinking (careful....), and i tested this myself: if the process you're attempting to create a launcher for can only be run as root, eg. system-config-packages - you can create a launcher using that as the command, and it will prompt you for a pw when you launch it.
however, if the process you wish to launch can be run by both user and root (albeit with different results, eg launching a mail client to retrieve local mail), then you'll have to go with the su routines.

cheers,

Last edited by mrclisdue; 03-17-2006 at 11:17 PM.
 
Old 03-18-2006, 09:18 AM   #7
Wheat_Thins
Member
 
Registered: Nov 2005
Location: Michigan
Distribution: Primary: Ubuntu 8.10
Posts: 94

Original Poster
Rep: Reputation: 15
Thanks a million guys, adding kdesu -c '*command here*' under the launchers command line works great!

THANK YOU!
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
How could normal user obtain root password or change root password ckamheng Debian 18 02-18-2009 10:28 PM
How to retrieve( or reset) root password in Mandrake Linux, as I forgot my password? Reghunath Linux - Software 4 05-08-2008 04:11 AM
Root-user shortcuts and thunderbird Rick069 Linux - Software 1 03-12-2006 01:00 PM
Logged in as root, prompted for root password ta0kira Slackware 13 04-25-2005 01:29 AM
setting up for non-root users (tips/shortcuts) pbhj Slackware 2 11-14-2003 11:36 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Security

All times are GMT -5. The time now is 02:30 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration