Vulnerability · Published May 1, 2026 · Assigned by Linux
CVE-2026-31705ksmbd: fix out-of-bounds write in smb2_get_ea() EA alignment
Critical 9.8
In plain English
A critical-severity security flaw in Linux from Linux. There are no confirmed reports of exploitation so far. The chance it is exploited in the next 30 days is estimated at 0.4% (higher than 34% of all known vulnerabilities). Fixed versions are available - upgrade the affected package.
Official description
In the Linux kernel, the following vulnerability has been resolved: ksmbd: fix out-of-bounds write in smb2_get_ea() EA alignment smb2_get_ea() applies 4-byte alignment padding via memset() after writing each EA entry. The bounds check on buf_free_len is performed before the value memcpy, but the alignment memset fires unconditionally afterward with no check on remaining space. When the EA value exactly fills the remaining buffer (buf_free_len == 0 after value subtraction), the alignment memset writes 1-3 NUL bytes past the buf_free_len boundary. In compound requests where the response buffer is shared across commands, the first command (e.g., READ) can consume most of the buffer, leaving a tight remainder for the QUERY_INFO EA response. The alignment memset then overwrites past the physical kvmalloc allocation into adjacent kernel heap memory. Add a bounds check before the alignment memset to ensure buf_free_len can accommodate the padding bytes. This is the same bug pattern fixed by commit beef2634f81f ("ksmbd: fix potencial OOB in get_file_all_info() for compound requests") and commit fda9522ed6af ("ksmbd: fix OOB write in QUERY_INFO for compound requests"), both of which added bounds checks before unconditional writes in QUERY_INFO response handlers.
Affected packages & fixed versions
| Ecosystem | Package | Fixed in | Advisory |
|---|---|---|---|
| Debian:12 | linux | 6.1.176-1 | DEBIAN-CVE-2026-31705 |
| Debian:13 | linux | 6.12.85-1 | DEBIAN-CVE-2026-31705 |
| Debian:14 | linux | 7.0.3-1 | DEBIAN-CVE-2026-31705 |
| Ubuntu:22.04:LTS | linux | 5.15.0-187.197 | USN-8631-1 |
| Ubuntu:22.04:LTS | linux | 5.15.0-187.197 | UBUNTU-CVE-2026-31705 |
| Ubuntu:24.04:LTS | linux | 6.8.0-136.136 | UBUNTU-CVE-2026-31705 |
| Ubuntu:25.10 | linux | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:26.04:LTS | linux | 7.0.0-27.27 | UBUNTU-CVE-2026-31705 |
| Ubuntu:22.04:LTS | linux-allwinner-5.19 | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:22.04:LTS | linux-aws | 5.15.0-1113.120 | USN-8631-1 |
| Ubuntu:22.04:LTS | linux-aws | 5.15.0-1113.120 | UBUNTU-CVE-2026-31705 |
| Ubuntu:24.04:LTS | linux-aws | 6.8.0-1061.64 | UBUNTU-CVE-2026-31705 |
| Ubuntu:25.10 | linux-aws | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:26.04:LTS | linux-aws | 7.0.0-1008.8 | UBUNTU-CVE-2026-31705 |
| Ubuntu:22.04:LTS | linux-aws-5.19 | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:24.04:LTS | linux-aws-6.14 | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:24.04:LTS | linux-aws-6.17 | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:22.04:LTS | linux-aws-6.2 | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:22.04:LTS | linux-aws-6.5 | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:22.04:LTS | linux-aws-6.8 | 6.8.0-1061.64~22.04.1 | UBUNTU-CVE-2026-31705 |
| Ubuntu:22.04:LTS | linux-azure | 5.15.0-1118.127 | UBUNTU-CVE-2026-31705 |
| Ubuntu:22.04:LTS | linux-azure | 5.15.0-1118.127 | USN-8631-1 |
| Ubuntu:24.04:LTS | linux-azure | 6.8.0-1063.71 | UBUNTU-CVE-2026-31705 |
| Ubuntu:25.10 | linux-azure | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:26.04:LTS | linux-azure | 7.0.0-1010.10 | UBUNTU-CVE-2026-31705 |
| Ubuntu:22.04:LTS | linux-azure-5.19 | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:24.04:LTS | linux-azure-6.11 | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:24.04:LTS | linux-azure-6.14 | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:24.04:LTS | linux-azure-6.17 | 6.17.0-1022.22 | UBUNTU-CVE-2026-31705 |
| Ubuntu:24.04:LTS | linux-azure-6.17 | 6.17.0-1022.22 | USN-8636-1 |
| Ubuntu:22.04:LTS | linux-azure-6.2 | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:22.04:LTS | linux-azure-6.5 | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:22.04:LTS | linux-azure-6.8 | 6.8.0-1063.71~22.04.1 | UBUNTU-CVE-2026-31705 |
| Ubuntu:22.04:LTS | linux-azure-fde | 5.15.0-1118.127 | USN-8631-1 |
| Ubuntu:22.04:LTS | linux-azure-fde | 5.15.0-1118.127 | UBUNTU-CVE-2026-31705 |
| Ubuntu:24.04:LTS | linux-azure-fde | 6.8.0-1062.69 | UBUNTU-CVE-2026-31705 |
| Ubuntu:25.10 | linux-azure-fde | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:26.04:LTS | linux-azure-fde | 7.0.0-1009.9 | UBUNTU-CVE-2026-31705 |
| Ubuntu:22.04:LTS | linux-azure-fde-5.19 | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:24.04:LTS | linux-azure-fde-6.14 | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:22.04:LTS | linux-azure-fde-6.2 | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:22.04:LTS | linux-azure-fde-6.8 | 6.8.0-1062.69~22.04.1 | UBUNTU-CVE-2026-31705 |
| Ubuntu:24.04:LTS | linux-azure-nvidia | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:24.04:LTS | linux-azure-nvidia-6.14 | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:22.04:LTS | linux-gcp | 5.15.0-1114.124 | UBUNTU-CVE-2026-31705 |
| Ubuntu:22.04:LTS | linux-gcp | 5.15.0-1114.124 | USN-8661-1 |
| Ubuntu:24.04:LTS | linux-gcp | 6.8.0-1064.72 | UBUNTU-CVE-2026-31705 |
| Ubuntu:25.10 | linux-gcp | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:26.04:LTS | linux-gcp | 7.0.0-1007.7 | UBUNTU-CVE-2026-31705 |
| Ubuntu:22.04:LTS | linux-gcp-5.19 | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:24.04:LTS | linux-gcp-6.11 | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:24.04:LTS | linux-gcp-6.14 | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:24.04:LTS | linux-gcp-6.17 | 6.17.0-1022.25 | USN-8636-1 |
| Ubuntu:24.04:LTS | linux-gcp-6.17 | 6.17.0-1022.25 | UBUNTU-CVE-2026-31705 |
| Ubuntu:22.04:LTS | linux-gcp-6.2 | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:22.04:LTS | linux-gcp-6.5 | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:22.04:LTS | linux-gcp-6.8 | 6.8.0-1064.72~22.04.1 | UBUNTU-CVE-2026-31705 |
| Ubuntu:22.04:LTS | linux-gke | 5.15.0-1110.116 | USN-8661-3 |
| Ubuntu:22.04:LTS | linux-gke | 5.15.0-1110.116 | UBUNTU-CVE-2026-31705 |
| Ubuntu:24.04:LTS | linux-gke | 6.8.0-1059.67 | UBUNTU-CVE-2026-31705 |
| Ubuntu:22.04:LTS | linux-gkeop | 5.15.0-1096.104 | USN-8631-1 |
| Ubuntu:22.04:LTS | linux-gkeop | 5.15.0-1096.104 | UBUNTU-CVE-2026-31705 |
| Ubuntu:24.04:LTS | linux-gkeop | 6.8.0-1046.50 | UBUNTU-CVE-2026-31705 |
| Ubuntu:22.04:LTS | linux-hwe-5.19 | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:24.04:LTS | linux-hwe-6.11 | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:24.04:LTS | linux-hwe-6.14 | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:24.04:LTS | linux-hwe-6.17 | 6.17.0-42.42 | USN-8636-1 |
| Ubuntu:24.04:LTS | linux-hwe-6.17 | 6.17.0-42.42 | UBUNTU-CVE-2026-31705 |
| Ubuntu:22.04:LTS | linux-hwe-6.2 | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:22.04:LTS | linux-hwe-6.5 | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:22.04:LTS | linux-hwe-6.8 | 6.8.0-136.136~22.04.1 | UBUNTU-CVE-2026-31705 |
| Ubuntu:24.04:LTS | linux-hwe-7.0 | 7.0.0-28.28~24.04.1 | UBUNTU-CVE-2026-31705 |
| Ubuntu:22.04:LTS | linux-ibm | 5.15.0-1107.111 | USN-8631-1 |
| Ubuntu:22.04:LTS | linux-ibm | 5.15.0-1107.111 | UBUNTU-CVE-2026-31705 |
| Ubuntu:24.04:LTS | linux-ibm | 6.8.0-1061.62 | UBUNTU-CVE-2026-31705 |
| Ubuntu:26.04:LTS | linux-ibm | 7.0.0-1009.9 | UBUNTU-CVE-2026-31705 |
| Ubuntu:22.04:LTS | linux-ibm-6.8 | 6.8.0-1061.62~22.04.1 | UBUNTU-CVE-2026-31705 |
| Ubuntu:22.04:LTS | linux-intel-iot-realtime | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:22.04:LTS | linux-intel-iotg | 5.15.0-1108.114 | UBUNTU-CVE-2026-31705 |
| Ubuntu:22.04:LTS | linux-intel-iotg | 5.15.0-1108.114 | USN-8631-1 |
| Ubuntu:22.04:LTS | linux-kvm | 5.15.0-1105.110 | USN-8631-1 |
| Ubuntu:22.04:LTS | linux-kvm | 5.15.0-1105.110 | UBUNTU-CVE-2026-31705 |
| Ubuntu:22.04:LTS | linux-lowlatency | 5.15.0-190.200 | UBUNTU-CVE-2026-31705 |
| Ubuntu:22.04:LTS | linux-lowlatency | 5.15.0-190.200 | USN-8661-2 |
| Ubuntu:24.04:LTS | linux-lowlatency | 6.8.0-136.136.2 | UBUNTU-CVE-2026-31705 |
| Ubuntu:22.04:LTS | linux-lowlatency-hwe-5.19 | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:24.04:LTS | linux-lowlatency-hwe-6.11 | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:22.04:LTS | linux-lowlatency-hwe-6.2 | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:22.04:LTS | linux-lowlatency-hwe-6.5 | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:22.04:LTS | linux-lowlatency-hwe-6.8 | 6.8.0-136.136.2~22.04.1 | UBUNTU-CVE-2026-31705 |
| Ubuntu:22.04:LTS | linux-nvidia | 5.15.0-1108.109 | UBUNTU-CVE-2026-31705 |
| Ubuntu:22.04:LTS | linux-nvidia | 5.15.0-1108.109 | USN-8631-1 |
| Ubuntu:24.04:LTS | linux-nvidia | 6.8.0-1059.62 | UBUNTU-CVE-2026-31705 |
| Ubuntu:26.04:LTS | linux-nvidia | 7.0.0-1013.13 | UBUNTU-CVE-2026-31705 |
| Ubuntu:24.04:LTS | linux-nvidia-6.11 | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:24.04:LTS | linux-nvidia-6.17 | 6.17.0-1031.31 | UBUNTU-CVE-2026-31705 |
| Ubuntu:22.04:LTS | linux-nvidia-6.2 | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:22.04:LTS | linux-nvidia-6.5 | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:22.04:LTS | linux-nvidia-6.8 | 6.8.0-1059.62~22.04.1 | UBUNTU-CVE-2026-31705 |
| Ubuntu:24.04:LTS | linux-nvidia-lowlatency | 6.8.0-1059.62.1 | UBUNTU-CVE-2026-31705 |
| Ubuntu:22.04:LTS | linux-nvidia-tegra | 5.15.0-1065.67 | USN-8631-1 |
| Ubuntu:22.04:LTS | linux-nvidia-tegra | 5.15.0-1065.67 | UBUNTU-CVE-2026-31705 |
| Ubuntu:24.04:LTS | linux-nvidia-tegra | 6.8.0-1030.31 | UBUNTU-CVE-2026-31705 |
| Ubuntu:22.04:LTS | linux-nvidia-tegra-igx | 5.15.0-1054.54 | USN-8631-3 |
| Ubuntu:22.04:LTS | linux-nvidia-tegra-igx | 5.15.0-1054.54 | UBUNTU-CVE-2026-31705 |
| Ubuntu:22.04:LTS | linux-oem-5.17 | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:22.04:LTS | linux-oem-6.0 | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:22.04:LTS | linux-oem-6.1 | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:24.04:LTS | linux-oem-6.11 | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:24.04:LTS | linux-oem-6.14 | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:24.04:LTS | linux-oem-6.17 | 6.17.0-1032.32 | USN-8636-1 |
| Ubuntu:24.04:LTS | linux-oem-6.17 | 6.17.0-1032.32 | UBUNTU-CVE-2026-31705 |
| Ubuntu:22.04:LTS | linux-oem-6.5 | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:24.04:LTS | linux-oem-6.8 | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:22.04:LTS | linux-oracle | 5.15.0-1110.116 | USN-8631-2 |
| Ubuntu:22.04:LTS | linux-oracle | 5.15.0-1110.116 | UBUNTU-CVE-2026-31705 |
| Ubuntu:24.04:LTS | linux-oracle | 6.8.0-1058.61 | UBUNTU-CVE-2026-31705 |
| Ubuntu:25.10 | linux-oracle | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:26.04:LTS | linux-oracle | 7.0.0-1007.7 | UBUNTU-CVE-2026-31705 |
| Ubuntu:24.04:LTS | linux-oracle-6.14 | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:24.04:LTS | linux-oracle-6.17 | 6.17.0-1020.20 | UBUNTU-CVE-2026-31705 |
| Ubuntu:24.04:LTS | linux-oracle-6.17 | 6.17.0-1020.20 | USN-8636-2 |
| Ubuntu:22.04:LTS | linux-oracle-6.5 | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:22.04:LTS | linux-oracle-6.8 | 6.8.0-1058.61~22.04.1 | UBUNTU-CVE-2026-31705 |
| Ubuntu:22.04:LTS | linux-raspi | 5.15.0-1108.111 | USN-8661-5 |
| Ubuntu:22.04:LTS | linux-raspi | 5.15.0-1108.111 | UBUNTU-CVE-2026-31705 |
| Ubuntu:24.04:LTS | linux-raspi | 6.8.0-1061.65 | UBUNTU-CVE-2026-31705 |
| Ubuntu:25.10 | linux-raspi | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:26.04:LTS | linux-raspi | 7.0.0-1014.14 | UBUNTU-CVE-2026-31705 |
| Ubuntu:24.04:LTS | linux-raspi-realtime | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:22.04:LTS | linux-realtime | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:24.04:LTS | linux-realtime | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:25.10 | linux-realtime | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:26.04:LTS | linux-realtime | 7.0.0-27.27.1 | UBUNTU-CVE-2026-31705 |
| Ubuntu:22.04:LTS | linux-riscv | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:24.04:LTS | linux-riscv | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:25.10 | linux-riscv | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:26.04:LTS | linux-riscv | 7.0.0-27.27.1 | UBUNTU-CVE-2026-31705 |
| Ubuntu:22.04:LTS | linux-riscv-5.19 | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:24.04:LTS | linux-riscv-6.14 | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:24.04:LTS | linux-riscv-6.17 | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:22.04:LTS | linux-riscv-6.5 | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:22.04:LTS | linux-riscv-6.8 | 6.8.0-136.136~22.04.3 | UBUNTU-CVE-2026-31705 |
| Ubuntu:22.04:LTS | linux-starfive-5.19 | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:22.04:LTS | linux-starfive-6.2 | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:22.04:LTS | linux-starfive-6.5 | no fix listed | UBUNTU-CVE-2026-31705 |
| Ubuntu:24.04:LTS | linux-vmware | 6.8.0-1008.8 | UBUNTU-CVE-2026-31705 |
| Ubuntu:24.04:LTS | linux-xilinx | 6.8.0-1033.34 | UBUNTU-CVE-2026-31705 |
| Ubuntu:22.04:LTS | linux-xilinx-zynqmp | 5.15.0-1076.80 | UBUNTU-CVE-2026-31705 |
| Ubuntu:22.04:LTS | linux-xilinx-zynqmp | 5.15.0-1076.80 | USN-8631-1 |
Affected products (as reported)
| Vendor | Product | Versions |
|---|---|---|
| Linux | Linux | 9f297df20d93411c0b4ddad7f88ba04a7cd36e77 – before ddbbc8b2a09dd2cfed90871313e3691ae1db08a2e2b76ab8b5c9327ab2dae6da05d0752eb2f4771d – before ffbce350c6fd1e99116ea57383b9031717e36d3be2b76ab8b5c9327ab2dae6da05d0752eb2f4771d – before 98f3de6ef4efbd899348d333f0902dc4ff14380ce2b76ab8b5c9327ab2dae6da05d0752eb2f4771d – before 790304c02bf9bd7b8171feda4294d6e62d32ae8fe2b76ab8b5c9327ab2dae6da05d0752eb2f4771d – before 922d48fe8c19f388ffa2f709f33acaae4e408de2e2b76ab8b5c9327ab2dae6da05d0752eb2f4771d – before 30010c952077a1c89ecdd71fc4d574c75a8f5617f2283680a80571ca82d710bc6ecd8f8beac67d636.1.71 – before 6.1.175 |
| Linux | Linux | 6.6 |
References
- https://git.kernel.org/stable/c/ddbbc8b2a09dd2cfed90871313e3691ae1db08a2
- https://git.kernel.org/stable/c/ffbce350c6fd1e99116ea57383b9031717e36d3b
- https://git.kernel.org/stable/c/98f3de6ef4efbd899348d333f0902dc4ff14380c
- https://git.kernel.org/stable/c/790304c02bf9bd7b8171feda4294d6e62d32ae8f
- https://git.kernel.org/stable/c/922d48fe8c19f388ffa2f709f33acaae4e408de2
- https://git.kernel.org/stable/c/30010c952077a1c89ecdd71fc4d574c75a8f5617
- https://cert-portal.siemens.com/productcert/html/ssa-784472.html