Bug 992925 - SELinux is preventing /usr/lib64/erlang/erts-5.10.1/bin/beam.smp from 'name_connect' accesses on the tcp_socket .
SELinux is preventing /usr/lib64/erlang/erts-5.10.1/bin/beam.smp from 'name_c...
Status: CLOSED DUPLICATE of bug 992920
Product: Fedora
Classification: Fedora
Component: selinux-policy (Show other bugs)
19
x86_64 Unspecified
unspecified Severity unspecified
: ---
: ---
Assigned To: Miroslav Grepl
Fedora Extras Quality Assurance
abrt_hash:e6904d4a93ba5d26160013a3321...
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2013-08-05 04:46 EDT by Samium Gromoff
Modified: 2013-08-05 10:06 EDT (History)
3 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2013-08-05 10:06:48 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Samium Gromoff 2013-08-05 04:46:07 EDT
Description of problem:
I'm trying to run ejaberrd, but during startup it gets shot down by SELinux.
I've no idea, really. All I can add, is that I've disabled most transports and enabled PAM authentication:

{listen,
 [
  {5222, ejabberd_c2s, [
                        {access, c2s},
                        {shaper, c2s_shaper},
                        {max_stanza_size, 65536},
                        %%zlib,
                        starttls, {certfile, "/etc/ejabberd/ejabberd.pem"}
                       ]},
  {5280, ejabberd_http, [
                         %%{request_handlers,
                         %% [
                         %%  {["pub", "archive"], mod_http_fileserver}
                         %% ]},
                         %%captcha,
                         http_bind,
                         http_poll,
                         web_admin
                        ]}
 ]}.
{auth_method, pam}.
{pam_service, "login"}.
SELinux is preventing /usr/lib64/erlang/erts-5.10.1/bin/beam.smp from 'name_connect' accesses on the tcp_socket .

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

If you believe that beam.smp should be allowed name_connect access on the  tcp_socket 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:ephemeral_port_t:s0
Target Objects                 [ tcp_socket ]
Source                        beam.smp
Source Path                   /usr/lib64/erlang/erts-5.10.1/bin/beam.smp
Port                          34560
Host                          (removed)
Source RPM Packages           erlang-erts-R16B-0.3.fc19.x86_64
Target RPM Packages           
Policy RPM                    selinux-policy-3.12.1-66.fc19.noarch
Selinux Enabled               True
Policy Type                   targeted
Enforcing Mode                Enforcing
Host Name                     (removed)
Platform                      Linux (removed) 3.9.5-301.fc19.x86_64 #1 SMP Tue
                              Jun 11 19:39:38 UTC 2013 x86_64 x86_64
Alert Count                   1
First Seen                    2013-08-02 17:47:47 MSK
Last Seen                     2013-08-02 17:47:47 MSK
Local ID                      6288b03e-02bf-4e4f-9588-44fefa54e9d5

Raw Audit Messages
type=AVC msg=audit(1375451267.291:514): avc:  denied  { name_connect } for  pid=27836 comm="beam.smp" dest=34560 scontext=system_u:system_r:rabbitmq_beam_t:s0 tcontext=system_u:object_r:ephemeral_port_t:s0 tclass=tcp_socket


type=SYSCALL msg=audit(1375451267.291:514): arch=x86_64 syscall=connect success=no exit=EACCES a0=b a1=7fe435e01e58 a2=10 a3=1 items=0 ppid=27809 pid=27836 auid=4294967295 uid=991 gid=989 euid=991 suid=991 fsuid=991 egid=989 sgid=989 fsgid=989 ses=4294967295 tty=(none) comm=beam.smp exe=/usr/lib64/erlang/erts-5.10.1/bin/beam.smp subj=system_u:system_r:rabbitmq_beam_t:s0 key=(null)

Hash: beam.smp,rabbitmq_beam_t,ephemeral_port_t,tcp_socket,name_connect

Additional info:
reporter:       libreport-2.1.6
hashmarkername: setroubleshoot
kernel:         3.9.5-301.fc19.x86_64
type:           libreport
Comment 1 Miroslav Grepl 2013-08-05 10:06:48 EDT

*** This bug has been marked as a duplicate of bug 992920 ***

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