xserver: Branch 'server-1.20-branch'

GitLab Mirror gitlab-mirror at kemper.freedesktop.org
Tue Apr 13 14:00:38 UTC 2021


 Xi/chgfctl.c |    5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

New commits:
commit a1a1aa2c14636284669b28a956d756d5705dcf15
Author: Matthieu Herrb <matthieu at herrb.eu>
Date:   Sun Mar 21 18:38:57 2021 +0100

    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 at herrb.eu>

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;


More information about the xorg-commit mailing list