- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Disable user to use sendmail
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
09-12-2004 07:55 PM
09-12-2004 07:55 PM
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-12-2004 08:11 PM
09-12-2004 08:11 PM
Re: Disable user to use sendmail
Not by my knowledge, but you can try the following workaround:
you can make a file called sendmail under the users home-dir and put some text in it that the user isn't authorized. Next thing is to chown root:sys and the chmod 505 on the newly created file. Next is to make sure the users home-dir is the first search path in the $PATH variable.
MB.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-12-2004 08:14 PM
09-12-2004 08:14 PM
Solutionmove the origial sendmail binary /usr/bin/sendmail to /usr/bin/sendmailorg
Make a script as,
#!/usr/bin/ksh
ALLOW_USER="root test user"
index=0
while [[ $index -lt ${#ALLOW_USER[*]} ]]
do
if [[ "$(who -m | awk '{ print $1 }')" != "${ALLOW_USER[$index]}" ]]
then
echo "You are not allowed to execute sendmail"
exit 1
else
echo "/usr/bin/sendmailorg $*" | sh
fi
let index=index+1
done
You can use configuration of users allow as,
/etc/mail/sendmail.allow file name
Put the name's there and read the user's from there on script too.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-12-2004 08:16 PM
09-12-2004 08:16 PM
Re: Disable user to use sendmail
You can prohibit users from sending mail by adding them the the /etc/mail/access
Regards
Michael
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-12-2004 08:17 PM
09-12-2004 08:17 PM
Re: Disable user to use sendmail
new script checks user and give the access to use original binary. And more it is good to change sendmail* name on /usr/bin/ location so that other user's directly access them