apparmor.d/apparmor.d/groups/systemd/hostnamectl
2024-02-07 00:16:21 +01:00

26 lines
No EOL
592 B
Text

# apparmor.d - Full set of apparmor profiles
# Copyright (C) 2021-2024 Alexandre Pujol <alexandre@pujol.io>
# SPDX-License-Identifier: GPL-2.0-only
abi <abi/3.0>,
include <tunables/global>
@{exec_path} = @{bin}/hostnamectl
profile hostnamectl @{exec_path} {
include <abstractions/base>
include <abstractions/bus-system>
include <abstractions/consoles>
capability net_admin,
# dbus: talk bus=system name=org.freedesktop.hostname1 label=systemd-hostnamed
@{exec_path} mr,
/etc/machine-id r,
@{PROC}/sys/kernel/random/boot_id r,
include if exists <local/hostnamectl>
}