]> xenbits.xensource.com Git - libvirt.git/commitdiff
Allow apparmor parser to be executed in /usr/bin
authorTom <libvirt-patch@douile.com>
Tue, 20 Aug 2024 23:30:59 +0000 (23:30 +0000)
committerAndrea Bolognani <abologna@redhat.com>
Thu, 12 Sep 2024 07:44:20 +0000 (09:44 +0200)
This commit modifies the AppArmor profile for virt-aa-helper to
accommodate an observed behavior in certain Linux distributions,
such as ArchLinux.

In these distributions, /usr/sbin symlinks to /usr/bin. To ensure
that virt-aa-helper can execute apparmor_parser when it resides
in /usr/bin, the profile has been updated accordingly.

Signed-off-by: Tom <libvirt-patch@douile.com>
Reviewed-by: Andrea Bolognani <abologna@redhat.com>
src/security/apparmor/usr.lib.libvirt.virt-aa-helper.in

index 26ee20a17d4c715dd91da292192fc3e96b9e8294..44645c69893d5f746158e750e1a0c5d24241aaa5 100644 (file)
@@ -41,7 +41,7 @@ profile virt-aa-helper @libexecdir@/virt-aa-helper {
   deny /dev/mapper/* r,
 
   @libexecdir@/virt-aa-helper mr,
-  /{usr/,}sbin/apparmor_parser Ux,
+  /{usr/,}{s,}bin/apparmor_parser Ux,
 
   @sysconfdir@/apparmor.d/libvirt/* r,
   @sysconfdir@/apparmor.d/libvirt/libvirt-[0-9a-f]*-[0-9a-f]*-[0-9a-f]*-[0-9a-f]*-[0-9a-f]* rw,