Bug 581303

Summary: SELinux is preventing /bin/bash "getattr" access on /bin/hostname.
Product: [Fedora] Fedora Reporter: Doncho Gunchev <dgunchev>
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: carlg, dwalsh, kingsamses+rhbz, marco, mgrepl
Target Milestone: ---   
Target Release: ---   
Hardware: x86_64   
OS: Linux   
Whiteboard: setroubleshoot_trace_hash:eb47be1a4c84b82151051bd7013b10a140e4e65dae030cd8cb8ea7395a0e4631
Fixed In Version: selinux-policy-3.6.32-113.fc12 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2010-05-03 16:08:58 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 Doncho Gunchev 2010-04-11 16:28:19 UTC
Summary:

SELinux is preventing /bin/bash "getattr" access on /bin/hostname.

Detailed Description:

SELinux denied access requested by shorewall. It is not expected that this
access is required by shorewall 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:shorewall_t:s0
Target Context                system_u:object_r:hostname_exec_t:s0
Target Objects                /bin/hostname [ file ]
Source                        shorewall
Source Path                   /bin/bash
Port                          <Unknown>
Host                          (removed)
Source RPM Packages           bash-4.0.35-3.fc12
Target RPM Packages           net-tools-1.60-99.fc12
Policy RPM                    selinux-policy-3.6.32-108.fc12
Selinux Enabled               True
Policy Type                   targeted
Enforcing Mode                Enforcing
Plugin Name                   catchall
Host Name                     (removed)
Platform                      Linux (removed)
                              2.6.32.11-99.fc12.x86_64 #1 SMP Mon Apr 5 19:59:38
                              UTC 2010 x86_64 x86_64
Alert Count                   2
First Seen                    Sun 11 Apr 2010 07:24:05 PM EEST
Last Seen                     Sun 11 Apr 2010 07:24:05 PM EEST
Local ID                      26843317-6643-423f-a499-8c85072a753f
Line Numbers                  

Raw Audit Messages            

node=(removed) type=AVC msg=audit(1271003045.297:9): avc:  denied  { getattr } for  pid=1806 comm="shorewall" path="/bin/hostname" dev=dm-1 ino=109441 scontext=system_u:system_r:shorewall_t:s0 tcontext=system_u:object_r:hostname_exec_t:s0 tclass=file

node=(removed) type=SYSCALL msg=audit(1271003045.297:9): arch=c000003e syscall=4 success=no exit=-13 a0=1ea7df0 a1=7fffba686750 a2=7fffba686750 a3=e items=0 ppid=1793 pid=1806 auid=4294967295 uid=0 gid=0 euid=0 suid=0 fsuid=0 egid=0 sgid=0 fsgid=0 tty=(none) ses=4294967295 comm="shorewall" exe="/bin/bash" subj=system_u:system_r:shorewall_t:s0 key=(null)



Hash String generated from  catchall,shorewall,shorewall_t,hostname_exec_t,file,getattr
audit2allow suggests:

#============= shorewall_t ==============
allow shorewall_t hostname_exec_t:file getattr;

Comment 1 Miroslav Grepl 2010-04-12 08:25:05 UTC
Dan,
I will add

hostname_exec(shorewall_t)

Comment 2 Miroslav Grepl 2010-04-13 12:13:05 UTC
Fixed in selinux-policy-3.6.32-111.fc12

Comment 3 Fedora Update System 2010-04-23 12:44:21 UTC
selinux-policy-3.6.32-113.fc12 has been submitted as an update for Fedora 12.
http://admin.fedoraproject.org/updates/selinux-policy-3.6.32-113.fc12

Comment 4 Miroslav Grepl 2010-04-26 07:39:15 UTC
*** Bug 585583 has been marked as a duplicate of this bug. ***

Comment 5 Fedora Update System 2010-04-27 02:22:58 UTC
selinux-policy-3.6.32-113.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/selinux-policy-3.6.32-113.fc12

Comment 6 Fedora Update System 2010-05-03 16:06:59 UTC
selinux-policy-3.6.32-113.fc12 has been pushed to the Fedora 12 stable repository.  If problems still persist, please make note of it in this bug report.