Bug 1008144

Summary: SELinux is preventing /usr/sbin/prelink from 'getattr' accesses on the file /usr/lib64/amanda/ndmjob.
Product: [Fedora] Fedora Reporter: HANS-Joachim Elbers <hajoelbers>
Component: selinux-policyAssignee: Miroslav Grepl <mgrepl>
Status: CLOSED CURRENTRELEASE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 19CC: dominick.grift, dwalsh, lvrabec, mgrepl
Target Milestone: ---   
Target Release: ---   
Hardware: x86_64   
OS: Unspecified   
Whiteboard: abrt_hash:b6c90bd95c5d6c3ba376616466685e68b5da641bd788c3d72ae5a43465b53857
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2013-09-16 08:05:55 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 HANS-Joachim Elbers 2013-09-15 08:20:35 UTC
Description of problem:
SELinux is preventing /usr/sbin/prelink from 'getattr' accesses on the file /usr/lib64/amanda/ndmjob.

*****  Plugin catchall (100. confidence) suggests  ***************************

If sie denken, dass es prelink standardmässig erlaubt sein sollte, getattr Zugriff auf ndmjob file zu erhalten.
Then sie sollten dies als Fehler melden.
Um diesen Zugriff zu erlauben, können Sie ein lokales Richtlinien-Modul erstellen.
Do
zugriff jetzt erlauben, indem Sie die nachfolgenden Befehle ausführen:
# grep prelink /var/log/audit/audit.log | audit2allow -M mypol
# semodule -i mypol.pp

Additional Information:
Source Context                system_u:system_r:prelink_t:s0-s0:c0.c1023
Target Context                system_u:object_r:amanda_exec_t:s0
Target Objects                /usr/lib64/amanda/ndmjob [ file ]
Source                        prelink
Source Path                   /usr/sbin/prelink
Port                          <Unbekannt>
Host                          (removed)
Source RPM Packages           prelink-0.5.0-1.fc19.x86_64
Target RPM Packages           
Policy RPM                    selinux-policy-3.12.1-74.2.fc19.noarch
Selinux Enabled               True
Policy Type                   targeted
Enforcing Mode                Enforcing
Host Name                     (removed)
Platform                      Linux (removed) 3.10.11-200.fc19.x86_64 #1 SMP Mon
                              Sep 9 13:03:01 UTC 2013 x86_64 x86_64
Alert Count                   28
First Seen                    2013-09-15 10:15:44 CEST
Last Seen                     2013-09-15 10:17:40 CEST
Local ID                      75a4f7bf-462b-4ae1-8698-2b0f69a1a304

Raw Audit Messages
type=AVC msg=audit(1379233060.925:691): avc:  denied  { getattr } for  pid=6264 comm="prelink" path="/usr/lib64/amanda/ndmjob" dev="dm-1" ino=2912242 scontext=system_u:system_r:prelink_t:s0-s0:c0.c1023 tcontext=system_u:object_r:amanda_exec_t:s0 tclass=file


type=SYSCALL msg=audit(1379233060.925:691): arch=x86_64 syscall=newfstatat success=no exit=EACCES a0=4 a1=12a974b a2=7fff0dcdd5f0 a3=100 items=0 ppid=6255 pid=6264 auid=0 uid=0 gid=0 euid=0 suid=0 fsuid=0 egid=0 sgid=0 fsgid=0 ses=15 tty=(none) comm=prelink exe=/usr/sbin/prelink subj=system_u:system_r:prelink_t:s0-s0:c0.c1023 key=(null)

Hash: prelink,prelink_t,amanda_exec_t,file,getattr

Additional info:
reporter:       libreport-2.1.6
hashmarkername: setroubleshoot
kernel:         3.10.11-200.fc19.x86_64
type:           libreport

Comment 1 Lukas Vrabec 2013-09-16 08:05:55 UTC
Hi Hans, 

Could you update selinux-policy package? This bug is fixed in selinux-policy-3.12.1-74.3.fc19.noarch



audit2allow -i avc 


#============= prelink_t ==============

#!!!! This avc is allowed in the current policy
allow prelink_t amanda_exec_t:file getattr;


$ rpm -q selinux-policy
selinux-policy-3.12.1-74.3.fc19.noarch