-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA256 Xen Security Advisory CVE-2016-9381 / XSA-197 version 4 qemu incautious about shared ring processing UPDATES IN VERSION 4 ==================== Normalize version tags. ISSUE DESCRIPTION ================= The compiler can emit optimizations in qemu which can lead to double fetch vulnerabilities. Specifically data on the rings shared between qemu and the hypervisor (which the guest under control can obtain mappings of) can be fetched twice (during which time the guest can alter the contents) possibly leading to arbitrary code execution in qemu. IMPACT ====== Malicious administrators can exploit this vulnerability to take over the qemu process, elevating its privilege to that of the qemu process. In a system not using a device model stub domain (or other techniques for deprivileging qemu), malicious guest administrators can thus elevate their privilege to that of the host. VULNERABLE SYSTEMS ================== All Xen versions with all flavors of qemu are affected. Only x86 HVM guests expose the vulnerability. x86 PV guests do not expose the vulnerability. ARM systems are not vulnerable. MITIGATION ========== Running only PV guests will avoid the vulnerability. Enabling stubdomains will mitigate this issue, by reducing the escalation to only those privileges accorded to the service domain. In a usual configuration, a service domain has only the privilege of the guest, so this eliminates the vulnerability. The vulnerability can be avoided if the guest kernel is controlled by the host rather than guest administrator, provided that further steps are taken to prevent the guest administrator from loading code into the kernel (e.g. by disabling loadable modules etc) or from using other mechanisms which allow them to run code at kernel privilege. CREDITS ======= This issue was discovered by yanghongke of Huawei Security Test Team. RESOLUTION ========== Applying the appropriate attached patch resolves this issue. xsa197-qemuu.patch qemu-xen master, 4.7.x xsa197-qemut.patch qemu-xen-traditional master - 4.6.x xsa197-4.6-qemuu.patch qemu-xen 4.6.x xsa197-4.5-qemuu.patch qemu-xen 4.5.x xsa197-4.5-qemut.patch qemu-xen-traditional 4.5.x, 4.4.x xsa197-4.4-qemuu.patch qemu-xen 4.4.x $ sha256sum xsa197* a7d63958e3d3afc21c0585ec4690886a3191f01127583b4a29766c45fe4dd611 xsa197-4.4-qemuu.patch 56d037b3eaa0c3f5a7c474ad5087d8a41c2769d0d8b39c8f64699215a33e17a6 xsa197-4.5-qemut.patch 902836f0e5c6c46193c06f7c133a3bdd59f902ee490b962857640a6cd73e4be7 xsa197-4.5-qemuu.patch 20a418606f5536ac4fb009f21548a28b1b32dfb08fc97a259c40240d37a2abe8 xsa197-4.6-qemuu.patch 266996b2b5ac65ded76af63b3d57d4972ab95522b517e7bc9c5ff554d8c2d5e0 xsa197-qemut.patch cd08b149c97b3f94dcda14b1f280dbb92911d93ffcd5dbcf5ee5ab2bebdc7878 xsa197-qemuu.patch $ DEPLOYMENT DURING EMBARGO ========================= Deployment of the patch described above (or others which are substantially similar) and the PV guest mitigation are permitted during the embargo, even on public-facing systems with untrusted guest users and administrators. HOWEVER deployment of the stubdomain mitigation described above is NOT permitted (except where all the affected systems and VMs are administered and used only by organisations which are members of the Xen Project Security Issues Predisclosure List). Specifically, deployment on public cloud systems is NOT permitted. This is because in that case the configuration change may be visible to the guest which could lead to the rediscovery of the vulnerability. But: Distribution of updated software is prohibited (except to other members of the predisclosure list). Predisclosure list members who wish to deploy significantly different patches and/or mitigations, please contact the Xen Project Security Team. (Note: this during-embargo deployment notice is retained in post-embargo publicly released Xen Project advisories, even though it is then no longer applicable. This is to enable the community to have oversight of the Xen Project Security Team's decisionmaking.) For more information about permissible uses of embargoed information, consult the Xen Project community's agreed Security Policy: http://www.xenproject.org/security-policy.html -----BEGIN PGP SIGNATURE----- iQFABAEBCAAqFiEEI+MiLBRfRHX6gGCng/4UyVfoK9kFAmV8b/QMHHBncEB4ZW4u b3JnAAoJEIP+FMlX6CvZqGcIALDcK4mpevA1mYTJr6wns0GvN+/SNEM2LPnvsE8y 8ZZaJkjbG5fozRXlXzX0uM54/QVt358kCl+2D5xrdE9+rqPctScu0LKyMn7ehN/+ AbHSTSxH6dNCIsf4/omXOjCCd9nqUDUz+cFkK3Qze1pXeUtOVdPbBpSo9qerLXQ6 lg5ms8ucy76s3U6Bteljl/ohL0OMUIaoH6hLnGqb9eQHUHw6vTy0O4i9sF3BT+aX /i3mlbAeZUXGSEbtw0DDUsx5+A0cJResP/YnnCwilhbC2fF7b0vgB2oaiEY+Kb3z ZTPsMMf1abvrm8sXAeRmNEA5r9B5E0azUaGy3Uc9R9rK4c8= =81mH -----END PGP SIGNATURE-----