Bug 559703 - SELinux is preventing /bin/mailx "getattr" access on /var/run/packagekit-cron.9HXVBh.
Summary: SELinux is preventing /bin/mailx "getattr" access on /var/run/packagekit-cron...
Alias: None
Product: Fedora
Classification: Fedora
Component: selinux-policy
Version: 12
Hardware: x86_64
OS: Linux
Target Milestone: ---
Assignee: Miroslav Grepl
QA Contact: Fedora Extras Quality Assurance
Whiteboard: setroubleshoot_trace_hash:82332ec3b05...
Depends On:
TreeView+ depends on / blocked
Reported: 2010-01-28 19:17 UTC by joshua
Modified: 2010-02-11 14:42 UTC (History)
2 users (show)

Fixed In Version: 3.6.32-84.fc12
Doc Type: Bug Fix
Doc Text:
Clone Of:
Last Closed: 2010-02-11 14:42:47 UTC

Attachments (Terms of Use)

Description joshua 2010-01-28 19:17:30 UTC

SELinux is preventing /bin/mailx "getattr" access on

Detailed Description:

[SELinux is in permissive mode. This access was not denied.]

SELinux denied access requested by mail. It is not expected that this access is
required by mail and this access may signal an intrusion attempt. It is also
possible that the specific version or configuration of the application is
causing it to require additional access.

Allowing Access:

You can generate a local policy module to allow this access - see FAQ
(http://fedora.redhat.com/docs/selinux-faq-fc5/#id2961385) Please file a bug

Additional Information:

Source Context                system_u:system_r:system_mail_t:s0-s0:c0.c1023
Target Context                system_u:object_r:crond_var_run_t:s0
Target Objects                /var/run/packagekit-cron.9HXVBh [ file ]
Source                        mail
Source Path                   /bin/mailx
Port                          <Unknown>
Host                          (removed)
Source RPM Packages           mailx-12.4-3.fc12
Target RPM Packages           
Policy RPM                    selinux-policy-3.6.32-73.fc12
Selinux Enabled               True
Policy Type                   targeted
Enforcing Mode                Permissive
Plugin Name                   catchall
Host Name                     (removed)
Platform                      Linux (removed)
                     #1 SMP Mon Jan 18
                              19:52:07 UTC 2010 x86_64 x86_64
Alert Count                   1
First Seen                    Thu 28 Jan 2010 07:42:42 AM EST
Last Seen                     Thu 28 Jan 2010 07:42:42 AM EST
Local ID                      53a486ab-3a1f-4789-80bd-5abae166ac7e
Line Numbers                  

Raw Audit Messages            

node=(removed) type=AVC msg=audit(1264682562.220:697): avc:  denied  { getattr } for  pid=4654 comm="mail" path="/var/run/packagekit-cron.9HXVBh" dev=dm-4 ino=135678 scontext=system_u:system_r:system_mail_t:s0-s0:c0.c1023 tcontext=system_u:object_r:crond_var_run_t:s0 tclass=file

node=(removed) type=SYSCALL msg=audit(1264682562.220:697): arch=c000003e syscall=5 success=yes exit=128 a0=0 a1=7fff1e8d8910 a2=7fff1e8d8910 a3=2000 items=0 ppid=24372 pid=4654 auid=0 uid=0 gid=0 euid=0 suid=0 fsuid=0 egid=0 sgid=0 fsgid=0 tty=(none) ses=76 comm="mail" exe="/bin/mailx" subj=system_u:system_r:system_mail_t:s0-s0:c0.c1023 key=(null)

Hash String generated from  selinux-policy-3.6.32-73.fc12,catchall,mail,system_mail_t,crond_var_run_t,file,getattr
audit2allow suggests:

#============= system_mail_t ==============
allow system_mail_t crond_var_run_t:file getattr;

Comment 1 Daniel Walsh 2010-01-28 19:38:19 UTC
Do you know if the system is actually trying to mail this file?

Comment 2 Daniel Walsh 2010-01-28 19:44:38 UTC

Add mta_system_content(cron_var_run_t)
to cron.te please

Comment 3 joshua 2010-01-28 21:26:54 UTC
I think it is supposed to be mailing me a list of what it updated, but I can't say for sure that *this* event was supposed to be that.  I'll note here that I have ssmtp installed and active per alternatives:

$ ls -l /usr/sbin/sendmail /etc/alternatives/mta
lrwxrwxrwx. 1 root root 24 2009-11-30 15:47 /etc/alternatives/mta -> /usr/sbin/sendmail.ssmtp

lrwxrwxrwx. 1 root root 21 2009-11-30 15:47 /usr/sbin/sendmail -> /etc/alternatives/mta

Not sure of that makes a difference here or not.

Comment 4 Daniel Walsh 2010-01-28 21:30:24 UTC
I think allow mail to read this file is fine.

Comment 5 Miroslav Grepl 2010-01-29 09:00:24 UTC
Fixed in selinux-policy-3.6.32-79.fc12

Comment 6 Fedora Update System 2010-02-03 23:19:16 UTC
selinux-policy-3.6.32-82.fc12 has been submitted as an update for Fedora 12.

Comment 7 Fedora Update System 2010-02-05 01:45:21 UTC
selinux-policy-3.6.32-84.fc12 has been pushed to the Fedora 12 testing repository.  If problems still persist, please make note of it in this bug report.
 If you want to test the update, you can install it with 
 su -c 'yum --enablerepo=updates-testing update selinux-policy'.  You can provide feedback for this update here: http://admin.fedoraproject.org/updates/F12/FEDORA-2010-1492

Comment 8 Fedora Update System 2010-02-11 14:38:10 UTC
selinux-policy-3.6.32-84.fc12 has been pushed to the Fedora 12 stable repository.  If problems still persist, please make note of it in this bug report.

Note You need to log in before you can comment on or make changes to this bug.