Bug 541624 - SELinux is preventing /usr/sbin/xenstored "search" access on /proc/xen.
Summary: SELinux is preventing /usr/sbin/xenstored "search" access on /proc/xen.
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: selinux-policy
Version: 12
Hardware: x86_64
OS: Linux
low
medium
Target Milestone: ---
Assignee: Daniel Walsh
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard: setroubleshoot_trace_hash:e2a60d8fca1...
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2009-11-26 14:39 UTC by Sebastian
Modified: 2010-01-08 20:07 UTC (History)
3 users (show)

Fixed In Version: 3.6.32-66.fc12
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2010-01-08 20:07:44 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)

Description Sebastian 2009-11-26 14:39:24 UTC
Summary:

SELinux is preventing /usr/sbin/xenstored "search" access on /proc/xen.

Detailed Description:

SELinux denied access requested by xenstored. It is not expected that this
access is required by xenstored 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
report.

Additional Information:

Source Context                unconfined_u:system_r:xenstored_t:s0
Target Context                system_u:object_r:xenfs_t:s0
Target Objects                /proc/xen [ dir ]
Source                        xenstored
Source Path                   /usr/sbin/xenstored
Port                          <Unknown>
Host                          (removed)
Source RPM Packages           xen-runtime-3.4.1-5.fc12
Target RPM Packages           
Policy RPM                    selinux-policy-3.6.32-46.fc12
Selinux Enabled               True
Policy Type                   targeted
Enforcing Mode                Enforcing
Plugin Name                   catchall
Host Name                     (removed)
Platform                      Linux (removed) 2.6.31.6-xen #5 SMP
                              Thu Nov 26 14:12:06 CET 2009 x86_64 x86_64
Alert Count                   1
First Seen                    Thu 26 Nov 2009 03:03:04 PM CET
Last Seen                     Thu 26 Nov 2009 03:03:04 PM CET
Local ID                      359b1fa8-1dbf-41b0-9470-f5f81a5cf422
Line Numbers                  

Raw Audit Messages            

node=(removed) type=AVC msg=audit(1259244184.74:41): avc:  denied  { search } for  pid=4242 comm="xenstored" name="/" dev=xenfs ino=1 scontext=unconfined_u:system_r:xenstored_t:s0 tcontext=system_u:object_r:xenfs_t:s0 tclass=dir

node=(removed) type=SYSCALL msg=audit(1259244184.74:41): arch=c000003e syscall=2 success=no exit=-13 a0=3463412c6f a1=2 a2=0 a3=54 items=0 ppid=1 pid=4242 auid=500 uid=0 gid=0 euid=0 suid=0 fsuid=0 egid=0 sgid=0 fsgid=0 tty=(none) ses=1 comm="xenstored" exe="/usr/sbin/xenstored" subj=unconfined_u:system_r:xenstored_t:s0 key=(null)



Hash String generated from  selinux-policy-3.6.32-46.fc12,catchall,xenstored,xenstored_t,xenfs_t,dir,search
audit2allow suggests:

#============= xenstored_t ==============
allow xenstored_t xenfs_t:dir search;

Comment 1 Sebastian 2009-11-26 14:43:38 UTC
The directory /dev/xen doesn't exit because at this time i doesn't use a xenified dom0 kernel.

Comment 2 Daniel Walsh 2009-11-30 15:43:53 UTC
If you put xenstored_t into permissive mode, what avc's are generated?


# semanage permissive -a xenstored_t
Run your tests

To remove permissive mode execute

# semanage permissive -d xenstored_t

Comment 3 Daniel Walsh 2009-12-23 13:59:35 UTC

You can add these rules for now using

# grep avc /var/log/audit/audit.log | audit2allow -M mypol
# semodule -i mypol.pp

Fixed in selinux-policy-3.6.32-64.fc12.noarch

Comment 4 Fedora Update System 2010-01-04 21:51:09 UTC
selinux-policy-3.6.32-66.fc12 has been submitted as an update for Fedora 12.
http://admin.fedoraproject.org/updates/selinux-policy-3.6.32-66.fc12

Comment 5 Fedora Update System 2010-01-05 22:47:00 UTC
selinux-policy-3.6.32-66.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-0184

Comment 6 Fedora Update System 2010-01-08 20:01:49 UTC
selinux-policy-3.6.32-66.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.