Fedora Account System
Red Hat Associate
Red Hat Customer
Disclaimer: Community trackers are created by Red Hat Product Security team on a best effort basis. Package maintainers are required to ascertain if the flaw indeed affects their package, before starting the update process. This is caused by an incomplete fix regression from commit a3171732d. XkbAllocNames() still uses max_key_code+1 for the names->keys allocation size, while memset in the ChangeKeycodeRange path uses MAP_LENGTH which can be larger. This causes a heap out-of-bounds write when the keycode range is changed to a value where MAP_LENGTH exceeds max_key_code+1. An authenticated X client can trigger this by sending XKB requests that change the keycode range. The heap out-of-bounds write can lead to arbitrary code execution or denial of service. Fixed in: xorg-server-21.1.25 and xwayland-24.1.14 Fix: https://gitlab.freedesktop.org/xorg/xserver/-/commit/TBD Found by: Anonymous working with TrendAI Zero Day Initiative. (ZDI-CAN-31941) * Patch From 58e2874f69ef83323cdd18a4004535e06a8947bb Mon Sep 17 00:00:00 2001 From: Peter Hutterer <peter.hutterer> Date: Wed, 26 Aug 2026 17:04:03 +1000 Subject: [PATCH xserver] xkb: allocate names->keys to MAP_LENGTH in XkbAllocNames Commit a3171732d ("xkb: Always use MAP_LENGTH keymap size") converted most XKB allocation functions to use MAP_LENGTH (256) instead of max_key_code + 1. It also removed the per-array reallocarray() calls in XkbChangeKeycodeRange(), replacing them with a memset up to MAP_LENGTH. However, XkbAllocNames() was missed and still allocates names->keys to max_key_code + 1. When a keycodes component with max_key_code < 255 is loaded (e.g. sun(type6) with max_key_code=132) and then a SetMap request extends maxKeyCode to 255, XkbChangeKeycodeRange() memsets names->keys from max_key_code to MAP_LENGTH-1, writing past the undersized allocation. Fix by allocating names->keys to MAP_LENGTH, consistent with all other keymap arrays after a3171732d. This vulnerability was discovered by: Anonymous working with TrendAI Zero Day Initiative ZDI-CAN-31941 CVE-2026-93520 Fixes: a3171732da50 ("xkb: Always use MAP_LENGTH keymap size") Assisted-by: Claude:claude-opus-4-6 #+begin_src diff --- xkb/XKBAlloc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/xkb/XKBAlloc.c b/xkb/XKBAlloc.c index dced42eebd2c..314a858ddb09 100644 --- a/xkb/XKBAlloc.c +++ b/xkb/XKBAlloc.c @@ -143,17 +143,17 @@ XkbAllocNames(XkbDescPtr xkb, unsigned which, int nTotalRG, int nTotalAliases) } } } if ((which & XkbKeyNamesMask) && (names->keys == NULL)) { if ((!XkbIsLegalKeycode(xkb->min_key_code)) || (!XkbIsLegalKeycode(xkb->max_key_code)) || (xkb->max_key_code < xkb->min_key_code)) return BadValue; - names->keys = calloc((xkb->max_key_code + 1), sizeof(XkbKeyNameRec)); + names->keys = calloc(MAP_LENGTH, sizeof(XkbKeyNameRec)); if (names->keys == NULL) return BadAlloc; } if ((which & XkbKeyAliasesMask) && (nTotalAliases > 0)) { if (names->key_aliases == NULL) { names->key_aliases = calloc(nTotalAliases, sizeof(XkbKeyAliasRec)); } else if (nTotalAliases > names->num_key_aliases) { -- 2.55.0 #+end_src
FEDORA-2026-6b7d3e80f7 (tigervnc-1.16.2-9.fc44) has been submitted as an update to Fedora 44. https://bodhi.fedoraproject.org/updates/FEDORA-2026-6b7d3e80f7
FEDORA-2026-80450b1573 (tigervnc-1.16.2-9.fc45) has been submitted as an update to Fedora 45. https://bodhi.fedoraproject.org/updates/FEDORA-2026-80450b1573
FEDORA-2026-6b7d3e80f7 has been pushed to the Fedora 44 testing repository. Soon you'll be able to install the update with the following command: `sudo dnf upgrade --enablerepo=updates-testing --refresh --advisory=FEDORA-2026-6b7d3e80f7` You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2026-6b7d3e80f7 See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.
FEDORA-2026-80450b1573 has been pushed to the Fedora 45 testing repository. Soon you'll be able to install the update with the following command: `sudo dnf upgrade --enablerepo=updates-testing --refresh --advisory=FEDORA-2026-80450b1573` You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2026-80450b1573 See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.
FEDORA-2026-6b7d3e80f7 (tigervnc-1.16.2-9.fc44) has been pushed to the Fedora 44 stable repository. If problem still persists, please make note of it in this bug report.
FEDORA-2026-80450b1573 (tigervnc-1.16.2-9.fc45) has been pushed to the Fedora 45 stable repository. If problem still persists, please make note of it in this bug report.