apparmor.d/apparmor.d/groups/systemd/systemd-machined
2023-12-05 21:27:03 +00:00

65 lines
1.9 KiB
Text

# apparmor.d - Full set of apparmor profiles
# Copyright (C) 2021 Alexandre Pujol <alexandre@pujol.io>
# SPDX-License-Identifier: GPL-2.0-only
abi <abi/3.0>,
include <tunables/global>
@{exec_path} = @{lib}/systemd/systemd-machined
profile systemd-machined @{exec_path} {
include <abstractions/base>
include <abstractions/dbus-strict>
include <abstractions/systemd-common>
capability chown,
capability dac_override,
capability dac_read_search,
capability fowner,
capability fsetid,
capability kill,
capability mknod,
capability setgid,
capability sys_admin,
capability sys_chroot,
capability sys_ptrace,
dbus bind bus=system name=org.freedesktop.machine1,
dbus receive bus=system path=/org/freedesktop/machine1{,/**}
interface=org.freedesktop.machine1.Manager
peer=(name=:*),
dbus receive bus=system path=/org/freedesktop/machine1{,/**}
interface=org.freedesktop.DBus.Properties
peer=(name=:*),
dbus send bus=system path=/org/freedesktop/systemd1/{,{unit,job}/*}
interface=org.freedesktop.DBus.Properties
member=Get
peer=(name=org.freedesktop.systemd1),
dbus receive bus=system path=/org/freedesktop/systemd1{,/{unit,job}/*}
interface=org.freedesktop.DBus.Properties
member=PropertiesChanged
peer=(name=:*),
dbus send bus=system path=/org/freedesktop/systemd1
interface=org.freedesktop.systemd1.Manager
member={StopUnit,UnrefUnit,StartTransientUnit,Subscribe}
peer=(name=org.freedesktop.systemd1),
dbus receive bus=system path=/org/freedesktop/systemd1
interface=org.freedesktop.systemd1.Manager
member={JobRemoved,UnitRemoved,Reloading}
peer=(name=:*),
@{exec_path} mr,
/var/lib/machines/{,**} rw,
/etc/machine-id r,
@{run}/systemd/machines/{,**} rw,
@{run}/systemd/userdb/io.systemd.Machine rw,
@{run}/systemd/notify w,
include if exists <local/systemd-machined>
}