From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-alma10-1.taild15c8.ts.net [100.103.45.18]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 7C3204908CA for ; Sat, 25 Jul 2026 08:51:38 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=100.103.45.18 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1784969499; cv=none; b=ANjUT+pUDWZI7cfj+KQt/PPL7xwQAyWK4Xx+hoX8XUWTJgp39Ia/hr5vLF86GBaYxpq1elqO0SHNpSPOUJj38JKE8hxdRb8VKv/AZwcfIMriMP1v89GQH7CMbN6HBI1lrwaNDLM3OdiiWkOzWKPo5mmbcQyd+BuCDgyywNR8OXM= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1784969499; c=relaxed/simple; bh=0I0uc92Au4iw2RWjCUAJ8/1u28p0+I21stknxtyMndc=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=sT+LWRVjvkkF43rZDstFr7ZIC8YLYlGjronuMH43acxzcZ9w0EOqFJ6eNxO7ay7cCst/tMjMDwBuc+71hf//O0S3pnO9R520ytC7yLETKB4QuXO6tMq5qgvoTM+Xhemz7lqDG7ooLmdQlIhm1R4h3T3+7GP3ReGDRSCA3eofZ1Q= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=v9G/FPB8; arc=none smtp.client-ip=100.103.45.18 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b="v9G/FPB8" Received: by smtp.kernel.org (Postfix) with ESMTPSA id A2ABB1F000E9; Sat, 25 Jul 2026 08:51:37 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linuxfoundation.org; s=korg; t=1784969498; bh=4ShcxFJfVcPpAXOF5ugrlJe2fU4H0xPoaBqgifGRhTI=; h=From:To:Cc:Subject:Date:Reply-To; b=v9G/FPB8ekCNZGv7gcGzunr7pMYHzfl4sXOcosiMijS8x759yxGhWGAJhcMuSY6F6 efZeEbos4qohDOhMXNDuxwemovHkmnFU0/J4l7swkJOc49NuWvdHuRKea+xRahE3gC Afh06Do4P+Bo+yoOsq908guWW+xhIEqYONtfpt0U= From: Greg Kroah-Hartman To: linux-cve-announce@vger.kernel.org Cc: Greg Kroah-Hartman Subject: CVE-2026-64277: Input: synaptics-rmi4 - bound the F3A keymap to the GPIO count Date: Sat, 25 Jul 2026 10:48:14 +0200 Message-ID: <2026072501-CVE-2026-64277-34e2@gregkh> X-Mailer: git-send-email 2.55.0 Reply-To: , Precedence: bulk X-Mailing-List: linux-cve-announce@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=4349; i=gregkh@linuxfoundation.org; h=from:subject:message-id; bh=HccIxd9bmhxpvOwHaLMrLwXeGvbRMo48AxnQHuI2AFg=; b=owGbwMvMwCRo6H6F97bub03G02pJDFkpFY67TPktzwR6css11n1uOxDv1DfnxQUOt9Ir1fFmv eo/mRk7YlkYBJkYZMUUWb5s4zm6v+KQopeh7WmYOaxMIEMYuDgFYCK77BkW3Hx94bFCF4dWdPbf 3x8Elq3ddmXTF4YF6xieTD+5wvUsf6uKXY5CjoGi4htRAA== X-Developer-Key: i=gregkh@linuxfoundation.org; a=openpgp; fpr=F4B60CC5BF78C2214A313DCB3147D40DDB2DFB29 Content-Transfer-Encoding: 8bit From: Greg Kroah-Hartman Description =========== In the Linux kernel, the following vulnerability has been resolved: Input: synaptics-rmi4 - bound the F3A keymap to the GPIO count rmi_f3a_initialize() takes the GPIO count from the device query register (f3a->gpio_count = buf & RMI_F3A_GPIO_COUNT, range 0..127). rmi_f3a_map_gpios() then allocates gpio_key_map with min(gpio_count, TRACKSTICK_RANGE_END) == at most 6 entries, but rmi_f3a_attention() iterates the full gpio_count and dereferences gpio_key_map[i], and input->keycodemax is set to the full gpio_count while input->keycode points at the 6-entry allocation. A device that reports gpio_count > 6 therefore causes an out-of-bounds read of gpio_key_map[] on every attention interrupt, and out-of-bounds accesses through the input core's default keymap ioctls: EVIOCGKEYCODE reads past the buffer (leaking adjacent slab memory to user space) and EVIOCSKEYCODE writes a caller-controlled value past it, for any process able to open the evdev node, since input_default_getkeycode() and input_default_setkeycode() only bound the index against keycodemax. Size the keymap for the full gpio_count. The mapping loop is unchanged: it still assigns only the first min(gpio_count, TRACKSTICK_RANGE_END) entries; the remaining slots stay KEY_RESERVED (devm_kcalloc zero-fills) and are skipped when reporting. The Linux kernel CVE team has assigned CVE-2026-64277 to this issue. Affected and fixed versions =========================== Issue introduced in 5.10 with commit 9e4c596bfd004f447a652205163234dfd4aafa69 and fixed in 5.10.261 with commit 502ad7caaa1a445b734c827fa256e5311df67e3d Issue introduced in 5.10 with commit 9e4c596bfd004f447a652205163234dfd4aafa69 and fixed in 5.15.212 with commit 3480e24bc4e178aaa009edb25b6ee12df199e210 Issue introduced in 5.10 with commit 9e4c596bfd004f447a652205163234dfd4aafa69 and fixed in 6.1.178 with commit 35ed74d32d8260bdfb14a94caf402bf0866bdeec Issue introduced in 5.10 with commit 9e4c596bfd004f447a652205163234dfd4aafa69 and fixed in 6.6.145 with commit ba57f430328534501962d60d651e385ffd7af9ca Issue introduced in 5.10 with commit 9e4c596bfd004f447a652205163234dfd4aafa69 and fixed in 6.12.96 with commit 850117b637bcb1dcc14be0cf09ac819a8707b42c Issue introduced in 5.10 with commit 9e4c596bfd004f447a652205163234dfd4aafa69 and fixed in 6.18.39 with commit 8db211aed83733073b0814adaeeab61d4521474e Issue introduced in 5.10 with commit 9e4c596bfd004f447a652205163234dfd4aafa69 and fixed in 7.1.4 with commit 64fb0e1161ccc6b9e48b8df61f07d3c34c01ec42 Issue introduced in 5.10 with commit 9e4c596bfd004f447a652205163234dfd4aafa69 and fixed in 7.2-rc1 with commit 57c10915f2c16c90e0d46ad00876bf39ece40fc2 Please see https://www.kernel.org for a full list of currently supported kernel versions by the kernel community. Unaffected versions might change over time as fixes are backported to older supported kernel versions. The official CVE entry at https://cve.org/CVERecord/?id=CVE-2026-64277 will be updated if fixes are backported, please check that for the most up to date information about this issue. Affected files ============== The file(s) affected by this issue are: drivers/input/rmi4/rmi_f3a.c Mitigation ========== The Linux kernel CVE team recommends that you update to the latest stable kernel version for this, and many other bugfixes. Individual changes are never tested alone, but rather are part of a larger kernel release. Cherry-picking individual commits is not recommended or supported by the Linux kernel community at all. If however, updating to the latest release is impossible, the individual changes to resolve this issue can be found at these commits: https://git.kernel.org/stable/c/502ad7caaa1a445b734c827fa256e5311df67e3d https://git.kernel.org/stable/c/3480e24bc4e178aaa009edb25b6ee12df199e210 https://git.kernel.org/stable/c/35ed74d32d8260bdfb14a94caf402bf0866bdeec https://git.kernel.org/stable/c/ba57f430328534501962d60d651e385ffd7af9ca https://git.kernel.org/stable/c/850117b637bcb1dcc14be0cf09ac819a8707b42c https://git.kernel.org/stable/c/8db211aed83733073b0814adaeeab61d4521474e https://git.kernel.org/stable/c/64fb0e1161ccc6b9e48b8df61f07d3c34c01ec42 https://git.kernel.org/stable/c/57c10915f2c16c90e0d46ad00876bf39ece40fc2