Bug 561177

Summary: SELinux is preventing /usr/bin/python "search" access on /root/.local.
Product: [Fedora] Fedora Reporter: dvdriddell
Component: selinux-policyAssignee: Miroslav Grepl <mgrepl>
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: medium Docs Contact:
Priority: low    
Version: 12CC: davide.rossetti, dwalsh, jcmj, mgrepl, zikamev
Target Milestone: ---   
Target Release: ---   
Hardware: x86_64   
OS: Linux   
Whiteboard: setroubleshoot_trace_hash:c66b81c4589728fc8a8b4de7b94b193d02fbd1c5f9d9314e3dc7795ab5908481
Fixed In Version: 3.6.32-84.fc12 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2010-02-11 14:42:34 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description dvdriddell 2010-02-02 22:58:25 UTC
Summary:

SELinux is preventing /usr/bin/python "search" access on /root/.local.

Detailed Description:

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

SELinux denied access requested by SetroubleshootF. It is not expected that this
access is required by SetroubleshootF 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://docs.fedoraproject.org/selinux-faq-fc5/#id2961385) Please file a bug
report.

Additional Information:

Source Context                system_u:system_r:setroubleshoot_fixit_t:s0-s0:c0.
                              c1023
Target Context                system_u:object_r:gconf_home_t:s0
Target Objects                /root/.local [ dir ]
Source                        SetroubleshootF
Source Path                   /usr/bin/python
Port                          <Unknown>
Host                          (removed)
Source RPM Packages           python-2.6.2-4.fc12
Target RPM Packages           
Policy RPM                    selinux-policy-3.6.32-78.fc12
Selinux Enabled               True
Policy Type                   targeted
Enforcing Mode                Permissive
Plugin Name                   catchall
Host Name                     (removed)
Platform                      Linux (removed) 2.6.32.7-37.fc12.x86_64 #1 SMP
                              Fri Jan 29 14:19:39 UTC 2010 x86_64 x86_64
Alert Count                   1
First Seen                    Tue 02 Feb 2010 09:42:38 PM GMT
Last Seen                     Tue 02 Feb 2010 09:42:38 PM GMT
Local ID                      c25d989c-496e-4b79-a111-50fbc986a2a9
Line Numbers                  

Raw Audit Messages            

node=(removed) type=AVC msg=audit(1265146958.212:52): avc:  denied  { search } for  pid=3692 comm="SetroubleshootF" name=".local" dev=dm-0 ino=403329 scontext=system_u:system_r:setroubleshoot_fixit_t:s0-s0:c0.c1023 tcontext=system_u:object_r:gconf_home_t:s0 tclass=dir

node=(removed) type=SYSCALL msg=audit(1265146958.212:52): arch=c000003e syscall=4 success=no exit=-2 a0=20795a0 a1=7fff39838650 a2=7fff39838650 a3=6b6361702d657469 items=0 ppid=3691 pid=3692 auid=4294967295 uid=0 gid=0 euid=0 suid=0 fsuid=0 egid=0 sgid=0 fsgid=0 tty=(none) ses=4294967295 comm="SetroubleshootF" exe="/usr/bin/python" subj=system_u:system_r:setroubleshoot_fixit_t:s0-s0:c0.c1023 key=(null)



Hash String generated from  selinux-policy-3.6.32-78.fc12,catchall,SetroubleshootF,setroubleshoot_fixit_t,gconf_home_t,dir,search
audit2allow suggests:

#============= setroubleshoot_fixit_t ==============
allow setroubleshoot_fixit_t gconf_home_t:dir search;

Comment 1 Miroslav Grepl 2010-02-03 11:19:41 UTC
Dan,
we have 'userdom_dontaudit_search_admin_dir(setroubleshoot_fixit_t)' so I would dontaudit this access.

#######################################
## <summary>
##  Dontaudit search gconf homedir content
## </summary>
## <param name="domain">
##  <summary>
##  Domain allowed access.
##  </summary>
## </param>
#
interface(`gnome_dontaudit_search_gconf_home_dir',`
    gen_require(`
        type gconf_home_t;
    ')

    dontaudit $1 gconf_home_t:dir search_dir_perms;
')


gnome_dontaudit_search_gconf_home_dir(setroubleshoot_fixit_t)

Comment 2 Miroslav Grepl 2010-02-03 22:09:11 UTC
Oops, just

gnome_dontaudit_search_config(setroubleshoot_fixit_t)

is sufficient.


Fixed in selinux-policy-3.6.32-82.fc12

Comment 3 Fedora Update System 2010-02-03 23:22:02 UTC
selinux-policy-3.6.32-82.fc12 has been submitted as an update for Fedora 12.
http://admin.fedoraproject.org/updates/selinux-policy-3.6.32-82.fc12

Comment 4 Fedora Update System 2010-02-05 01:45:07 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 5 Fedora Update System 2010-02-11 14:37:55 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.