From 3ad53a2bb087d99f25ba75b0396c94727a7e15ac Mon Sep 17 00:00:00 2001 From: Alexandre Pujol Date: Tue, 10 Sep 2024 18:39:29 +0100 Subject: [PATCH] feat(profile): add aa-unconfined. --- apparmor.d/profiles-a-f/aa-unconfined | 44 +++++++++++++++++++++++++++ 1 file changed, 44 insertions(+) create mode 100644 apparmor.d/profiles-a-f/aa-unconfined diff --git a/apparmor.d/profiles-a-f/aa-unconfined b/apparmor.d/profiles-a-f/aa-unconfined new file mode 100644 index 00000000..a47fa60e --- /dev/null +++ b/apparmor.d/profiles-a-f/aa-unconfined @@ -0,0 +1,44 @@ +# apparmor.d - Full set of apparmor profiles +# Copyright (C) 2024 Alexandre Pujol +# SPDX-License-Identifier: GPL-2.0-only + +abi , + +include + +@{exec_path} = @{bin}/aa-unconfined +profile aa-unconfined @{exec_path} flags=(attach_disconnected) { + include + include + include + + capability dac_read_search, + capability sys_ptrace, + + ptrace read, + + @{exec_path} mr, + + @{bin}/ r, + @{bin}/netstat Px, + @{bin}/ss Px, + + /usr/share/terminfo/** r, + + /etc/apparmor/logprof.conf r, + @{etc_ro}/inputrc r, + + owner @{tmp}/@{rand8} rw, + owner @{tmp}/apparmor-bugreport-@{rand8}.txt rw, + owner /var/tmp/@{rand8} rw, + + @{PROC}/ r, + @{PROC}/@{pid}/cmdline r, + @{PROC}/@{pids}/attr/apparmor/current r, + @{PROC}/@{pids}/attr/current r, + owner @{PROC}/@{pid}/mounts r, + + include if exists +} + +# vim:syntax=apparmor