Bug 989148 - SELinux is preventing /usr/bin/dbus-daemon from 'associate' accesses on the shared memory .
SELinux is preventing /usr/bin/dbus-daemon from 'associate' accesses on the s...
Product: Fedora
Classification: Fedora
Component: selinux-policy (Show other bugs)
x86_64 Unspecified
unspecified Severity unspecified
: ---
: ---
Assigned To: Lukas Vrabec
Fedora Extras Quality Assurance
Depends On:
  Show dependency treegraph
Reported: 2013-07-27 18:45 EDT by erwincas
Modified: 2015-02-18 09:02 EST (History)
6 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2015-02-18 09:02:28 EST
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 erwincas 2013-07-27 18:45:18 EDT
Description of problem:
SELinux is preventing /usr/bin/dbus-daemon from 'associate' accesses on the shared memory .

*****  Plugin associate (99.5 confidence) suggests  **************************

If you want to change the label of  to system_dbusd_t, you are not allowed to since it is not a valid file type.
Then you must pick a valid file label.
select a valid file type.  List valid file labels by executing: 
# seinfo -afile_type -x

*****  Plugin catchall (1.49 confidence) suggests  ***************************

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

Additional Information:
Source Context                system_u:system_r:system_dbusd_t:s0-s0:c0.c1023
Target Context                system_u:system_r:initrc_t:s0
Target Objects                 [ shm ]
Source                        dbus-daemon
Source Path                   /usr/bin/dbus-daemon
Port                          <Unknown>
Host                          (removed)
Source RPM Packages           dbus-1.6.12-1.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.10.3-300.fc19.x86_64 #1 SMP Fri
                              Jul 26 00:00:58 UTC 2013 x86_64 x86_64
Alert Count                   19
First Seen                    2013-07-27 10:40:43 CST
Last Seen                     2013-07-27 16:43:18 CST
Local ID                      ff904924-bec0-40d7-a65b-a20ac9a89f4d

Raw Audit Messages
type=AVC msg=audit(1374964998.381:456): avc:  denied  { associate } for  pid=502 comm="dbus-daemon" key=838933471  scontext=system_u:system_r:system_dbusd_t:s0-s0:c0.c1023 tcontext=system_u:system_r:initrc_t:s0 tclass=shm

type=SYSCALL msg=audit(1374964998.381:456): arch=x86_64 syscall=shmget success=no exit=EACCES a0=32011bdf a1=0 a2=0 a3=14 items=0 ppid=1 pid=502 auid=4294967295 uid=81 gid=81 euid=81 suid=81 fsuid=81 egid=81 sgid=81 fsgid=81 ses=4294967295 tty=(none) comm=dbus-daemon exe=/usr/bin/dbus-daemon subj=system_u:system_r:system_dbusd_t:s0-s0:c0.c1023 key=(null)

Hash: dbus-daemon,system_dbusd_t,initrc_t,shm,associate

Additional info:
reporter:       libreport-2.1.5
hashmarkername: setroubleshoot
kernel:         3.10.3-300.fc19.x86_64
type:           libreport

Potential duplicate: bug 801537
Comment 1 Miroslav Grepl 2013-07-29 04:56:59 EDT
What process is running as initrc_t?

ps -eZ | grep initrc_t
Comment 2 Daniel Walsh 2013-07-29 14:07:48 EDT
Comment 3 erwincas 2013-07-29 14:33:35 EDT
(In reply to Miroslav Grepl from comment #1)
> What process is running as initrc_t?
> ps -eZ | grep initrc_t

system_u:system_r:initrc_t:s0     978 ?        00:00:00 esets_daemon
system_u:system_r:initrc_t:s0     980 ?        00:00:26 esets_daemon
system_u:system_r:initrc_t:s0     981 ?        00:00:00 esets_mac
Comment 4 Miroslav Grepl 2013-08-08 08:51:42 EDT
Where does esets_daemon come from?
Comment 5 erwincas 2013-08-08 12:42:10 EDT
(In reply to Miroslav Grepl from comment #4)
> Where does esets_daemon come from?

It comes from Eset Nod32 Antivirus for linux Ver 4.
Comment 6 Daniel Walsh 2013-08-09 08:40:48 EDT
Did anything break?
Comment 7 erwincas 2013-08-10 12:51:18 EDT
(In reply to Daniel Walsh from comment #6)
> Did anything break?

nothing, everything runs fine, just the messages at every startup.
Comment 8 Daniel Walsh 2013-08-28 11:55:22 EDT
What is weird here is system_dbusd_t only associates with its own shared memory.

sesearch -A -s system_dbusd_t -c shm
Found 1 semantic av rules:
   allow system_dbusd_t system_dbusd_t : shm { create destroy getattr setattr read write associate unix_read unix_write lock } ; 

According to policy anyways.
Comment 9 Stephen Smalley 2013-08-29 08:25:44 EDT
If shmget is called with a key that is not IPC_PRIVATE and the key already exists, then it can yield an identifier for a pre-existing segment created by another process.
Output of ipcs -m -p might be interesting, along with ps entries for the pids displayed in the ipcs output.
Comment 10 Fedora End Of Life 2015-01-09 17:13:47 EST
This message is a notice that Fedora 19 is now at end of life. Fedora 
has stopped maintaining and issuing updates for Fedora 19. It is 
Fedora's policy to close all bug reports from releases that are no 
longer maintained. Approximately 4 (four) weeks from now this bug will
be closed as EOL if it remains open with a Fedora 'version' of '19'.

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 19 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.
Comment 11 Fedora End Of Life 2015-02-18 09:02:28 EST
Fedora 19 changed to end-of-life (EOL) status on 2015-01-06. Fedora 19 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

Thank you for reporting this bug and we are sorry it could not be fixed.

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