Git-Url: 
http://git.frugalware.org/gitweb/gitweb.cgi?p=frugalware-current.git;a=commitdiff;h=3c1ab459da74e09bbf944a26a5ebc292053a562a

commit 3c1ab459da74e09bbf944a26a5ebc292053a562a
Author: kikadf <[email protected]>
Date:   Thu Feb 6 10:08:18 2014 +0100

qemu-1.6.1-2-x86_64

* Fix CVE-2013-4375

diff --git a/source/xapps-extra/qemu/CVE-2013-4375.patch 
b/source/xapps-extra/qemu/CVE-2013-4375.patch
new file mode 100644
index 0000000..39b7340
--- /dev/null
+++ b/source/xapps-extra/qemu/CVE-2013-4375.patch
@@ -0,0 +1,37 @@
+From a76f48e53382e6f039db6278443e3ce437653302 Mon Sep 17 00:00:00 2001
+From: Matthew Daley <[email protected]>
+Date: Thu, 10 Oct 2013 14:10:48 +0000
+Subject: [PATCH] xen_disk: mark ioreq as mapped before unmapping in error case
+
+Commit 4472beae modified the semantics of ioreq_{un,}map so that they are
+idempotent if called when they're not needed (ie., twice in a row). However,
+it neglected to handle the case where batch mapping is not being used (the
+default), and one of the grants fails to map. In this case, ioreq_unmap will
+be called to unwind and unmap any mappings already performed, but ioreq_unmap
+simply returns due to the aforementioned change (the ioreq has not already
+been marked as mapped).
+
+The frontend user can therefore force xen_disk to leak grant mappings, a
+per-domain limited resource.
+
+Fix by marking the ioreq as mapped before calling ioreq_unmap in this
+situation.
+
+Signed-off-by: Matthew Daley <[email protected]>
+Signed-off-by: Stefano Stabellini <[email protected]>
+---
+ hw/block/xen_disk.c |    1 +
+ 1 files changed, 1 insertions(+), 0 deletions(-)
+
+Index: qemu-1.5.0+dfsg/hw/block/xen_disk.c
+===================================================================
+--- qemu-1.5.0+dfsg.orig/hw/block/xen_disk.c   2014-01-28 05:41:30.460949671 
-0500
++++ qemu-1.5.0+dfsg/hw/block/xen_disk.c        2014-01-28 05:41:30.456949671 
-0500
+@@ -404,6 +404,7 @@
+                 xen_be_printf(&ioreq->blkdev->xendev, 0,
+                               "can't map grant ref %d (%s, %d maps)\n",
+                               refs[i], strerror(errno), 
ioreq->blkdev->cnt_map);
++                ioreq->mapped = 1;
+                 ioreq_unmap(ioreq);
+                 return -1;
+             }
diff --git a/source/xapps-extra/qemu/FrugalBuild 
b/source/xapps-extra/qemu/FrugalBuild
index 41c4d9c..72daabe 100644
--- a/source/xapps-extra/qemu/FrugalBuild
+++ b/source/xapps-extra/qemu/FrugalBuild
@@ -9,7 +9,7 @@ USE_DEVEL=${USE_DEVEL:-"n"}
pkgname=qemu
pkgver=1.6.1
Fuse $USE_DEVEL && pkgver=svn6369
-pkgrel=1
+pkgrel=2
Fuse $USE_DEVEL && pkgrel=1
pkgdesc="QEMU is a FAST! processor emulator"
url="http://www.nongnu.org/qemu/";
@@ -47,6 +47,11 @@ subdepends=('glib2' 'glib2 nss')

TARGETS="i386-softmmu x86_64-softmmu arm-softmmu"

+# FSA fix ***
+source=(${source[@]} CVE-2013-4375.patch)
+sha1sums=(${sha1sums[@]} '761b353dbbd110fd8e75e0e5f471effdc8e37beb')
+# ***********
+
build()
{
if Fuse $USE_DEVEL; then
_______________________________________________
Frugalware-git mailing list
[email protected]
http://frugalware.org/mailman/listinfo/frugalware-git

Reply via email to