unofficial mirror of guix-patches@gnu.org 
 help / color / mirror / code / Atom feed
blob 523a5b1dbff05d4fc0f7392a1a2ea9a6dd924d63 1397 bytes (raw)
name: gnu/packages/patches/xorg-server-CVE-2021-3472.patch 	 # note: path name is non-authoritative(*)

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
 
Fix CVE-2021-3472:

https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2021-3472
https://seclists.org/oss-sec/2021/q2/20

Patch copied from upstream source repository:

https://gitlab.freedesktop.org/xorg/xserver/-/commit/7aaf54a1884f71dc363f0b884e57bcb67407a6cd

From 7aaf54a1884f71dc363f0b884e57bcb67407a6cd Mon Sep 17 00:00:00 2001
From: Matthieu Herrb <matthieu@herrb.eu>
Date: Sun, 21 Mar 2021 18:38:57 +0100
Subject: [PATCH] Fix XChangeFeedbackControl() request underflow

CVE-2021-3472 / ZDI-CAN-1259

This vulnerability was discovered by:
Jan-Niklas Sohn working with Trend Micro Zero Day Initiative

Signed-off-by: Matthieu Herrb <matthieu@herrb.eu>
---
 Xi/chgfctl.c | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/Xi/chgfctl.c b/Xi/chgfctl.c
index 1de4da9ef..7a597e43d 100644
--- a/Xi/chgfctl.c
+++ b/Xi/chgfctl.c
@@ -464,8 +464,11 @@ ProcXChangeFeedbackControl(ClientPtr client)
         break;
     case StringFeedbackClass:
     {
-        xStringFeedbackCtl *f = ((xStringFeedbackCtl *) &stuff[1]);
+        xStringFeedbackCtl *f;
 
+        REQUEST_AT_LEAST_EXTRA_SIZE(xChangeFeedbackControlReq,
+                                    sizeof(xStringFeedbackCtl));
+        f = ((xStringFeedbackCtl *) &stuff[1]);
         if (client->swapped) {
             if (len < bytes_to_int32(sizeof(xStringFeedbackCtl)))
                 return BadLength;
-- 
2.31.1


debug log:

solving 523a5b1dbf ...
found 523a5b1dbf in https://yhetil.org/guix-patches/YISPXgLbiVYNzzDN@jasmine.lan/ ||
	https://yhetil.org/guix-patches/dacfdb6bb4549e538777842d345baa860de6d114.1619293138.git.leo@famulari.name/

applying [1/1] https://yhetil.org/guix-patches/YISPXgLbiVYNzzDN@jasmine.lan/
diff --git a/gnu/packages/patches/xorg-server-CVE-2021-3472.patch b/gnu/packages/patches/xorg-server-CVE-2021-3472.patch
new file mode 100644
index 0000000000..523a5b1dbf

1:41: trailing whitespace.
 
1:48: trailing whitespace.
-- 
Checking patch gnu/packages/patches/xorg-server-CVE-2021-3472.patch...
1:50: new blank line at EOF.
+
Applied patch gnu/packages/patches/xorg-server-CVE-2021-3472.patch cleanly.
warning: 3 lines add whitespace errors.

skipping https://yhetil.org/guix-patches/dacfdb6bb4549e538777842d345baa860de6d114.1619293138.git.leo@famulari.name/ for 523a5b1dbf
index at:
100644 523a5b1dbff05d4fc0f7392a1a2ea9a6dd924d63	gnu/packages/patches/xorg-server-CVE-2021-3472.patch

(*) Git path names are given by the tree(s) the blob belongs to.
    Blobs themselves have no identifier aside from the hash of its contents.^

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).