sendmail policy
# Use capabilities
allow $1_mail_t self:capability net_bind_service;
Why is the above in macros/program/sendmail_macros.te?
I may have written the policy like that to keep the functionality of the previous sendmail policy. However I don't have a Sendmail machine for testing and I can't think of any good reason for allowing such access.
Maybe this should be removed?
Signature · 10 lines
http://www.coker.com.au/selinux/ My NSA Security Enhanced Linux packages http://www.coker.com.au/bonnie++/ Bonnie++ hard drive benchmark http://www.coker.com.au/postal/ Postal SMTP/POP benchmark http://www.coker.com.au/~russell/ My home page -- This message was distributed to subscribers of the selinux mailing list. If you no longer wish to subscribe, send mail to [email protected] with the words "unsubscribe selinux" without quotes as the message.
When I remove that capability I get:
avc: denied { name_bind } for pid=14564 exe=/usr/sbin/sendmail port=6400
scontext=root:sysadm_r:sysadm_mail_t tcontext=system_u:object_r:smtp_port_t tclass=tcp_socket
That's on an older machine (sendmail policy is pre-Coker mods, 2.4.18 kernel/policy). It was set up to run as a sendmail server, but I'm not sure how well configured/correct it is at this point. Sendmail fails to start in enforcing mode without that capability. If I toggle the box into permissive mode, sendmail starts and still appears to work (i.e., it sends and receives mail) when I toggle it back to enforcing mode. I'm not real familiar with configuring sendmail, and I couldn't tell from a quick search what it wants to do with port 6400.
The line in the sendmail macro file in that version of the policy was:
allow $1_mail_t $1_mail_t:capability { setuid setgid net_bind_service chown };
David
Quoted 11 lines
-----Original Message-----
From: [email protected] [mailto:[email protected]]On Behalf Of Russell Coker
Sent: Thursday, February 27, 2003 5:21 AM
To: [email protected]
Subject: sendmail policy# Use capabilities
allow $1_mail_t self:capabilitynet_bind_service;
Quoted 8 lines
Why is the above in macros/program/sendmail_macros.te?
I may have written the policy like that to keep the functionality of the previous sendmail policy. However I don't have a Sendmail machine for testing and I can't think of any good reason for allowing such access.
Maybe this should be removed?
--
This message was distributed to subscribers of the selinux mailing list. If you no longer wish to subscribe, send mail to [email protected] with the words "unsubscribe selinux" without quotes as the message.