Please take our Survey
logo       

Choosing A Webhost:
A web hosting service is a type of Internet hosting service that allows individuals and organizations to provide their own website accessible via the World Wide Web. Web hosts are companies that provide space on a server they own for use by their clients as well as providing Internet connectivity, typically in a data center. Web hosts can also provide data center space and connectivity to the Internet for servers they do not own to be located in their data center, called colocation. more...

Re: A few permission problems: msg#00119

Subject: Re: A few permission problems
Nicklas Norling wrote:

<snip>
Since 01:22:00 this day my server is in enforce mode. The only thing I've found so far is sendmail being denied access to urandom and random. I have sendmail setup with SMTP AUTH as well as certs for performing STARTTLS with any TLS-able connecting MTA.

/var/log/messages
Jul 19 08:09:38 spock kernel: audit(1121753378.808:188): avc: denied { getattr } for pid=20520 comm="sendmail" name="urandom" dev=tmpfs ino=846 scontext=root:system_r:system_mail_ttcontext=system_u:object_r:urandom_device_t tclass=chr_file Jul 19 08:09:38 spock kernel: audit(1121753378.808:189): avc: denied { getattr } for pid=20520 comm="sendmail" name="random" dev=tmpfs ino=844 scontext=root:system_r:system_mail_ttcontext=system_u:object_r:random_device_t tclass=chr_file

/var/log/maillog
Jul 19 08:09:38 spock sendmail[20520]: j6J69cMx020520: from=<edited>, size=874, class=0, nrcpts=1, msgid=<bd1035dcc05d7b2d6a16b046ae4bdd04@xxxxxxxxxxxxxx>, bodytype=8BITMIME, relay=apache@localhost Jul 19 08:09:38 spock sendmail[20520]: j6J69cMx020520: STARTTLS=client, error: connect failed=-1, SSL_error=5, timedout=0, errno=2 Jul 19 08:09:38 spock sendmail[20520]: ruleset=tls_server, arg1=SOFTWARE, relay=[127.0.0.1], reject=403 4.7.0TLS handshake. Jul 19 08:09:38 spock sendmail[20520]: j6J69cMx020520: to=<edited>, ctladdr=<edited> (48/48), delay=00:00:00, xdelay=00:00:00, mailer=relay, pri=30874, relay=[127.0.0.1] [127.0.0.1], dsn=4.0.0, stat=Deferred: 403 4.7.0 TLS handshake. Jul 19 08:09:38 spock sendmail[20521]: STARTTLS=server, error: accept failed=0, SSL_error=5, timedout=0,errno=0 Jul 19 08:09:38 spock sendmail[20521]: j6J69cai020521: localhost [127.0.0.1] did not issue MAIL/EXPN/VRFY/ETRN during connection to MTA

audit2allow -d -l
allow system_mail_t random_device_t:chr_file getattr;
allow system_mail_t urandom_device_t:chr_file getattr;

Policy rpm installed: selinux-policy-targeted-1.25.1-9.noarch.rpm

<snip>

I've installed selinux-policy-targeted-sources-1.25.1-9.noarch.rpm, edited
/etc/selinux/targeted/src/policy/domains/misc/local.te to contain:

allow system_mail_t random_device_t:chr_file getattr;
allow system_mail_t urandom_device_t:chr_file getattr;

Then did a 'make reload' in /etc/selinux/targeted/src/policy as per instructions I found on the net. This made the sendmail TLS errors go away, however, trying smtp auth saslauthd complains instead:

Jul 19 14:14:19 spock saslauthd[22499]: do_auth : auth failure: [user=<edited>] [service=smtp] [realm=] [mech=shadow] [reason=Unknown] Jul 19 14:14:19 spock saslauthd[22500]: do_auth : auth failure: [user=<edited>] [service=smtp] [realm=] [mech=shadow] [reason=Unknown]

'setenforce 0' makes it all work. No avc's in the logs during enforcing mode.

I guess my pathetic attempts at creating local rules failed misserably :(
I'm in way over my head here I think... Any pointers?
/Nicke



<Prev in Thread] Current Thread [Next in Thread>
Google Custom Search

Recently Viewed:
qnx.openqnx.dev...    gcc.libstdc++.c...    solaris.opensol...    information-ret...    misc.misterhous...    web.catalyst.ge...    apache.webservi...    redhat.release....    hardware.lirc/2...    kernel.autofs/2...    technology.sust...    linux.vdr/2003-...    editors.lyx.gen...    org.user-groups...    netbsd.devel.pk...    xdg.devel/2004-...    version-control...    jakarta.slide.d...    debian.packages...    creativecommons...    ports.ppc.embed...    bug-tracking.bu...   
Home | blog view | USPTO Patent Archive | advertise | OSDir is an inevitable website. super tiny logo

Free Magazines

Cisco News
Receive a free quarterly e-newsletter with exclusive articles on how Cisco IT uses its own products and solutions to enable the business.
subscribe

Systems Management News, the newspaper for IT systems administration and data center managers! Each issue of Systems Management News is chock-full of news and analysis to help you understand what's happening in your field.
subscribe

The Enterprise Newsweekly eWeek is the essential technology information source for builders of e-business.
subscribe

Oracle Magazine Oracle Magazine contains technology strategy articles, sample code, tips, Oracle and partner news, how to articles for developers and DBAs, and more. Oracle (NASDAQ: ORCL) is the world's largest enterprise software company.
subscribe

Total Telecom Total Telecom is "The Economist of the communications industry".
subscribe