- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- restricting direct root login in ssh ...
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-28-2005 10:03 PM
10-28-2005 10:03 PM
In my company every one are login directly as root. i would like to restrict that direct login to root. I would like all users to login using an individual user account and then use SU as necessary.
plz prepose some solutions to this problem.
thanks and regards
sukumar
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-28-2005 10:09 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-28-2005 10:18 PM
10-28-2005 10:18 PM
Re: restricting direct root login in ssh ...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-28-2005 10:34 PM
10-28-2005 10:34 PM
Re: restricting direct root login in ssh ...
Can you try this method as well..
another way :-
Edit .profile of root as like these
#root.allow
user=`logname`;
sulog="/var/adm/sulog"
TTY="`tty | cut -d/ -f3`"
if [ ${user} = "root" ]
then
if [ ${TTY} != "console" ]
then
echo "
exit
fi
else
grep ${user} /etc/root.allow > /dev/null 2>&1
if [ ${?} -ne 0 ]
then
echo "
date=`date "+%m/%d %H:%M"`
echo "ERR ${date} - ${TTY} ${user}-root" >> ${sulog}
exit
fi
fi
*****
create a file /etc/root.allow and enter user name who will allowed to do su.
But at my place I am using the method which is mentioned by Svetoslav Gyurov. But we are finding an alternative for this to restrict root login according to the PCs from where we are doing ssh to this machines. We are trying to achieving this using a script. So that only few machines will be able to use direct root logins along with the console. This will give more flexibility to us.
Regards,
Syam
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-28-2005 10:42 PM
10-28-2005 10:42 PM
Re: restricting direct root login in ssh ...
The above script I got from ITRC but not tested. Best method is going ahead with the sshd_config. Please assign only zero points for my posts as your problem is already resolved. Thank you.
Regards,
Syam
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-28-2005 10:42 PM
10-28-2005 10:42 PM
Re: restricting direct root login in ssh ...
thank you syam.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-28-2005 10:53 PM
10-28-2005 10:53 PM
Re: restricting direct root login in ssh ...
thanking you Svetoslav and syam.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-28-2005 10:56 PM
10-28-2005 10:56 PM
Re: restricting direct root login in ssh ...
See a thread already posted in ITRC.
there are few scripts which will help you in making your own scripts. May be some modification required but i this this will help you.
http://forums1.itrc.hp.com/service/forums/questionanswer.do?threadId=142175
Regards,
Syam