Note: This bug is displayed in read-only format because
the product is no longer active in Red Hat Bugzilla.
RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
DescriptionLuiz Capitulino
2012-07-13 00:55:21 UTC
We're going to introduce a SELinux policy on RHEL6.4 to deny qemu-ga to read/write arbitrary guest files, this has to be documented in qemu-ga's future manpage and/or configuration files.
In https://bugzilla.redhat.com/show_bug.cgi?id=839831#c0
Luiz requested to add a "qemu_guest_agent_read_any" boolean for the SELinux policy to allow arbitrary read by the daemon. But I did you find this in latest selinux-policy, so I will not mention it in the doc.
This bug can be verified pass now. In the qemu-guest-agent-0.12.1.2-2.351 there's selinux policy note in the /etc/sysconfig/qemu-ga document while in the older version of qemu-guest-agent there's not.
In qemu-guest-agent-0.12.1.2-2.350.el6:
# cat /etc/sysconfig/qemu-ga
# Transport method may be one of following:
# * unix-listen
# * virtio-serial
# * isa-serial
# Default: virtio-serial
TRANSPORT_METHOD="virtio-serial"
# You also can override the device/socket path
# Default: /dev/virtio-ports/org.qemu.guest_agent.0
DEVPATH="/dev/virtio-ports/org.qemu.guest_agent.0"
# If logfile is unset it defaults to stderr but the daemon
# function of init script redirects stderr to /dev/null
LOGFILE="/var/log/qemu-ga.log"
# Override pidfile name
# Default: /var/run/qemu-ga.pid
PIDFILE="/var/run/qemu-ga.pid"
# Comma-separated blacklist of RPCs to disable or empty list to enable all
# Tip: You can get the list of RPC commands using `qemu-ga --blacklist ?`
# Default: blank list to enable all RPCs
# Note: There should be no spaces between commas and commands in the blacklist
BLACKLIST_RPC="guest-file-open,guest-file-close,guest-file-read,guest-file-write,guest-file-seek,guest-file-flush"
=======================
In fixed version qemu-guest-agent-0.12.1.2-2.351.el6:
# cat /etc/sysconfig/qemu-ga
# Transport method may be one of following:
# * unix-listen
# * virtio-serial
# * isa-serial
# Default: virtio-serial
TRANSPORT_METHOD="virtio-serial"
#TRANSPORT_METHOD="isa-serial"
# You also can override the device/socket path
# Default: /dev/virtio-ports/org.qemu.guest_agent.0
DEVPATH="/dev/virtio-ports/org.qemu.guest_agent.0"
#DEVPATH="/dev/ttyS1"
# If logfile is unset it defaults to stderr but the daemon
# function of init script redirects stderr to /dev/null
LOGFILE="/var/log/qemu-ga.log"
# Override pidfile name
# Default: /var/run/qemu-ga.pid
PIDFILE="/var/run/qemu-ga.pid"
# SELinux note:
# About guest arbitrary file read/write
#
# A new selinux policy is introduced on RHEL-6.4 to deny qemu-ga to
# read/write arbitrary guest files except the device file used to talk
# with host processes, LOGFILE and PIDFILE.
#
# You can disable this policy by "restorecon -R -v /usr/bin/qemu-ga"
# Comma-separated blacklist of RPCs to disable or empty list to enable all
# Tip: You can get the list of RPC commands using `qemu-ga --blacklist ?`
# Default: blank list to enable all RPCs
# Note: There should be no spaces between commas and commands in the blacklist
BLACKLIST_RPC="guest-file-open,guest-file-close,guest-file-read,guest-file-write,guest-file-seek,guest-file-flush"
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.
For information on the advisory, and where to find the updated
files, follow the link below.
If the solution does not work for you, open a new bug report.
http://rhn.redhat.com/errata/RHBA-2013-0527.html
(In reply to comment #16)
> I don't understand how running a verbose, recursive restorecon on the
> qemu-ga binary will modify any policy?!?!
Please open a new bug and describe your problem detail, thanks.