ksmbd: fix incorrect validation for num_aces field of smb_acl
Linux
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
Linux
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
≥ 0626e6641f6b467447c81dd7678a69c66f7746cf · < 1b8b67f3c5e5169535e26efedd3e422172e2db64| No fix yet |
| Linux Linux |
|
|
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.
From the CVE record · Linux
The Linux kernel's ksmbd component incorrectly validates the num_aces field of an SMB ACL against an allocation limit rather than the number of ACEs that fit in the request buffer. A request with an invalid num_aces value can pass that check; the input does not specify authentication requirements, user interaction, or the resulting impact.
Engineers running Linux kernels with ksmbd should check whether their kernel is affected; affected versions are not specified.