Bug 1369281 - security: apparmor denies qemu.conf set_process_name
Summary: security: apparmor denies qemu.conf set_process_name
Keywords:
Status: CLOSED UPSTREAM
Alias: None
Product: Virtualization Tools
Classification: Community
Component: libvirt
Version: unspecified
Hardware: x86_64
OS: Linux
unspecified
unspecified
Target Milestone: ---
Assignee: Libvirt Maintainers
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2016-08-23 01:28 UTC by zssqcaim
Modified: 2016-12-12 14:32 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2016-12-12 14:32:52 UTC
Embargoed:


Attachments (Terms of Use)

Description zssqcaim 2016-08-23 01:28:24 UTC
Description of problem:
current apparmor profile denies qemu to change task names

Version-Release number of selected component (if applicable):
at least: 1.3.5; 2.0.0

How reproducible:
always

Steps to Reproduce:
1. use apparmor security driver
2. run virtual machine

Actual results:
noise in syslog (apparmor audit)
example
apparmor="DENIED" operation="open" profile="libvirt-cdf35917-3cf6-46ec-b41b-e906add9259f" name="/proc/3024/task/9431/comm" pid=3024 comm="qemu-system-x86" requested_mask="rw" denied_mask="rw"

Expected results:
--

Additional info:
fix: add rule to the profile /etc/apparmor.d/abstractions/libvirt-qemu
  @{PROC}/@{pid}/task/*/comm rw,

Comment 1 Cole Robinson 2016-09-08 14:05:32 UTC
I assume this is via the qemu.conf set_process_name option?

FWIW the libvirt apparmor maintainers don't really follow this bug tracker, might be better to try libvir-list or file a distro bug. Or if you want to take a stab at fixing it, look at ./src/security/virt-aa-helper.c in libvirt.git

Comment 3 Cole Robinson 2016-12-12 14:32:52 UTC
Patch is upstream now, thanks!

commit a73e7037e5a5f7af94216e2147c6ef675b2323f6
Author: intrigeri <intrigeri+libvirt>
Date:   Mon Dec 12 10:59:32 2016 +0000

    AppArmor: allow QEMU to set_process_name.


Note You need to log in before you can comment on or make changes to this bug.