CVE-2024-42256
Severity CVSS v4.0:
Pending analysis
Type:
Unavailable / Other
Publication date:
08/08/2024
Last modified:
06/09/2024
Description
In the Linux kernel, the following vulnerability has been resolved:<br />
<br />
cifs: Fix server re-repick on subrequest retry<br />
<br />
When a subrequest is marked for needing retry, netfs will call<br />
cifs_prepare_write() which will make cifs repick the server for the op<br />
before renegotiating credits; it then calls cifs_issue_write() which<br />
invokes smb2_async_writev() - which re-repicks the server.<br />
<br />
If a different server is then selected, this causes the increment of<br />
server->in_flight to happen against one record and the decrement to happen<br />
against another, leading to misaccounting.<br />
<br />
Fix this by just removing the repick code in smb2_async_writev(). As this<br />
is only called from netfslib-driven code, cifs_prepare_write() should<br />
always have been called first, and so server should never be NULL and the<br />
preparatory step is repeated in the event that we do a retry.<br />
<br />
The problem manifests as a warning looking something like:<br />
<br />
WARNING: CPU: 4 PID: 72896 at fs/smb/client/smb2ops.c:97 smb2_add_credits+0x3f0/0x9e0 [cifs]<br />
...<br />
RIP: 0010:smb2_add_credits+0x3f0/0x9e0 [cifs]<br />
...<br />
smb2_writev_callback+0x334/0x560 [cifs]<br />
cifs_demultiplex_thread+0x77a/0x11b0 [cifs]<br />
kthread+0x187/0x1d0<br />
ret_from_fork+0x34/0x60<br />
ret_from_fork_asm+0x1a/0x30<br />
<br />
Which may be triggered by a number of different xfstests running against an<br />
Azure server in multichannel mode. generic/249 seems the most repeatable,<br />
but generic/215, generic/249 and generic/308 may also show it.
Impact
Base Score 3.x
9.80
Severity 3.x
CRITICAL
Vulnerable products and versions
| CPE | From | Up to |
|---|---|---|
| cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:* | 6.10 (including) | 6.10.1 (excluding) |
To consult the complete list of CPE names with products and versions, see this page



