Bug 1036315 - SELinux is preventing /usr/bin/perl from 'read' accesses on the file /etc/mdadm.conf.
Summary: SELinux is preventing /usr/bin/perl from 'read' accesses on the file /etc/mda...
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Fedora
Classification: Fedora
Component: selinux-policy
Version: 20
Hardware: x86_64
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Miroslav Grepl
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard: abrt_hash:57883adcb976924924bbbd65c79...
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-11-30 21:07 UTC by Colin J Thomson
Modified: 2014-11-09 13:48 UTC (History)
6 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2014-01-06 20:20:14 UTC
Type: ---


Attachments (Terms of Use)

Description Colin J Thomson 2013-11-30 21:07:03 UTC
Description of problem:
SELinux is preventing /usr/bin/perl from 'read' accesses on the file /etc/mdadm.conf.

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

If you believe that perl should be allowed read access on the mdadm.conf file by default.
Then you should report this as a bug.
You can generate a local policy module to allow this access.
Do
allow this access for now by executing:
# grep perl /var/log/audit/audit.log | audit2allow -M mypol
# semodule -i mypol.pp

Additional Information:
Source Context                system_u:system_r:logwatch_t:s0-s0:c0.c1023
Target Context                unconfined_u:object_r:mdadm_conf_t:s0
Target Objects                /etc/mdadm.conf [ file ]
Source                        perl
Source Path                   /usr/bin/perl
Port                          <Unknown>
Host                          (removed)
Source RPM Packages           perl-5.18.1-288.fc20.x86_64
Target RPM Packages           
Policy RPM                    selinux-policy-3.12.1-105.fc20.noarch
Selinux Enabled               True
Policy Type                   targeted
Enforcing Mode                Enforcing
Host Name                     (removed)
Platform                      Linux (removed) 3.11.9-300.fc20.x86_64 #1 SMP Wed
                              Nov 20 22:23:25 UTC 2013 x86_64 x86_64
Alert Count                   3
First Seen                    2013-11-28 20:47:06 GMT
Last Seen                     2013-11-30 19:32:05 GMT
Local ID                      51328bf2-c2cb-4e04-af33-cc81e3898a6d

Raw Audit Messages
type=AVC msg=audit(1385839925.479:771): avc:  denied  { read } for  pid=19389 comm="perl" name="mdadm.conf" dev="md127" ino=2233120 scontext=system_u:system_r:logwatch_t:s0-s0:c0.c1023 tcontext=unconfined_u:object_r:mdadm_conf_t:s0 tclass=file


type=SYSCALL msg=audit(1385839925.479:771): arch=x86_64 syscall=open success=no exit=EACCES a0=e828a0 a1=0 a2=1b6 a3=0 items=0 ppid=19387 pid=19389 auid=0 uid=0 gid=0 euid=0 suid=0 fsuid=0 egid=0 sgid=0 fsgid=0 ses=13 tty=(none) comm=perl exe=/usr/bin/perl subj=system_u:system_r:logwatch_t:s0-s0:c0.c1023 key=(null)

Hash: perl,logwatch_t,mdadm_conf_t,file,read

Additional info:
reporter:       libreport-2.1.9
hashmarkername: setroubleshoot
kernel:         3.11.9-300.fc20.x86_64
type:           libreport

Comment 1 Miroslav Grepl 2013-12-04 18:37:58 UTC
Did you configure it or did it happen by default?

Comment 2 Colin J Thomson 2013-12-04 18:50:48 UTC
(In reply to Miroslav Grepl from comment #1)
> Did you configure it or did it happen by default?

By default, I did not configure anything, I have been monitoring this and the alert happens everytime the system runs it daily cronjobs.

Comment 3 Miroslav Grepl 2013-12-06 12:51:34 UTC
I added a fix.

Comment 4 Colin J Thomson 2013-12-21 14:48:35 UTC
The fix in selinux-policy-3.12.1-109.fc20 works fine, I see no more alerts, thanks.

Comment 5 Peter Trenholme 2013-12-23 19:47:49 UTC
Description of problem:
Just booting again after an update yesterday

Additional info:
reporter:       libreport-2.1.10
hashmarkername: setroubleshoot
kernel:         3.11.10-301.fc20.x86_64
type:           libreport

Comment 6 Miroslav Grepl 2014-01-06 20:20:14 UTC
Thank you for testing.


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