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 |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
 |
11-22-2005, 07:39 PM
|
#1
|
Senior Member
Registered: Mar 2003
Location: fasdf
Distribution: Debian / Suse /RHEL
Posts: 1,130
Rep:
|
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
|
|
|
11-22-2005, 08:26 PM
|
#2
|
Member
Registered: Mar 2005
Distribution: Gentoo kernel 2.6.14
Posts: 96
Rep:
|
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
|
|
|
11-22-2005, 08:40 PM
|
#3
|
Senior Member
Registered: Mar 2003
Location: fasdf
Distribution: Debian / Suse /RHEL
Posts: 1,130
Original Poster
Rep:
|
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
|
|
|
11-22-2005, 08:47 PM
|
#4
|
Member
Registered: Mar 2005
Distribution: Gentoo kernel 2.6.14
Posts: 96
Rep:
|
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
|
|
|
11-23-2005, 03:18 AM
|
#5
|
Senior Member
Registered: Mar 2003
Location: fasdf
Distribution: Debian / Suse /RHEL
Posts: 1,130
Original Poster
Rep:
|
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.
|
|
|
11-24-2005, 02:37 AM
|
#6
|
Senior Member
Registered: Mar 2003
Location: fasdf
Distribution: Debian / Suse /RHEL
Posts: 1,130
Original Poster
Rep:
|
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
|
|
|
11-24-2005, 03:23 AM
|
#7
|
Member
Registered: Mar 2005
Distribution: Gentoo kernel 2.6.14
Posts: 96
Rep:
|
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
|
|
|
11-24-2005, 03:28 AM
|
#8
|
Senior Member
Registered: Mar 2003
Location: fasdf
Distribution: Debian / Suse /RHEL
Posts: 1,130
Original Poster
Rep:
|
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
|
|
|
All times are GMT -5. The time now is 09:51 AM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|