CVE-2024-27036: cifs: Fix writeback data corruption
In the Linux kernel, the following vulnerability has been resolved:
cifs: Fix writeback data corruption
cifs writeback doesn't correctly handle the case where
cifs_extend_writeback() hits a point where it is considering an additional
folio, but this would overrun the wsize - at which point it drops out of
the xarray scanning loop and calls xas_pause(). The problem is that
xas_pause() advances the loop counter - thereby skipping that page.
What needs to happen is for xas_reset() to be called any time we decide we
don't want to process the page we're looking at, but rather send the
request we are building and start a new one.
Fix this by copying and adapting the netfslib writepages code as a
temporary measure, with cifs writeback intending to be offloaded to
netfslib in the near future.
This also fixes the issue with the use of filemap_get_folios_tag() causing
retry of a bunch of pages which the extender already dealt with.
This can be tested by creating, say, a 64K file somewhere not on cifs
(otherwise copy-offload may get underfoot), mounting a cifs share with a
wsize of 64000, copying the file to it and then comparing the original file
and the copy:
dd if=/dev/urandom of=/tmp/64K bs=64k count=1
mount //192.168.6.1/test /mnt -o user=...,pass=...,wsize=64000
cp /tmp/64K /mnt/64K
cmp /tmp/64K /mnt/64K
Without the fix, the cmp fails at position 64000 (or shortly thereafter).
Security readout for executives and security teams
Plain-English summary
CVE-2024-27036 is a Linux kernel CIFS client data integrity bug. Under specific SMB/CIFS writeback conditions, writes to a network share can skip a page and corrupt copied data. This is primarily an operational reliability and integrity risk, not a confirmed remote takeover issue.
Executive priority
Treat this as a moderate-priority data integrity issue. It can silently corrupt files written to network shares, which may affect backups, shared business documents, or operational datasets. Prioritize patching CIFS-writing Linux clients over unrelated systems.
Technical view
The CIFS writeback path mishandles xarray scanning when extending a writeback request would exceed wsize. Calling xas_pause() advances iteration and can skip a folio; the fix resets scanning and adapts netfslib writepages logic. The source describes corruption near the wsize boundary, with stable kernel commits provided.
Likely exposure
Linux systems using the kernel CIFS/SMB client to write files to network shares are the relevant exposure. Risk is higher where affected kernels use CIFS mounts with write sizes that trigger the boundary condition. Systems not using CIFS writes are unlikely to be exposed.
Exploitation context
The source bundle does not cite active exploitation, and KEV is false. Evidence supports a reproducible data corruption condition, not public weaponization. The CVE text includes a test scenario, but no attacker model, privilege requirement, or remote exploit path is established.
Researcher notes
The record lacks CVSS, CWE, and a detailed threat model. The strongest evidence is the kernel maintainer description and stable commits. Focus research on affected CIFS writeback behavior, version-range confirmation, and distribution backport status rather than assuming exploitability beyond corruption.
Mitigation direction
Upgrade to a kernel containing the referenced stable CIFS fixes.
Check Linux distribution advisories for backported fixes and exact package versions.
Prioritize systems writing important data to CIFS or SMB shares.
Avoid relying on affected CIFS write paths for critical transfers until fixed.
Use integrity checks for important files copied to CIFS shares.
Validation and detection
Inventory Linux hosts that mount CIFS or SMB shares for writes.
Map running kernel versions against distribution advisories for CVE-2024-27036.
Review CIFS mount options, especially configured write size behavior.
Perform non-destructive file integrity testing in a controlled environment.
Confirm the relevant stable fix is present in installed kernel source or changelog.
Generated from the cited source records. This long-tail analysis has not been individually reviewed by a named human.
Potential ATT&CK relevance
Conservative CVE-to-ATT&CK context
These mappings and lookup hints may be relevant to the vulnerability behavior, CWE, affected product, or exposure path. Glexia-inferred context is not an official MITRE, ATT&CK, CWE, or CVE Program mapping.
ATT&CK lookup starting points
Use these exact CWE pages and searches to review the Glexia ATT&CK library from this CVE's weakness and description context.
cve · low confidence lookup
CVE-2024-27036 mapping review
Open the CVE-to-ATT&CK bridge for reviewed, inferred, or future official mappings tied to this CVE.
These fields come from the CVE record and ADP containers, not from Glexia's Take. They preserve time-varying source decisions such as CISA SSVC, KEV status, CVSS metrics, and provider references.