LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
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 11-22-2005, 07:39 PM   #1
ust
Senior Member
 
Registered: Mar 2003
Location: fasdf
Distribution: Debian / Suse /RHEL
Posts: 1,130

Rep: Reputation: 31
login permission


If I want the root user can only login at the console , can't login at workstation , that mean the root can't login via telnet , rsh , ftp ... , what can I do ? thx
 
Old 11-22-2005, 08:26 PM   #2
cyberjun
Member
 
Registered: Mar 2005
Distribution: Gentoo kernel 2.6.14
Posts: 96

Rep: Reputation: 15
Hi,

I think /etc/securetty is the file you need. Following is the extact from that file:
# /etc/securetty: list of terminals on which root is allowed to login.
# See securetty(5) and login(1).

Checkout the man pages for securetty and login. However, this will not prevent "su" from giving out rootshells (after authetication ofcourse!!). If you want to prevent normal users from using "su", then I think the solutions to the problem vary. I use Gentoo and I have to add the normal user to group wheel for letting him use "su".
Hope this helps.

cheers,
--cyberjun
 
Old 11-22-2005, 08:40 PM   #3
ust
Senior Member
 
Registered: Mar 2003
Location: fasdf
Distribution: Debian / Suse /RHEL
Posts: 1,130

Original Poster
Rep: Reputation: 31
Quote:
Originally posted by cyberjun
Hi,

I think /etc/securetty is the file you need. Following is the extact from that file:
# /etc/securetty: list of terminals on which root is allowed to login.
# See securetty(5) and login(1).

Checkout the man pages for securetty and login. However, this will not prevent "su" from giving out rootshells (after authetication ofcourse!!). If you want to prevent normal users from using "su", then I think the solutions to the problem vary. I use Gentoo and I have to add the normal user to group wheel for letting him use "su".
Hope this helps.

cheers,
--cyberjun
thx reply ,

my /etc/securetty has many lines as below, if I want to only let root user login at console , do I need to erase all lines excetp tty1 ? thx

vc/7
vc/8
vc/9
vc/10
vc/11
tty1
tty2
tty3
tty4
tty5
tty6
tty7
tty8
tty9
tty10
tty11
rsh
rlogin
rcp
ttyp0
tty0
 
Old 11-22-2005, 08:47 PM   #4
cyberjun
Member
 
Registered: Mar 2005
Distribution: Gentoo kernel 2.6.14
Posts: 96

Rep: Reputation: 15
Hi,
Yes I think that should be it. Maybe you can keep tty1 through tty6 and comment out the rest. You should try this only while keeping atleast one root session open otherwise you might end up accidentally locking yourself out.
Try and let me know.

cheers,
--cyberjun
 
Old 11-23-2005, 03:18 AM   #5
ust
Senior Member
 
Registered: Mar 2003
Location: fasdf
Distribution: Debian / Suse /RHEL
Posts: 1,130

Original Poster
Rep: Reputation: 31
Quote:
Originally posted by cyberjun
Hi,
Yes I think that should be it. Maybe you can keep tty1 through tty6 and comment out the rest. You should try this only while keeping atleast one root session open otherwise you might end up accidentally locking yourself out.
Try and let me know.

cheers,
--cyberjun

thx r suggestion.
 
Old 11-24-2005, 02:37 AM   #6
ust
Senior Member
 
Registered: Mar 2003
Location: fasdf
Distribution: Debian / Suse /RHEL
Posts: 1,130

Original Poster
Rep: Reputation: 31
Quote:
Originally posted by cyberjun
Hi,

I think /etc/securetty is the file you need. Following is the extact from that file:
# /etc/securetty: list of terminals on which root is allowed to login.
# See securetty(5) and login(1).

Checkout the man pages for securetty and login. However, this will not prevent "su" from giving out rootshells (after authetication ofcourse!!). If you want to prevent normal users from using "su", then I think the solutions to the problem vary. I use Gentoo and I have to add the normal user to group wheel for letting him use "su".
Hope this helps.

cheers,
--cyberjun
the reply , if I hv add the user to the wheel group , but still can't su to the root , could suggest what is the reason ? thx
 
Old 11-24-2005, 03:23 AM   #7
cyberjun
Member
 
Registered: Mar 2005
Distribution: Gentoo kernel 2.6.14
Posts: 96

Rep: Reputation: 15
what is ur distro? as I said, might depend on the distro you are using. I use Gentoo and for me its the wheel group. I can't tell which group will be the correct one for you?

cheers,
--cyberjun
 
Old 11-24-2005, 03:28 AM   #8
ust
Senior Member
 
Registered: Mar 2003
Location: fasdf
Distribution: Debian / Suse /RHEL
Posts: 1,130

Original Poster
Rep: Reputation: 31
Quote:
Originally posted by cyberjun
what is ur distro? as I said, might depend on the distro you are using. I use Gentoo and for me its the wheel group. I can't tell which group will be the correct one for you?

cheers,
--cyberjun
I use Suse and RH .

thx
 
Old 11-24-2005, 06:06 AM   #9
cyberjun
Member
 
Registered: Mar 2005
Distribution: Gentoo kernel 2.6.14
Posts: 96

Rep: Reputation: 15
hey,
are you sure all is well with the /bin/su permissions ? Check the following link:

http://archives.neohapsis.com/archiv...4-q1/1349.html


cheers,
--cyberjun
 
  


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



Similar Threads
Thread Thread Starter Forum Replies Last Post
GNOME login - bind: Permission denied Fle>< Linux - Software 7 11-07-2005 11:11 AM
Login against active directory. Get permission denied! ZilenT-X Linux - Newbie 6 08-15-2005 04:29 AM
permission problem - root is the only user which can login hitman_et Linux - Newbie 6 04-03-2005 10:12 AM
USB permission and virtual login? sard Debian 2 03-13-2005 10:27 AM
permission denied message at login p_test Linux - Newbie 2 10-07-2004 02:53 PM

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

All times are GMT -5. The time now is 03:07 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
Open Source Consulting | Domain Registration