- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- restrict "su" access
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
02-23-2008 02:16 PM
02-23-2008 02:16 PM
restrict "su" access
We need to restrict "su" access such that it should not be possible to su to normal ( unprivileged ) user accounts. For eg.. su to root should be possible but su to mickey should not be possible.
Thanks in adv.
Regards,
Wish
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-23-2008 03:29 PM
02-23-2008 03:29 PM
Re: restrict "su" access
Finally, create a file called /etc/default containing the following lines:
ABORT_LOGIN_ON_MISSING_HOMEDIR=1
NOLOGIN=1
NUMBER_OF_LOGINS_ALLOWED=3
This prevents users from logging into the machine if they don't have a home directory defined in /etc/passwd and will prevent a user from logging in with more than three concurrent sessions.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-23-2008 03:57 PM
02-23-2008 03:57 PM
Re: restrict "su" access
$ su
...user becomes root...
# cp /usr/bin/sh /tmp/mickeysh
# chown mickey /tmp/mickeysh
# chmod 4700 /tmp/mickeysh
# /tmp/mickeysh
$ /usr/bin/sh
$ whoami
mickey
Your problem might benefit from a different approach:
1.) Find out which routine tasks require root privileges
2.) Design and implement ways to perform those tasks without root access. For this, you can use standard UNIX file permissions, group memberships and/or tools like Restricted SAM, sudo or HP RBAC.
(This can actually make those routine tasks *easier* for the authorized people, if your design is good. That will make your people *want* to use the new ways after a while.)
3.) When you've reached the point that root access is required only very rarely, change the root password. Treat the new password like the master key of your main office/factory/whatever.
4.) For any new systems, start doing steps 1) and 2) when the system is still in design phase. It's much easier that way, and allows you to notice any potential problem spots while they can still be changed.
MK
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-23-2008 04:35 PM
02-23-2008 04:35 PM
Re: restrict "su" access
but if someone needs to be root to do a task
just set up sudoers to let them run whatever script they need to run
User_Alias ROOTCMD = users,placed,here
Cmnd_Alias MYCMD = /path/to/some/script
ROOTCMD ALL = (root) MYCMD
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-24-2008 11:35 AM
02-24-2008 11:35 AM
Re: restrict "su" access
(like normal users = a,b,c
a should not able to su - b / su - c vise-vers)
Regds,
Wish
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-24-2008 03:18 PM
02-24-2008 03:18 PM