pkgsrc-WIP-changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

modular-xorg-server-dfbsd: Update wip/modular-xorg-server-dfbsd security patches



Module Name:	pkgsrc-wip
Committed By:	David Shao <davshao%gmail.com@localhost>
Pushed By:	dshao
Date:		Tue Aug 8 18:32:28 2017 -0700
Changeset:	482d096eedd296ffbe88244a19a229c027ecfe6b

Modified Files:
	modular-xorg-server-dfbsd/Makefile
	modular-xorg-server-dfbsd/Makefile.common
	modular-xorg-server-dfbsd/distinfo
Added Files:
	modular-xorg-server-dfbsd/patches/patch-Xi_sendexev.c
	modular-xorg-server-dfbsd/patches/patch-dix_events.c
	modular-xorg-server-dfbsd/patches/patch-dix_swapreq.c

Log Message:
modular-xorg-server-dfbsd: Update wip/modular-xorg-server-dfbsd security patches

Changes:
 * Security patches from pkgsrc

To see a diff of this commit:
https://wip.pkgsrc.org/cgi-bin/gitweb.cgi?p=pkgsrc-wip.git;a=commitdiff;h=482d096eedd296ffbe88244a19a229c027ecfe6b

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

diffstat:
 modular-xorg-server-dfbsd/Makefile                 |  4 +-
 modular-xorg-server-dfbsd/Makefile.common          |  5 +-
 modular-xorg-server-dfbsd/distinfo                 |  5 +-
 .../patches/patch-Xi_sendexev.c                    | 65 ++++++++++++++++++++++
 .../patches/patch-dix_events.c                     | 24 ++++++++
 .../patches/patch-dix_swapreq.c                    | 25 +++++++++
 6 files changed, 125 insertions(+), 3 deletions(-)

diffs:
diff --git a/modular-xorg-server-dfbsd/Makefile b/modular-xorg-server-dfbsd/Makefile
index 3cbaae4c22..4dda1b2c29 100644
--- a/modular-xorg-server-dfbsd/Makefile
+++ b/modular-xorg-server-dfbsd/Makefile
@@ -1,7 +1,8 @@
-# $NetBSD: Makefile,v 1.111 2016/11/16 10:14:36 wiz Exp $
+# $NetBSD: Makefile,v 1.113 2017/07/28 21:10:00 wiz Exp $
 
 DISTNAME=	xorg-server-${XORG_VERSION}
 PKGNAME=	modular-${DISTNAME}
+PKGREVISION=	2
 
 MAINTAINER=	pkgsrc-users%NetBSD.org@localhost
 COMMENT=	Modular X11 server from modular X.org
@@ -15,6 +16,7 @@ NOT_FOR_PLATFORM=	Darwin-*-*
 CONFIGURE_ARGS+=	--enable-xorg
 CONFIGURE_ARGS+=	--disable-xephyr
 CONFIGURE_ARGS+=	--disable-kdrive
+CONFIGURE_ARGS.SunOS+=	--disable-input-thread
 
 .include "options.mk"
 
diff --git a/modular-xorg-server-dfbsd/Makefile.common b/modular-xorg-server-dfbsd/Makefile.common
index 52b92732de..f18998a0d7 100644
--- a/modular-xorg-server-dfbsd/Makefile.common
+++ b/modular-xorg-server-dfbsd/Makefile.common
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile.common,v 1.16 2017/03/16 11:56:46 wiz Exp $
+# $NetBSD: Makefile.common,v 1.17 2017/04/10 13:10:19 jperkin Exp $
 # used by x11/modular-xorg-server/Makefile
 # used by x11/modular-xorg-xephyr/Makefile
 
@@ -99,6 +99,9 @@ PLIST.sparc=		yes
 # Avoid to use bsd_kqueue_apm, force to use bsd_apm instead.
 CONFIGURE_ENV.NetBSD+=	ac_cv_header_sys_event_h=no
 
+# Avoid picking up epoll on illumos
+CONFIGURE_ENV.SunOS+=	ac_cv_func_epoll_create1=no
+
 INSTALLATION_DIRS+=	lib/xorg/modules/drivers lib/xorg/modules/input
 
 BUILDLINK_API_DEPENDS.MesaLib+=		MesaLib>=7.8.0
diff --git a/modular-xorg-server-dfbsd/distinfo b/modular-xorg-server-dfbsd/distinfo
index a2d2ac9ec5..f3e0f40b39 100644
--- a/modular-xorg-server-dfbsd/distinfo
+++ b/modular-xorg-server-dfbsd/distinfo
@@ -1,13 +1,16 @@
-$NetBSD: distinfo,v 1.82 2017/03/16 11:56:46 wiz Exp $
+$NetBSD: distinfo,v 1.83 2017/07/28 21:10:00 wiz Exp $
 
 SHA1 (xorg-server-1.19.3.tar.bz2) = 77f580ffa22a8bbcc3536e74e19114e446417a9c
 RMD160 (xorg-server-1.19.3.tar.bz2) = afa8708054016d4fa3632bf1db0bc462731717b4
 SHA512 (xorg-server-1.19.3.tar.bz2) = b988897418399e1361fdcca9465a781f55f8f6fbfdc5a59edfaee9046a0c6ad7a76f348d88b6004ce3d3fb3966b4c5af0b854f6549c32b2b8d7a43758809f669
 Size (xorg-server-1.19.3.tar.bz2) = 6050221 bytes
+SHA1 (patch-Xi_sendexev.c) = 46a165049d4b15c472736d3863aa4efad39418bc
 SHA1 (patch-config_config-backends.h) = f44868caa51e972a76949f73ac6083640af2c351
 SHA1 (patch-config_config.c) = 5a3fe4cb6c2170335ab547f438386cff77a9c152
 SHA1 (patch-config_devd.c) = c4f968f66903c858e0bb65cafb5229be77f10a2f
 SHA1 (patch-configure) = 9e9f497f14d563ef66f25c637a14b0bea2243c3f
+SHA1 (patch-dix_events.c) = a7ede761198583f1d59c4def49db48725a46bd21
+SHA1 (patch-dix_swapreq.c) = 66643fbd396d0b4222ba4a3f09c4bbe3f0083a33
 SHA1 (patch-hw_xfree86_common_xf86Config.c) = 7964ac8d32d4fcea113c8950661ab921c63ad9d0
 SHA1 (patch-hw_xfree86_common_xf86Globals.c) = 870100ea740b2c0bc1261355d3fcdf17ec50f64f
 SHA1 (patch-hw_xfree86_common_xf86Xinput.c) = 5217a62409708b085a1f83bb0401376e030fb34f
diff --git a/modular-xorg-server-dfbsd/patches/patch-Xi_sendexev.c b/modular-xorg-server-dfbsd/patches/patch-Xi_sendexev.c
new file mode 100644
index 0000000000..385e557594
--- /dev/null
+++ b/modular-xorg-server-dfbsd/patches/patch-Xi_sendexev.c
@@ -0,0 +1,65 @@
+$NetBSD: patch-Xi_sendexev.c,v 1.3 2017/07/28 21:10:00 wiz Exp $
+
+CVE-2017-10971 and CVE-2017-10972: apply fixes to the event loop from
+
+   https://cgit.freedesktop.org/xorg/xserver/commit/?id=ba336b24052122b136486961c82deac76bbde455
+   https://cgit.freedesktop.org/xorg/xserver/commit/?id=8caed4df36b1f802b4992edcfd282cbeeec35d9d
+   https://cgit.freedesktop.org/xorg/xserver/commit/?id=215f894965df5fb0bb45b107d84524e700d2073c
+   https://cgit.freedesktop.org/xorg/xserver/commit/?id=05442de962d3dc624f79fc1a00eca3ffc5489ced
+
+--- Xi/sendexev.c.orig	2017-03-15 18:05:25.000000000 +0000
++++ Xi/sendexev.c
+@@ -78,7 +78,7 @@ SProcXSendExtensionEvent(ClientPtr clien
+ {
+     CARD32 *p;
+     int i;
+-    xEvent eventT;
++    xEvent eventT = { .u.u.type = 0 };
+     xEvent *eventP;
+     EventSwapPtr proc;
+ 
+@@ -95,9 +95,17 @@ SProcXSendExtensionEvent(ClientPtr clien
+ 
+     eventP = (xEvent *) &stuff[1];
+     for (i = 0; i < stuff->num_events; i++, eventP++) {
++        if (eventP->u.u.type == GenericEvent) {
++            client->errorValue = eventP->u.u.type;
++            return BadValue;
++        }
++
+         proc = EventSwapVector[eventP->u.u.type & 0177];
+-        if (proc == NotImplemented)     /* no swapping proc; invalid event type? */
++        /* no swapping proc; invalid event type? */
++        if (proc == NotImplemented) {
++            client->errorValue = eventP->u.u.type;
+             return BadValue;
++        }
+         (*proc) (eventP, &eventT);
+         *eventP = eventT;
+     }
+@@ -117,7 +125,7 @@ SProcXSendExtensionEvent(ClientPtr clien
+ int
+ ProcXSendExtensionEvent(ClientPtr client)
+ {
+-    int ret;
++    int ret, i;
+     DeviceIntPtr dev;
+     xEvent *first;
+     XEventClass *list;
+@@ -141,10 +149,12 @@ ProcXSendExtensionEvent(ClientPtr client
+     /* The client's event type must be one defined by an extension. */
+ 
+     first = ((xEvent *) &stuff[1]);
+-    if (!((EXTENSION_EVENT_BASE <= first->u.u.type) &&
+-          (first->u.u.type < lastEvent))) {
+-        client->errorValue = first->u.u.type;
+-        return BadValue;
++    for (i = 0; i < stuff->num_events; i++) {
++        if (!((EXTENSION_EVENT_BASE <= first[i].u.u.type) &&
++            (first[i].u.u.type < lastEvent))) {
++            client->errorValue = first[i].u.u.type;
++            return BadValue;
++        }
+     }
+ 
+     list = (XEventClass *) (first + stuff->num_events);
diff --git a/modular-xorg-server-dfbsd/patches/patch-dix_events.c b/modular-xorg-server-dfbsd/patches/patch-dix_events.c
new file mode 100644
index 0000000000..5962da4455
--- /dev/null
+++ b/modular-xorg-server-dfbsd/patches/patch-dix_events.c
@@ -0,0 +1,24 @@
+$NetBSD: patch-dix_events.c,v 1.1 2017/07/28 21:10:00 wiz Exp $
+
+CVE-2017-10971 and CVE-2017-10972: apply fixes to the event loop from
+
+   https://cgit.freedesktop.org/xorg/xserver/commit/?id=ba336b24052122b136486961c82deac76bbde455
+   https://cgit.freedesktop.org/xorg/xserver/commit/?id=8caed4df36b1f802b4992edcfd282cbeeec35d9d
+   https://cgit.freedesktop.org/xorg/xserver/commit/?id=215f894965df5fb0bb45b107d84524e700d2073c
+   https://cgit.freedesktop.org/xorg/xserver/commit/?id=05442de962d3dc624f79fc1a00eca3ffc5489ced
+
+--- dix/events.c.orig	2017-03-15 18:05:25.000000000 +0000
++++ dix/events.c
+@@ -5366,6 +5366,12 @@ ProcSendEvent(ClientPtr client)
+         client->errorValue = stuff->event.u.u.type;
+         return BadValue;
+     }
++    /* Generic events can have variable size, but SendEvent request holds
++       exactly 32B of event data. */
++    if (stuff->event.u.u.type == GenericEvent) {
++        client->errorValue = stuff->event.u.u.type;
++        return BadValue;
++    }
+     if (stuff->event.u.u.type == ClientMessage &&
+         stuff->event.u.u.detail != 8 &&
+         stuff->event.u.u.detail != 16 && stuff->event.u.u.detail != 32) {
diff --git a/modular-xorg-server-dfbsd/patches/patch-dix_swapreq.c b/modular-xorg-server-dfbsd/patches/patch-dix_swapreq.c
new file mode 100644
index 0000000000..8c1a2efde5
--- /dev/null
+++ b/modular-xorg-server-dfbsd/patches/patch-dix_swapreq.c
@@ -0,0 +1,25 @@
+$NetBSD: patch-dix_swapreq.c,v 1.1 2017/07/28 21:10:00 wiz Exp $
+
+CVE-2017-10971 and CVE-2017-10972: apply fixes to the event loop from
+
+   https://cgit.freedesktop.org/xorg/xserver/commit/?id=ba336b24052122b136486961c82deac76bbde455
+   https://cgit.freedesktop.org/xorg/xserver/commit/?id=8caed4df36b1f802b4992edcfd282cbeeec35d9d
+   https://cgit.freedesktop.org/xorg/xserver/commit/?id=215f894965df5fb0bb45b107d84524e700d2073c
+   https://cgit.freedesktop.org/xorg/xserver/commit/?id=05442de962d3dc624f79fc1a00eca3ffc5489ced
+
+--- dix/swapreq.c.orig	2017-03-15 18:05:25.000000000 +0000
++++ dix/swapreq.c
+@@ -292,6 +292,13 @@ SProcSendEvent(ClientPtr client)
+     swapl(&stuff->destination);
+     swapl(&stuff->eventMask);
+ 
++    /* Generic events can have variable size, but SendEvent request holds
++       exactly 32B of event data. */
++    if (stuff->event.u.u.type == GenericEvent) {
++        client->errorValue = stuff->event.u.u.type;
++        return BadValue;
++    }
++
+     /* Swap event */
+     proc = EventSwapVector[stuff->event.u.u.type & 0177];
+     if (!proc || proc == NotImplemented)        /* no swapping proc; invalid event type? */


Home | Main Index | Thread Index | Old Index