Bug 1015313 - SELinux is preventing /usr/bin/kmod from 'search' accesses on the directory /usr/lib/modules.
SELinux is preventing /usr/bin/kmod from 'search' accesses on the directory /...
Product: Fedora
Classification: Fedora
Component: selinux-policy (Show other bugs)
i686 Unspecified
unspecified Severity unspecified
: ---
: ---
Assigned To: Miroslav Grepl
Fedora Extras Quality Assurance
Depends On:
  Show dependency treegraph
Reported: 2013-10-03 18:00 EDT by nino.corsi
Modified: 2013-10-04 03:34 EDT (History)
4 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2013-10-04 03:34:45 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description nino.corsi 2013-10-03 18:00:39 EDT
Description of problem:
SELinux is preventing /usr/bin/kmod from 'search' accesses on the directory /usr/lib/modules.

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

If si crede che kmod dovrebbe avere possibilità di accesso search sui modules directory in modo predefinito.
Then si dovrebbe riportare il problema come bug.
E' possibile generare un modulo di politica locale per consentire questo accesso.
consentire questo accesso per il momento eseguendo:
# grep modprobe /var/log/audit/audit.log | audit2allow -M mypol
# semodule -i mypol.pp

Additional Information:
Source Context                system_u:system_r:firewalld_t:s0
Target Context                system_u:object_r:modules_object_t:s0
Target Objects                /usr/lib/modules [ dir ]
Source                        modprobe
Source Path                   /usr/bin/kmod
Port                          <Sconosciuto>
Host                          (removed)
Source RPM Packages           kmod-14-1.fc19.i686
Target RPM Packages           
Policy RPM                    selinux-policy-3.12.1-74.8.fc19.noarch
Selinux Enabled               True
Policy Type                   targeted
Enforcing Mode                Enforcing
Host Name                     (removed)
Platform                      Linux (removed) 3.11.2-201.fc19.i686 #1 SMP Fri
                              Sep 27 19:46:30 UTC 2013 i686 i686
Alert Count                   7
First Seen                    2013-10-03 18:45:44 CEST
Last Seen                     2013-10-03 23:58:56 CEST
Local ID                      21f7441e-35ca-48e7-899a-0937628f6060

Raw Audit Messages
type=AVC msg=audit(1380837536.239:193): avc:  denied  { search } for  pid=806 comm="modprobe" name="modules" dev="dm-0" ino=394190 scontext=system_u:system_r:firewalld_t:s0 tcontext=system_u:object_r:modules_object_t:s0 tclass=dir

type=SYSCALL msg=audit(1380837536.239:193): arch=i386 syscall=open success=no exit=EACCES a0=bff1fa3c a1=88000 a2=1b6 a3=8159238 items=0 ppid=544 pid=806 auid=4294967295 uid=0 gid=0 euid=0 suid=0 fsuid=0 egid=0 sgid=0 fsgid=0 ses=4294967295 tty=(none) comm=modprobe exe=/usr/bin/kmod subj=system_u:system_r:firewalld_t:s0 key=(null)

Hash: modprobe,firewalld_t,modules_object_t,dir,search

Additional info:
reporter:       libreport-2.1.7
hashmarkername: setroubleshoot
kernel:         3.11.2-201.fc19.i686
type:           libreport
Comment 1 Lukas Vrabec 2013-10-04 03:34:45 EDT

You should use: "# restorecon /usr/bin/kmod". Because your /usr/bin/kmod has type firewalld_t instead of insmod_exec_t.

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