Description of problem: * the ejabberd service starts successfully but SELinux denial is triggered Version-Release number of selected component (if applicable): ejabberd-19.09.1-2.fc32.noarch ejabberd-selinux-19.09.1-2.fc32.noarch selinux-policy-3.14.5-28.fc32.noarch selinux-policy-targeted-3.14.5-28.fc32.noarch How reproducible: * always Steps to Reproduce: 1. get a Fedora 32 machine (targeted policy is active) 2. start the ejabberd service 3. search for SELinux denials Actual results (enforcing mode): ---- type=PROCTITLE msg=audit(03/02/2020 07:06:25.433:576) : proctitle=/usr/lib64/erlang/erts-10.6.4/bin/beam.smp -K true -P 250000 -- -root /usr/lib64/erlang -progname erl -- -home /var/lib/ejabberd type=PATH msg=audit(03/02/2020 07:06:25.433:576) : item=0 name=/etc/ejabberd/inetrc inode=532185 dev=fc:01 mode=file,640 ouid=ejabberd ogid=ejabberd rdev=00:00 obj=system_u:object_r:etc_t:s0 nametype=NORMAL cap_fp=none cap_fi=none cap_fe=0 cap_fver=0 cap_frootid=0 type=CWD msg=audit(03/02/2020 07:06:25.433:576) : cwd=/var/lib/ejabberd type=SYSCALL msg=audit(03/02/2020 07:06:25.433:576) : arch=x86_64 syscall=access success=no exit=EACCES(Permission denied) a0=0x7ff5b77b0748 a1=W_OK a2=0x81ed9 a3=0xffffffff items=1 ppid=1 pid=15663 auid=unset uid=ejabberd gid=ejabberd euid=ejabberd suid=ejabberd fsuid=ejabberd egid=ejabberd sgid=ejabberd fsgid=ejabberd tty=(none) ses=unset comm=7_dirty_io_sche exe=/usr/lib64/erlang/erts-10.6.4/bin/beam.smp subj=system_u:system_r:ejabberd_t:s0 key=(null) type=AVC msg=audit(03/02/2020 07:06:25.433:576) : avc: denied { write } for pid=15663 comm=7_dirty_io_sche name=inetrc dev="vda1" ino=532185 scontext=system_u:system_r:ejabberd_t:s0 tcontext=system_u:object_r:etc_t:s0 tclass=file permissive=0 ---- Expected results: * no SELinux denials
The only SELinux denial caught in permissive mode: ---- type=PROCTITLE msg=audit(03/02/2020 07:22:37.364:581) : proctitle=/usr/lib64/erlang/erts-10.6.4/bin/beam.smp -K true -P 250000 -- -root /usr/lib64/erlang -progname erl -- -home /var/lib/ejabberd type=PATH msg=audit(03/02/2020 07:22:37.364:581) : item=0 name=/etc/ejabberd/inetrc inode=532185 dev=fc:01 mode=file,640 ouid=ejabberd ogid=ejabberd rdev=00:00 obj=system_u:object_r:etc_t:s0 nametype=NORMAL cap_fp=none cap_fi=none cap_fe=0 cap_fver=0 cap_frootid=0 type=CWD msg=audit(03/02/2020 07:22:37.364:581) : cwd=/var/lib/ejabberd type=SYSCALL msg=audit(03/02/2020 07:22:37.364:581) : arch=x86_64 syscall=access success=no exit=EROFS(Read-only file system) a0=0x7f063dfa87e0 a1=W_OK a2=0x81ed9 a3=0xffffffff items=1 ppid=15767 pid=15778 auid=unset uid=ejabberd gid=ejabberd euid=ejabberd suid=ejabberd fsuid=ejabberd egid=ejabberd sgid=ejabberd fsgid=ejabberd tty=(none) ses=unset comm=10_dirty_io_sch exe=/usr/lib64/erlang/erts-10.6.4/bin/beam.smp subj=system_u:system_r:ejabberd_t:s0 key=(null) type=AVC msg=audit(03/02/2020 07:22:37.364:581) : avc: denied { write } for pid=15778 comm=10_dirty_io_sch name=inetrc dev="vda1" ino=532185 scontext=system_u:system_r:ejabberd_t:s0 tcontext=system_u:object_r:etc_t:s0 tclass=file permissive=1 ----
# find /etc/ -inum 532185 /etc/ejabberd/inetrc #
I believe that writing to a configuration file is not a good idea. Dontaudit candidate?
This message is a reminder that Fedora 32 is nearing its end of life. Fedora will stop maintaining and issuing updates for Fedora 32 on 2021-05-25. It is Fedora's policy to close all bug reports from releases that are no longer maintained. At that time this bug will be closed as EOL if it remains open with a Fedora 'version' of '32'. Package Maintainer: If you wish for this bug to remain open because you plan to fix it in a currently maintained version, simply change the 'version' to a later Fedora version. Thank you for reporting this issue and we are sorry that we were not able to fix it before Fedora 32 is end of life. If you would still like to see this bug fixed and are able to reproduce it against a later version of Fedora, you are encouraged change the 'version' to a later Fedora version prior this bug is closed as described in the policy above. Although we aim to fix as many bugs as possible during every release's lifetime, sometimes those efforts are overtaken by events. Often a more recent Fedora release includes newer upstream software that fixes bugs or makes them obsolete.
Fedora 32 changed to end-of-life (EOL) status on 2021-05-25. Fedora 32 is no longer maintained, which means that it will not receive any further security or bug fix updates. As a result we are closing this bug. If you can reproduce this bug against a currently maintained version of Fedora please feel free to reopen this bug against that version. If you are unable to reopen this bug, please file a new report against the current release. If you experience problems, please add a comment to this bug. Thank you for reporting this bug and we are sorry it could not be fixed.