# CVE-2025-21994: ksmbd: fix incorrect validation for num_aces field of smb_acl

- Severity: High 7.6 (CVSS:3.1, scored by Linux) `CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:L/A:H`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 0.31%, higher than 25% of CVEs (2026-12-01)
- Published: 2025-04-02T14:00:37.407Z
- Modified: 2026-08-05T11:55:53.957Z
- Assigned by: Linux

## Description

In the Linux kernel, the following vulnerability has been resolved:

ksmbd: fix incorrect validation for num_aces field of smb_acl

parse_dcal() validate num_aces to allocate posix_ace_state_array.

if (num_aces > ULONG_MAX / sizeof(struct smb_ace *))

It is an incorrect validation that we can create an array of size ULONG_MAX.
smb_acl has ->size field to calculate actual number of aces in request buffer
size. Use this to check invalid num_aces.

(As written by CVE List.)

## Affected

- Linux Linux: from 0626e6641f6b467447c81dd7678a69c66f7746cf before c3a3484d9d31b27a3db0fab91fcf191132d65236; from 0626e6641f6b467447c81dd7678a69c66f7746cf before 9c4e202abff45f8eac17989e549fc7a75095f675; from 0626e6641f6b467447c81dd7678a69c66f7746cf before d0f87370622a853b57e851f7d5a5452b72300f19; from 0626e6641f6b467447c81dd7678a69c66f7746cf before a4cb17797a5d241f1e509cb5b46ed95a80c2f5fd; from 0626e6641f6b467447c81dd7678a69c66f7746cf before f6a6721802ac2f12f4c1bbe839a4c229b61866f2; from 0626e6641f6b467447c81dd7678a69c66f7746cf before 1b8b67f3c5e5169535e26efedd3e422172e2db64; 5.15 (not affected: before 5.15; from 5.15.180 up to 5.15.*; from 6.1.132 up to 6.1.*; from 6.6.85 up to 6.6.*; from 6.12.21 up to 6.12.*; from 6.13.9 up to 6.13.*; from 6.14 up to *)
- linux linux_kernel: from 5.15 before 5.15.180; from 5.16 before 6.1.132; from 6.2 before 6.6.85; from 6.7 before 6.12.21; from 6.13 before 6.13.9; 6.14

## Every score

- Linux: CVSS:3.1 7.6 High `CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:L/A:H`
- NVD: CVSS:3.1 5.5 Medium `CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H`

## References

- <https://git.kernel.org/stable/c/c3a3484d9d31b27a3db0fab91fcf191132d65236> (patch)
- <https://git.kernel.org/stable/c/9c4e202abff45f8eac17989e549fc7a75095f675> (patch)
- <https://git.kernel.org/stable/c/d0f87370622a853b57e851f7d5a5452b72300f19> (patch)
- <https://git.kernel.org/stable/c/a4cb17797a5d241f1e509cb5b46ed95a80c2f5fd> (patch)
- <https://git.kernel.org/stable/c/f6a6721802ac2f12f4c1bbe839a4c229b61866f2> (patch)
- <https://git.kernel.org/stable/c/1b8b67f3c5e5169535e26efedd3e422172e2db64> (patch)
- <https://lists.debian.org/debian-lts-announce/2025/05/msg00045.html>

## Sources

- CVE List: [CVE-2025-21994](https://www.cve.org/CVERecord?id=CVE-2025-21994), CVE Terms of Use, modified 2026-08-05
- NVD: [CVE-2025-21994](https://nvd.nist.gov/vuln/detail/CVE-2025-21994), Public domain, modified 2026-07-30

---

Page: https://cve.day/CVE-2025-21994 · Whole record: https://cve.day/CVE-2025-21994.json · Rebuilt by cve.day 2026-11-25T22:58:55.955Z
