diff --git a/apparmor.d/profiles-a-l/acpid b/apparmor.d/profiles-a-l/acpid new file mode 100644 index 00000000..dfb18ca5 --- /dev/null +++ b/apparmor.d/profiles-a-l/acpid @@ -0,0 +1,36 @@ +# apparmor.d - Full set of apparmor profiles +# Copyright (C) 2021 Alexandre Pujol +# SPDX-License-Identifier: GPL-2.0-only + +abi , + +include + +@{exec_path} = /{usr/,}bin/acpid +profile acpid @{exec_path} flags=(attach_disconnected) { + include + include + + capability mknod, + + network netlink raw, + + @{exec_path} mr, + + /{usr/,}bin/{,ba,da}sh rix, + /{usr/,}bin/logger rix, + + /etc/acpi/{,**} r, + /etc/acpi/handler.sh rix, + + /dev/input/{,**} r, + /dev/tty rw, + /dev/null r, + + owner @{PROC}/@{pid}/fd/ r, + owner @{PROC}/@{pid}/loginuid r, + + @{run}/acpid.socket rw, + + include if exists +} diff --git a/profiles.manifest b/profiles.manifest index 13689d7d..db4293c2 100644 --- a/profiles.manifest +++ b/profiles.manifest @@ -1,6 +1,7 @@ aa-notify complain accounts-daemon acpi +acpid attach_disconnected,complain adb complain adduser amixer