xserver-xorg: Multiple CVE fixes
PATCH 1/1 xserver-xorg: Multiple CVE fixes
From: Vijay Anusuri <[email protected]>
Fix below CVE's
CVE-2023-6816
CVE-2024-0229
CVE-2024-21885
CVE-2024-21886
CVE-2024-0408
CVE-2024-0409
Signed-off-by Vijay Anusuri <[email protected]>
--- .../xserver-xorg/CVE-2023-6816.patch | 55 +++++ .../xserver-xorg/CVE-2024-0229-1.patch | 87 +++++++ .../xserver-xorg/CVE-2024-0229-2.patch | 221 ++++++++++++++++++ .../xserver-xorg/CVE-2024-0229-3.patch | 41 ++++ .../xserver-xorg/CVE-2024-0229-4.patch | 45 ++++ .../xserver-xorg/CVE-2024-0408.patch | 64 +++++ .../xserver-xorg/CVE-2024-0409.patch | 46 ++++ .../xserver-xorg/CVE-2024-21885.patch | 113 +++++++++ .../xserver-xorg/CVE-2024-21886-1.patch | 74 ++++++ .../xserver-xorg/CVE-2024-21886-2.patch | 57 +++++ .../xorg-xserver/xserver-xorg_1.20.14.bb | 10 + 11 files changed, 813 insertions(+) create mode 100644 meta/recipes-graphics/xorg-xserver/xserver-xorg/CVE-2023-6816.patch create mode 100644 meta/recipes-graphics/xorg-xserver/xserver-xorg/CVE-2024-0229-1.patch create mode 100644 meta/recipes-graphics/xorg-xserver/xserver-xorg/CVE-2024-0229-2.patch create mode 100644 meta/recipes-graphics/xorg-xserver/xserver-xorg/CVE-2024-0229-3.patch create mode 100644 meta/recipes-graphics/xorg-xserver/xserver-xorg/CVE-2024-0229-4.patch create mode 100644 meta/recipes-graphics/xorg-xserver/xserver-xorg/CVE-2024-0408.patch create mode 100644 meta/recipes-graphics/xorg-xserver/xserver-xorg/CVE-2024-0409.patch create mode 100644 meta/recipes-graphics/xorg-xserver/xserver-xorg/CVE-2024-21885.patch create mode 100644 meta/recipes-graphics/xorg-xserver/xserver-xorg/CVE-2024-21886-1.patch create mode 100644 meta/recipes-graphics/xorg-xserver/xserver-xorg/CVE-2024-21886-2.patch
meta/recipes-graphics/xorg-xserver/xserver-xorg/CVE-2023-6816.patch new file +55 -0
@@ -0,0 +1,55 @@ +From 9e2ecb2af8302dedc49cb6a63ebe063c58a9e7e3 Mon Sep 17 00:00:00 2001 +From: Peter Hutterer <[email protected]> +Date: Thu, 14 Dec 2023 11:29:49 +1000 +Subject: [PATCH] dix: allocate enough space for logical button maps + +Both DeviceFocusEvent and the XIQueryPointer reply contain a bit for +each logical button currently down. Since buttons can be arbitrarily mapped +to anything up to 255 make sure we have enough bits for the maximum mapping. + +CVE-2023-6816, ZDI-CAN-22664, ZDI-CAN-22665 + +This vulnerability was discovered by: +Jan-Niklas Sohn working with Trend Micro Zero Day Initiative + +Upstream-Status: Backport [https://gitlab.freedesktop.org/xorg/xserver/-/commit/9e2ecb2af8302dedc49cb6a63ebe063c58a9e7e3] +CVE: CVE-2023-6816 +Signed-off-by: Vijay Anusuri <[email protected]> +--- + Xi/xiquerypointer.c | 3 +-- + dix/enterleave.c | 5 +++-- + 2 files changed, 4 insertions(+), 4 deletions(-) + +diff --git a/Xi/xiquerypointer.c b/Xi/xiquerypointer.c +index 5b77b1a444..2b05ac5f39 100644 +--- a/Xi/xiquerypointer.c ++++ b/Xi/xiquerypointer.c +@@ -149,8 +149,7 @@ ProcXIQueryPointer(ClientPtr client) + if (pDev->button) { + int i; + +- rep.buttons_len = +- bytes_to_int32(bits_to_bytes(pDev->button->numButtons)); ++ rep.buttons_len = bytes_to_int32(bits_to_bytes(256)); /* button map up to 255 */ + rep.length += rep.buttons_len; + buttons = calloc(rep.buttons_len, 4); + if (!buttons) +diff --git a/dix/enterleave.c b/dix/enterleave.c +index 867ec74363..ded8679d76 100644 +--- a/dix/enterleave.c ++++ b/dix/enterleave.c +@@ -784,8 +784,9 @@ DeviceFocusEvent(DeviceIntPtr dev, int type, int mode, int detail, + + mouse = IsFloating(dev) ? dev : GetMaster(dev, MASTER_POINTER); + +- /* XI 2 event */ +- btlen = (mouse->button) ? bits_to_bytes(mouse->button->numButtons) : 0; ++ /* XI 2 event contains the logical button map - maps are CARD8 ++ * so we need 256 bits for the possibly maximum mapping */ ++ btlen = (mouse->button) ? bits_to_bytes(256) : 0; + btlen = bytes_to_int32(btlen); + len = sizeof(xXIFocusInEvent) + btlen * 4; + +-- +GitLab +
meta/recipes-graphics/xorg-xserver/xserver-xorg/CVE-2024-0229-1.patch new file +87 -0
87 lines not on this page · raw message
meta/recipes-graphics/xorg-xserver/xserver-xorg/CVE-2024-0229-2.patch new file +221 -0
221 lines not on this page · raw message
meta/recipes-graphics/xorg-xserver/xserver-xorg/CVE-2024-0229-3.patch new file +41 -0
41 lines not on this page · raw message
meta/recipes-graphics/xorg-xserver/xserver-xorg/CVE-2024-0229-4.patch new file +45 -0
45 lines not on this page · raw message
meta/recipes-graphics/xorg-xserver/xserver-xorg/CVE-2024-0408.patch new file +64 -0
64 lines not on this page · raw message
meta/recipes-graphics/xorg-xserver/xserver-xorg/CVE-2024-0409.patch new file +46 -0
46 lines not on this page · raw message
meta/recipes-graphics/xorg-xserver/xserver-xorg/CVE-2024-21885.patch new file +113 -0
113 lines not on this page · raw message
meta/recipes-graphics/xorg-xserver/xserver-xorg/CVE-2024-21886-1.patch new file +74 -0
74 lines not on this page · raw message
meta/recipes-graphics/xorg-xserver/xserver-xorg/CVE-2024-21886-2.patch new file +57 -0
57 lines not on this page · raw message
meta/recipes-graphics/xorg-xserver/xserver-xorg_1.20.14.bb +10 -0
@@ -20,6 +20,16 @@ SRC_URI += "file://0001-xf86pciBus.c-use-Intel-ddx-only-for-pre-gen4-hardwar.pat file://CVE-2023-5380.patch \ file://CVE-2023-6377.patch \ file://CVE-2023-6478.patch \ + file://CVE-2023-6816.patch \ + file://CVE-2024-0229-1.patch \ + file://CVE-2024-0229-2.patch \ + file://CVE-2024-0229-3.patch \ + file://CVE-2024-0229-4.patch \ + file://CVE-2024-21885.patch \ + file://CVE-2024-21886-1.patch \ + file://CVE-2024-21886-2.patch \ + file://CVE-2024-0408.patch \ + file://CVE-2024-0409.patch \ " SRC_URI[md5sum] = "453fc86aac8c629b3a5b77e8dcca30bf" SRC_URI[sha256sum] = "54b199c9280ff8bf0f73a54a759645bd0eeeda7255d1c99310d5b7595f3ac066"
Signature · 1 line
2.25.1