Move libvirtd profiles.

This commit is contained in:
Alexandre Pujol 2021-09-28 21:54:57 +01:00
parent b79ffa52c6
commit adabcd6b94
No known key found for this signature in database
GPG key ID: C5469996F0DF68EC
8 changed files with 40 additions and 244 deletions

View file

@ -13,7 +13,7 @@ profile libvirt-dbus @{exec_path} {
@{exec_path} mr,
/{usr/,}{s,}bin/libvirtd rPUx,
/{usr/,}{s,}bin/libvirtd rPx,
/usr/share/dbus-1/interfaces/org.libvirt.*.xml r,

View file

@ -0,0 +1,21 @@
# apparmor.d - Full set of apparmor profiles
# Copyright (C) Libvirt Team
# Copyright (C) 2021 Alexandre Pujol <alexandre@pujol.io>
# SPDX-License-Identifier: GPL-2.0-only
# This profile is for the container whose UUID matches this file.
abi <abi/3.0>,
include <tunables/global>
profile LIBVIRT_TEMPLATE flags=(attach_disconnected) {
include <abstractions/base>
include <abstractions/libvirt-lxc>
# Globally allows everything to run under this profile
# These can be narrowed depending on the container's use.
file,
capability,
network,
}

View file

@ -0,0 +1,17 @@
# apparmor.d - Full set of apparmor profiles
# Copyright (C) Libvirt Team
# Copyright (C) 2021 Alexandre Pujol <alexandre@pujol.io>
# SPDX-License-Identifier: GPL-2.0-only
# This profile is for the VM whose UUID matches this file.
abi <abi/3.0>,
include <tunables/global>
profile LIBVIRT_TEMPLATE flags=(attach_disconnected) {
include <abstractions/base>
include <abstractions/consoles>
include <abstractions/nameservice-strict>
include <abstractions/libvirt-qemu>
}

View file

@ -7,7 +7,7 @@ abi <abi/3.0>,
include <tunables/global>
@{exec_path} = /{usr/,}{,s}bin/libvirtd
@{exec_path} = /{usr/,}sbin/libvirtd /{usr/,}bin/libvirtd
profile libvirtd @{exec_path} flags=(attach_disconnected) {
include <abstractions/base>
include <abstractions/dbus>