2022-07-21 23:40:06 +02:00
|
|
|
# apparmor.d - Full set of apparmor profiles
|
2024-02-07 00:16:21 +01:00
|
|
|
# Copyright (C) 2022-2024 Alexandre Pujol <alexandre@pujol.io>
|
2022-07-21 23:40:06 +02:00
|
|
|
# SPDX-License-Identifier: GPL-2.0-only
|
|
|
|
|
|
|
|
abi <abi/3.0>,
|
|
|
|
|
|
|
|
include <tunables/global>
|
|
|
|
|
2024-02-29 00:47:47 +01:00
|
|
|
@{lib_dirs} = @{lib}/ /snap/{snapd,core}/@{int}@{lib}
|
2023-09-05 14:59:37 +02:00
|
|
|
|
|
|
|
@{exec_path} = @{lib_dirs}/snapd/snap-discard-ns
|
2022-07-21 23:40:06 +02:00
|
|
|
profile snap-discard-ns @{exec_path} {
|
|
|
|
include <abstractions/base>
|
|
|
|
|
|
|
|
capability setgid,
|
2023-02-19 19:22:18 +01:00
|
|
|
capability sys_admin,
|
|
|
|
|
|
|
|
network netlink raw,
|
|
|
|
|
|
|
|
umount @{run}/snapd/ns/*.mnt,
|
2022-07-21 23:40:06 +02:00
|
|
|
|
|
|
|
@{exec_path} mr,
|
|
|
|
|
|
|
|
/ r,
|
|
|
|
@{run}/ r,
|
|
|
|
@{run}/snapd/ r,
|
|
|
|
@{run}/snapd/lock/ r,
|
|
|
|
@{run}/snapd/lock/*.lock rwk,
|
|
|
|
@{run}/snapd/ns/ r,
|
|
|
|
@{run}/snapd/ns/* rw,
|
|
|
|
|
|
|
|
include if exists <local/snap-discard-ns>
|
|
|
|
}
|