unofficial mirror of guix-devel@gnu.org 
 help / color / mirror / code / Atom feed
* [PATCH] gnu: qemu: Patch CVE-2016-8910.
@ 2016-10-25 17:27 Kei Kebreau
  2016-10-25 17:36 ` Kei Kebreau
  2016-10-25 17:45 ` Leo Famulari
  0 siblings, 2 replies; 5+ messages in thread
From: Kei Kebreau @ 2016-10-25 17:27 UTC (permalink / raw)
  To: guix-devel


[-- Attachment #1.1: Type: text/plain, Size: 253 bytes --]

One of the email address was hidden on the list I got this patch from.
I don't know whether that's a potential problem.
See:
http://www.openwall.com/lists/oss-security/2016/10/24/2 and
https://lists.gnu.org/archive/html/qemu-devel/2016-10/msg05495.html

[-- Attachment #1.2: 0001-gnu-qemu-Patch-CVE-2016-8910.patch --]
[-- Type: text/plain, Size: 3100 bytes --]

From 4bc4920a96481d5c1a5c7f42cf3ec573f5096d39 Mon Sep 17 00:00:00 2001
From: Kei Kebreau <kei@openmailbox.org>
Date: Tue, 25 Oct 2016 13:24:09 -0400
Subject: [PATCH] gnu: qemu: Patch CVE-2016-8910.

* gnu/packages/qemu.scm (qemu)[source]: Add patch.
* gnu/packages/patches/qemu-CVE-2016-8910.patch: New file.
* gnu/local.mk (dist_patch_DATA): Register it.
---
 gnu/local.mk                                  |  1 +
 gnu/packages/patches/qemu-CVE-2016-8910.patch | 28 +++++++++++++++++++++++++++
 gnu/packages/qemu.scm                         |  3 ++-
 3 files changed, 31 insertions(+), 1 deletion(-)
 create mode 100644 gnu/packages/patches/qemu-CVE-2016-8910.patch

diff --git a/gnu/local.mk b/gnu/local.mk
index ff2d976..5577b69 100644
--- a/gnu/local.mk
+++ b/gnu/local.mk
@@ -814,6 +814,7 @@ dist_patch_DATA =						\
   %D%/packages/patches/qemu-CVE-2016-8576.patch			\
   %D%/packages/patches/qemu-CVE-2016-8577.patch			\
   %D%/packages/patches/qemu-CVE-2016-8578.patch			\
+  %D%/packages/patches/qemu-CVE-2016-8910.patch			\
   %D%/packages/patches/qt4-ldflags.patch			\
   %D%/packages/patches/quickswitch-fix-dmenu-check.patch	\
   %D%/packages/patches/rapicorn-isnan.patch			\
diff --git a/gnu/packages/patches/qemu-CVE-2016-8910.patch b/gnu/packages/patches/qemu-CVE-2016-8910.patch
new file mode 100644
index 0000000..7a38b3c
--- /dev/null
+++ b/gnu/packages/patches/qemu-CVE-2016-8910.patch
@@ -0,0 +1,28 @@
+From: Prasad J Pandit <ppandit@redhat.com>
+
+RTL8139 ethernet controller in C+ mode supports multiple
+descriptor rings, each with maximum of 64 descriptors. While
+processing transmit descriptor ring in 'rtl8139_cplus_transmit',
+it does not limit the descriptor count and runs forever. Add
+check to avoid it.
+
+Reported-by: Andrew Henderson <address@hidden>
+Signed-off-by: Prasad J Pandit <ppandit@redhat.com>
+---
+  hw/net/rtl8139.c | 2 +-
+  1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/hw/net/rtl8139.c b/hw/net/rtl8139.c
+index 3345bc6..f05e59c 100644
+--- a/hw/net/rtl8139.c
++++ b/hw/net/rtl8139.c
+@@ -2350,7 +2350,7 @@ static void rtl8139_cplus_transmit(RTL8139State *s)
+  {
+      int txcount = 0;
+    - while (rtl8139_cplus_transmit_one(s)) 
+
++    while (txcount < 64 && rtl8139_cplus_transmit_one(s))
+      {
+          ++txcount;
+      }
+
diff --git a/gnu/packages/qemu.scm b/gnu/packages/qemu.scm
index 9bf8c3a..a386426 100644
--- a/gnu/packages/qemu.scm
+++ b/gnu/packages/qemu.scm
@@ -79,7 +79,8 @@
                "0lqyz01z90nvxpc3nx4djbci7hx62cwvs5zwd6phssds0sap6vij"))
              (patches (search-patches "qemu-CVE-2016-8576.patch"
                                       "qemu-CVE-2016-8577.patch"
-                                      "qemu-CVE-2016-8578.patch"))))
+                                      "qemu-CVE-2016-8578.patch"
+                                      "qemu-CVE-2016-8910.patch"))))
     (build-system gnu-build-system)
     (arguments
      '(;; Running tests in parallel can occasionally lead to failures, like:
-- 
2.10.1


[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 818 bytes --]

^ permalink raw reply related	[flat|nested] 5+ messages in thread

* Re: [PATCH] gnu: qemu: Patch CVE-2016-8910.
  2016-10-25 17:27 [PATCH] gnu: qemu: Patch CVE-2016-8910 Kei Kebreau
@ 2016-10-25 17:36 ` Kei Kebreau
  2016-10-25 17:44   ` Kei Kebreau
  2016-10-25 17:45 ` Leo Famulari
  1 sibling, 1 reply; 5+ messages in thread
From: Kei Kebreau @ 2016-10-25 17:36 UTC (permalink / raw)
  To: guix-devel

[-- Attachment #1: Type: text/plain, Size: 436 bytes --]

Kei Kebreau <kei@openmailbox.org> writes:

> One of the email address was hidden on the list I got this patch from.
> I don't know whether that's a potential problem.
> See:
> http://www.openwall.com/lists/oss-security/2016/10/24/2 and
> https://lists.gnu.org/archive/html/qemu-devel/2016-10/msg05495.html

Also, I just noticed an issue with the patch I submitted. Any advice on
getting valid patches from online mailing list archives?

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 818 bytes --]

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] gnu: qemu: Patch CVE-2016-8910.
  2016-10-25 17:36 ` Kei Kebreau
@ 2016-10-25 17:44   ` Kei Kebreau
  0 siblings, 0 replies; 5+ messages in thread
From: Kei Kebreau @ 2016-10-25 17:44 UTC (permalink / raw)
  To: guix-devel


[-- Attachment #1.1: Type: text/plain, Size: 583 bytes --]

Kei Kebreau <kei@openmailbox.org> writes:

> Kei Kebreau <kei@openmailbox.org> writes:
>
>> One of the email address was hidden on the list I got this patch from.
>> I don't know whether that's a potential problem.
>> See:
>> http://www.openwall.com/lists/oss-security/2016/10/24/2 and
>> https://lists.gnu.org/archive/html/qemu-devel/2016-10/msg05495.html
>
> Also, I just noticed an issue with the patch I submitted. Any advice on
> getting valid patches from online mailing list archives?

BTW, I just fixed the issue. It appears that inline patches can get
messed up in replies.

[-- Attachment #1.2: 0001-gnu-qemu-Patch-CVE-2016-8910.patch --]
[-- Type: text/plain, Size: 3106 bytes --]

From a99ba6e18e063c08b0069fd59d98023427cb96aa Mon Sep 17 00:00:00 2001
From: Kei Kebreau <kei@openmailbox.org>
Date: Tue, 25 Oct 2016 13:42:23 -0400
Subject: [PATCH] gnu: qemu: Patch CVE-2016-8910.

* gnu/packages/qemu.scm (qemu)[source]: Add patch.
* gnu/packages/patches/qemu-CVE-2016-8910.patch: New file.
* gnu/local.mk (dist_patch_DATA): Register it.
---
 gnu/local.mk                                  |  1 +
 gnu/packages/patches/qemu-CVE-2016-8910.patch | 30 +++++++++++++++++++++++++++
 gnu/packages/qemu.scm                         |  3 ++-
 3 files changed, 33 insertions(+), 1 deletion(-)
 create mode 100644 gnu/packages/patches/qemu-CVE-2016-8910.patch

diff --git a/gnu/local.mk b/gnu/local.mk
index ff2d976..5577b69 100644
--- a/gnu/local.mk
+++ b/gnu/local.mk
@@ -814,6 +814,7 @@ dist_patch_DATA =						\
   %D%/packages/patches/qemu-CVE-2016-8576.patch			\
   %D%/packages/patches/qemu-CVE-2016-8577.patch			\
   %D%/packages/patches/qemu-CVE-2016-8578.patch			\
+  %D%/packages/patches/qemu-CVE-2016-8910.patch			\
   %D%/packages/patches/qt4-ldflags.patch			\
   %D%/packages/patches/quickswitch-fix-dmenu-check.patch	\
   %D%/packages/patches/rapicorn-isnan.patch			\
diff --git a/gnu/packages/patches/qemu-CVE-2016-8910.patch b/gnu/packages/patches/qemu-CVE-2016-8910.patch
new file mode 100644
index 0000000..7033c42
--- /dev/null
+++ b/gnu/packages/patches/qemu-CVE-2016-8910.patch
@@ -0,0 +1,30 @@
+From: Prasad J Pandit <ppandit@redhat.com>
+
+RTL8139 ethernet controller in C+ mode supports multiple
+descriptor rings, each with maximum of 64 descriptors. While
+processing transmit descriptor ring in 'rtl8139_cplus_transmit',
+it does not limit the descriptor count and runs forever. Add
+check to avoid it.
+
+Reported-by: Andrew Henderson <address@hidden>
+Signed-off-by: Prasad J Pandit <ppandit@redhat.com>
+---
+ hw/net/rtl8139.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/hw/net/rtl8139.c b/hw/net/rtl8139.c
+index 3345bc6..f05e59c 100644
+--- a/hw/net/rtl8139.c
++++ b/hw/net/rtl8139.c
+@@ -2350,7 +2350,7 @@ static void rtl8139_cplus_transmit(RTL8139State *s)
+ {
+     int txcount = 0;
+ 
+-    while (rtl8139_cplus_transmit_one(s))
++    while (txcount < 64 && rtl8139_cplus_transmit_one(s))
+     {
+         ++txcount;
+     }
+-- 
+2.7.4
+
diff --git a/gnu/packages/qemu.scm b/gnu/packages/qemu.scm
index 9bf8c3a..a386426 100644
--- a/gnu/packages/qemu.scm
+++ b/gnu/packages/qemu.scm
@@ -79,7 +79,8 @@
                "0lqyz01z90nvxpc3nx4djbci7hx62cwvs5zwd6phssds0sap6vij"))
              (patches (search-patches "qemu-CVE-2016-8576.patch"
                                       "qemu-CVE-2016-8577.patch"
-                                      "qemu-CVE-2016-8578.patch"))))
+                                      "qemu-CVE-2016-8578.patch"
+                                      "qemu-CVE-2016-8910.patch"))))
     (build-system gnu-build-system)
     (arguments
      '(;; Running tests in parallel can occasionally lead to failures, like:
-- 
2.10.1


[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 818 bytes --]

^ permalink raw reply related	[flat|nested] 5+ messages in thread

* Re: [PATCH] gnu: qemu: Patch CVE-2016-8910.
  2016-10-25 17:27 [PATCH] gnu: qemu: Patch CVE-2016-8910 Kei Kebreau
  2016-10-25 17:36 ` Kei Kebreau
@ 2016-10-25 17:45 ` Leo Famulari
  2016-10-25 17:46   ` Kei Kebreau
  1 sibling, 1 reply; 5+ messages in thread
From: Leo Famulari @ 2016-10-25 17:45 UTC (permalink / raw)
  To: Kei Kebreau; +Cc: guix-devel

[-- Attachment #1: Type: text/plain, Size: 576 bytes --]

On Tue, Oct 25, 2016 at 01:27:45PM -0400, Kei Kebreau wrote:
> One of the email address was hidden on the list I got this patch from.
> I don't know whether that's a potential problem.
> See:
> http://www.openwall.com/lists/oss-security/2016/10/24/2 and
> https://lists.gnu.org/archive/html/qemu-devel/2016-10/msg05495.html

The patch doesn't appear to have been pushed to the QEMU Git repo yet.

http://git.qemu.org/?p=qemu.git

Let's wait for that in order to be sure the patch is correct.  Plus,
then we'll be able to see that email address.

I expect that to happen soon.

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 819 bytes --]

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] gnu: qemu: Patch CVE-2016-8910.
  2016-10-25 17:45 ` Leo Famulari
@ 2016-10-25 17:46   ` Kei Kebreau
  0 siblings, 0 replies; 5+ messages in thread
From: Kei Kebreau @ 2016-10-25 17:46 UTC (permalink / raw)
  To: Leo Famulari; +Cc: guix-devel

[-- Attachment #1: Type: text/plain, Size: 657 bytes --]

Leo Famulari <leo@famulari.name> writes:

> On Tue, Oct 25, 2016 at 01:27:45PM -0400, Kei Kebreau wrote:
>> One of the email address was hidden on the list I got this patch from.
>> I don't know whether that's a potential problem.
>> See:
>> http://www.openwall.com/lists/oss-security/2016/10/24/2 and
>> https://lists.gnu.org/archive/html/qemu-devel/2016-10/msg05495.html
>
> The patch doesn't appear to have been pushed to the QEMU Git repo yet.
>
> http://git.qemu.org/?p=qemu.git
>
> Let's wait for that in order to be sure the patch is correct.  Plus,
> then we'll be able to see that email address.
>
> I expect that to happen soon.

Sounds good. :-)

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 818 bytes --]

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2016-10-25 17:47 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-10-25 17:27 [PATCH] gnu: qemu: Patch CVE-2016-8910 Kei Kebreau
2016-10-25 17:36 ` Kei Kebreau
2016-10-25 17:44   ` Kei Kebreau
2016-10-25 17:45 ` Leo Famulari
2016-10-25 17:46   ` Kei Kebreau

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).