feat(dbus): rewrite some dbus rules (4).

This commit is contained in:
Alexandre Pujol 2023-12-04 18:52:10 +00:00
parent d1affd31f6
commit 2432414ae2
No known key found for this signature in database
GPG key ID: C5469996F0DF68EC
13 changed files with 61 additions and 143 deletions

View file

@ -17,17 +17,11 @@ profile systemd-localed @{exec_path} flags=(attach_disconnected) {
# Needed?
audit capability net_admin,
dbus send bus=system path=/org/freedesktop/DBus
interface=org.freedesktop.DBus
member={ReleaseName,RequestName}
peer=(name=org.freedesktop.DBus),
dbus bind bus=system name=org.freedesktop.locale1,
dbus receive bus=system path=/org/freedesktop/locale1
interface=org.freedesktop.DBus.Properties
member=GetAll,
dbus bind bus=system
name=org.freedesktop.locale[0-9],
member=GetAll
peer=(name=:*, label=evolution-addressbook-factory),
@{exec_path} mr,

View file

@ -26,10 +26,7 @@ profile systemd-networkd @{exec_path} flags=(attach_disconnected,complain) {
network packet dgram,
network packet raw,
dbus send bus=system path=/org/freedesktop/DBus
interface=org.freedesktop.DBus
member=RequestName
peer=(name=org.freedesktop.DBus),
dbus bind bus=system name=org.freedesktop.network1,
dbus send bus=system path=/org/freedesktop/hostname1
interface=org.freedesktop.hostname1
@ -45,9 +42,6 @@ profile systemd-networkd @{exec_path} flags=(attach_disconnected,complain) {
member=PropertiesChanged
peer=(name=org.freedesktop.DBus),
dbus bind bus=system
name=org.freedesktop.network1,
@{exec_path} mr,
/var/lib/dbus/machine-id r,

View file

@ -9,6 +9,7 @@ include <tunables/global>
@{exec_path} = @{lib}/systemd/systemd-user-runtime-dir
profile systemd-user-runtime-dir @{exec_path} {
include <abstractions/base>
include <abstractions/bus/login>
include <abstractions/dbus-strict>
include <abstractions/nameservice-strict>
include <abstractions/systemd-common>
@ -22,11 +23,6 @@ profile systemd-user-runtime-dir @{exec_path} {
mount fstype=tmpfs options=(rw,nosuid,nodev) -> @{run}/user/@{uid}/,
umount @{run}/user/@{uid}/,
dbus send bus=system path=/org/freedesktop/login1
interface=org.freedesktop.DBus.Properties
member=Get
peer=(name=org.freedesktop.login1),
@{exec_path} mr,
/etc/machine-id r,