CVE-2023-53554: staging: ks7010: potential buffer overflow in ks_wlan_set_encode_ext()
From: Greg Kroah-Hartman <[email protected]>
Description
===========
In the Linux kernel, the following vulnerability has been resolved:
staging: ks7010: potential buffer overflow in ks_wlan_set_encode_ext()
The "exc->key_len" is a u16 that comes from the user. If it's over IW_ENCODING_TOKEN_MAX (64) that could lead to memory corruption.
The Linux kernel CVE team has assigned CVE-2023-53554 to this issue.
Affected and fixed versions
===========================
Issue introduced in 4.12 with commit b121d84882b97b8668be0b95e9ba50cfd01aa0f1 and fixed in 4.14.322 with commit 9496fb96ddeb740dc6b966f4a7d8dfb8b93921c6 Issue introduced in 4.12 with commit b121d84882b97b8668be0b95e9ba50cfd01aa0f1 and fixed in 4.19.291 with commit 663fff29fd613e2b0d30c4138157312ba93c4939 Issue introduced in 4.12 with commit b121d84882b97b8668be0b95e9ba50cfd01aa0f1 and fixed in 5.4.253 with commit 5373a1aa91b2298f9305794b8270cf9896be96b6 Issue introduced in 4.12 with commit b121d84882b97b8668be0b95e9ba50cfd01aa0f1 and fixed in 5.10.190 with commit caac4b6c15b66feae4d83f602e1e46f124540202 Issue introduced in 4.12 with commit b121d84882b97b8668be0b95e9ba50cfd01aa0f1 and fixed in 5.15.124 with commit baf420e30364ef9efe3e29a5c0e01e612aebf3fe Issue introduced in 4.12 with commit b121d84882b97b8668be0b95e9ba50cfd01aa0f1 and fixed in 6.1.43 with commit 7ae9f55a495077f838bab466411ee6f38574df9b Issue introduced in 4.12 with commit b121d84882b97b8668be0b95e9ba50cfd01aa0f1 and fixed in 6.4.8 with commit b1b04b56745bc79286c80aa876fabfab1e08ebf1 Issue introduced in 4.12 with commit b121d84882b97b8668be0b95e9ba50cfd01aa0f1 and fixed in 6.5 with commit 5f1c7031e044cb2fba82836d55cc235e2ad619dc
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-2023-53554
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/staging/ks7010/ks_wlan_net.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/9496fb96ddeb740dc6b966f4a7d8dfb8b93921c6 https://git.kernel.org/stable/c/663fff29fd613e2b0d30c4138157312ba93c4939 https://git.kernel.org/stable/c/5373a1aa91b2298f9305794b8270cf9896be96b6 https://git.kernel.org/stable/c/caac4b6c15b66feae4d83f602e1e46f124540202 https://git.kernel.org/stable/c/baf420e30364ef9efe3e29a5c0e01e612aebf3fe https://git.kernel.org/stable/c/7ae9f55a495077f838bab466411ee6f38574df9b https://git.kernel.org/stable/c/b1b04b56745bc79286c80aa876fabfab1e08ebf1 https://git.kernel.org/stable/c/5f1c7031e044cb2fba82836d55cc235e2ad619dc