diff --git a/apparmor.d/groups/bus/dbus-broker b/apparmor.d/groups/bus/dbus-broker new file mode 100644 index 00000000..2ed5eb9f --- /dev/null +++ b/apparmor.d/groups/bus/dbus-broker @@ -0,0 +1,43 @@ +# apparmor.d - Full set of apparmor profiles +# Copyright (C) 2024 Alexandre Pujol +# SPDX-License-Identifier: GPL-2.0-only + +abi , + +include + +@{exec_path} = @{bin}/dbus-broker +profile dbus-broker @{exec_path} flags=(attach_disconnected) { + include + include + include + include + include + + network netlink raw, + + signal (receive) set=(cont, term) peer=systemd-user, + + dbus bus=accessibility, + dbus bus=session, + dbus bus=system, + + @{exec_path} mr, + + @{bin}/* rPUx, + + # Extra rules for GDM + /var/lib/gdm{3,}/.local/share/icc/ r, + /var/lib/gdm{3,}/.local/share/icc/edid-*.icc r, + + @{user_share_dirs}/icc/ r, + @{user_share_dirs}/icc/edid-*.icc r, + + @{run}/systemd/sessions/*.ref rw, + @{run}/systemd/inhibit/*.ref rw, + + /dev/dri/card@{int} rw, + /dev/input/event@{int} rw, + + include if exists +} \ No newline at end of file diff --git a/dists/flags/main.flags b/dists/flags/main.flags index 8784b1cd..5073f8cb 100644 --- a/dists/flags/main.flags +++ b/dists/flags/main.flags @@ -87,8 +87,8 @@ cups-notifier-mailto complain cups-notifier-rss complain cups-pk-helper-mechanism complain cupsd attach_disconnected,complain -dbus-broker complain -dbus-broker-launch complain +dbus-broker attach_disconnected,complain +dbus-broker-launch attach_disconnected,complain dbus-daemon attach_disconnected,complain DiscoverNotifier complain dkms attach_disconnected,complain