LinuxQuestions.org
Help answer threads with 0 replies.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 10-19-2003, 05:54 PM   #1
kc8tbe
Member
 
Registered: Feb 2003
Location: Cleveland, Ohio (USA)
Distribution: Gentoo, Kubuntu 6.06
Posts: 179

Rep: Reputation: 30
allow non-root user to start gdm


I'd like to allow non-root users on my Gentoo system to start gdm (or xdm or kdm, for that matter) from bash. What's the big security risk (how is gdm more dangerous than startx?) and how do I go about accomplishing this?
 
Old 10-19-2003, 09:23 PM   #2
speter
Member
 
Registered: Sep 2003
Location: Edison, NJ
Distribution: Fedora, Mac OS X
Posts: 313

Rep: Reputation: 30
Why would you want to do that? They would already be logged in, so why run *DM at that point?

Steve
 
Old 10-20-2003, 04:17 PM   #3
kc8tbe
Member
 
Registered: Feb 2003
Location: Cleveland, Ohio (USA)
Distribution: Gentoo, Kubuntu 6.06
Posts: 179

Original Poster
Rep: Reputation: 30
True, the user could just run "startx". But if the user wants to change his WM, he would have to modify ~/.xsession or possibly even XSESSION (the latter of which he wouldn't have access to) - running gdm would just be more convenient. Not to mention that some Gnome features, such as logging into a windowed session from an active login, only work if gdm is running in the background.

Plus it annoys me that I don't know how to let non-root users run gdm .
 
Old 10-21-2003, 02:54 AM   #4
misophist
Member
 
Registered: Aug 2003
Location: here
Distribution: suse 8.2
Posts: 169

Rep: Reputation: 30
Check the 'sudo' command. It might do it.
 
Old 10-21-2003, 04:04 AM   #5
darthtux
Senior Member
 
Registered: Dec 2001
Location: 35.7480 N, 95.3690 W
Distribution: Debian, Gentoo, Red Hat, Solaris
Posts: 2,070

Rep: Reputation: 47
http://www.peakpeak.com/~jallen/howtos/sudo-howto.html
 
Old 10-21-2003, 10:49 AM   #6
kc8tbe
Member
 
Registered: Feb 2003
Location: Cleveland, Ohio (USA)
Distribution: Gentoo, Kubuntu 6.06
Posts: 179

Original Poster
Rep: Reputation: 30
Thanks for the helpful response!
Unfortunately, sudo isn't working so well. My sudoers file looks like this:

# sudoers file.
#
# This file MUST be edited with the 'visudo' command as root.
#
# See the sudoers man page for the details on how to write a sudoers file.
#

# Host alias specification

Host_Alias JACK = Jack, localhost

# User alias specification

User_Alias XUSERS = bkay, skay

# Cmnd alias specification

Cmnd_Alias STARTX = /usr/bin/gdm
Cmnd_Alias STOPX = /usr/bin/gdm-stop

# Defaults specification

# User privilege specification
root ALL=(ALL) ALL

# Uncomment to allow people in group wheel to run all commands
# %wheel ALL=(ALL) ALL

# Same thing without a password
# %wheel ALL=(ALL) NOPASSWD: ALL

# Samples
# %users ALL=/sbin/mount /cdrom,/sbin/umount /cdrom
# %users localhost=/sbin/shutdown -h now
XUSERS JACK = STARTX, STOPX

And my sudo command looks like this:

bkay@Jack bkay $ sudo STOPX
Password:
Sorry, user bkay is not allowed to execute 'STOPX' as root on Jack.
bkay@Jack bkay $

Help?
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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 On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
how to start x as user and not root? SharpyWarpy Fedora 5 06-22-2005 05:17 PM
How to run a Script as root, after Login as User, in GDM MHOOO Red Hat 14 03-08-2005 09:41 AM
Is it possible to start a service but not as a root user appas Linux - Software 1 10-16-2004 12:26 AM
I can start X with root but not with another user pewillette Linux - Newbie 4 04-21-2004 07:58 PM
Can't start X as non-root user. Please help! yitzhakbg Linux - Software 6 12-04-2003 12:06 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 09:58 PM.

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
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration