Bug 1072642 - SELinux is preventing /usr/lib64/erlang/erts-5.10.4/bin/beam.smp from 'create' accesses on the file couchdb.pid.
Summary: SELinux is preventing /usr/lib64/erlang/erts-5.10.4/bin/beam.smp from 'create...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: selinux-policy
Version: 19
Hardware: x86_64
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Lukas Vrabec
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard: abrt_hash:0032ee77f4aff7e169c65fa3e97...
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2014-03-05 01:06 UTC by Shawn Chidester
Modified: 2014-06-27 02:23 UTC (History)
4 users (show)

Fixed In Version: selinux-policy-3.12.1-74.26.fc19
Clone Of:
Environment:
Last Closed: 2014-06-27 02:23:19 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)

Description Shawn Chidester 2014-03-05 01:06:56 UTC
Description of problem:
Produced by installing couchdb via yum: sudo yum install couchdb
Then attempting to start the couchdb service: sudo systemctl start couchdb.service
I immediately get mutiple SELinux alerts about couchdb.
I've tried executing the following commans (as suggested in the SELinux alert and /var/log/messages):

grep beam.smp /var/log/audit/audit.log | audit2allow -M mypol
semodule -i mypol.pp

After executing these commands I try starting couchdb again (sudo systemctl start couchdb.service) and get the same SELinux alerts.
SELinux is preventing /usr/lib64/erlang/erts-5.10.4/bin/beam.smp from 'create' accesses on the file couchdb.pid.

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

If you believe that beam.smp should be allowed create access on the couchdb.pid 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 beam.smp /var/log/audit/audit.log | audit2allow -M mypol
# semodule -i mypol.pp

Additional Information:
Source Context                system_u:system_r:rabbitmq_beam_t:s0
Target Context                system_u:object_r:couchdb_var_run_t:s0
Target Objects                couchdb.pid [ file ]
Source                        beam.smp
Source Path                   /usr/lib64/erlang/erts-5.10.4/bin/beam.smp
Port                          <Unknown>
Host                          (removed)
Source RPM Packages           erlang-erts-R16B-03.1.fc19.x86_64
Target RPM Packages           
Policy RPM                    selinux-policy-3.12.1-74.18.fc19.noarch
Selinux Enabled               True
Policy Type                   targeted
Enforcing Mode                Enforcing
Host Name                     (removed)
Platform                      Linux (removed) 3.13.5-101.fc19.x86_64 #1 SMP Tue
                              Feb 25 21:25:32 UTC 2014 x86_64 x86_64
Alert Count                   5
First Seen                    2014-03-04 17:57:10 MST
Last Seen                     2014-03-04 17:57:11 MST
Local ID                      eb441ee1-e02d-4b6f-ae85-b2634afc460d

Raw Audit Messages
type=AVC msg=audit(1393981031.976:1135): avc:  denied  { create } for  pid=17449 comm="beam.smp" name="couchdb.pid" scontext=system_u:system_r:rabbitmq_beam_t:s0 tcontext=system_u:object_r:couchdb_var_run_t:s0 tclass=file


type=SYSCALL msg=audit(1393981031.976:1135): arch=x86_64 syscall=open success=no exit=EACCES a0=7f80bc0c17b8 a1=241 a2=1b6 a3=1 items=0 ppid=1 pid=17449 auid=4294967295 uid=988 gid=984 euid=988 suid=988 fsuid=988 egid=984 sgid=984 fsgid=984 ses=4294967295 tty=(none) comm=beam.smp exe=/usr/lib64/erlang/erts-5.10.4/bin/beam.smp subj=system_u:system_r:rabbitmq_beam_t:s0 key=(null)

Hash: beam.smp,rabbitmq_beam_t,couchdb_var_run_t,file,create

Additional info:
reporter:       libreport-2.1.12
hashmarkername: setroubleshoot
kernel:         3.13.5-101.fc19.x86_64
type:           libreport

Comment 1 Miroslav Grepl 2014-03-05 08:24:17 UTC
Lukas,
we have fixes in F20/rawhide.

Comment 2 Lukas Vrabec 2014-03-13 14:55:55 UTC
commit a4c40fd7e4c033f7adba1c9a4f0a1b10e92e6f6e
Author: Lukas Vrabec <lvrabec>
Date:   Thu Mar 13 15:55:17 2014 +0100

    Allow couchdb can manage rabbitmq files

Comment 3 Fedora Update System 2014-03-21 14:36:17 UTC
selinux-policy-3.12.1-74.23.fc19 has been submitted as an update for Fedora 19.
https://admin.fedoraproject.org/updates/selinux-policy-3.12.1-74.23.fc19

Comment 4 Fedora Update System 2014-03-22 05:09:34 UTC
Package selinux-policy-3.12.1-74.23.fc19:
* should fix your issue,
* was pushed to the Fedora 19 testing repository,
* should be available at your local mirror within two days.
Update it with:
# su -c 'yum update --enablerepo=updates-testing selinux-policy-3.12.1-74.23.fc19'
as soon as you are able to.
Please go to the following url:
https://admin.fedoraproject.org/updates/FEDORA-2014-4216/selinux-policy-3.12.1-74.23.fc19
then log in and leave karma (feedback).

Comment 5 Fedora Update System 2014-05-07 16:26:13 UTC
selinux-policy-3.12.1-74.26.fc19 has been submitted as an update for Fedora 19.
https://admin.fedoraproject.org/updates/selinux-policy-3.12.1-74.26.fc19

Comment 6 Fedora Update System 2014-06-27 02:23:19 UTC
selinux-policy-3.12.1-74.26.fc19 has been pushed to the Fedora 19 stable repository.  If problems still persist, please make note of it in this bug report.


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