CVE-2022-49655
fscache: Fix invalidation/lookup race
Check your servers for CVE-2022-49655
The Vulnpocalypse collector sends the package list of each Linux server and of its container images once a day. Vulnpocalypse shows every server where CVE-2022-49655 affects the running kernel, with the command that installs the fix. The free plan covers one server and one domain and does not need a credit card.
Description
In the Linux kernel, the following vulnerability has been resolved:
fscache: Fix invalidation/lookup race
If an NFS file is opened for writing and closed, fscache_invalidate() will be asked to invalidate the file - however, if the cookie is in the LOOKING_UP state (or the CREATING state), then request to invalidate doesn't get recorded for fscache_cookie_state_machine() to do something with.
Fix this by making __fscache_invalidate() set a flag if it sees the cookie is in the LOOKING_UP state to indicate that we need to go to invalidation. Note that this requires a count on the n_accesses counter for the state machine, which that will release when it's done.
fscache_cookie_state_machine() then shifts to the INVALIDATING state if it sees the flag.
Without this, an nfs file can get corrupted if it gets modified locally and then read locally as the cache contents may not get updated.
Exploitation
EPSS 0.15%: the probability of exploitation activity in the next 30 days, from the EPSS model of FIRST. The score is higher than 4.29% of all scored CVEs. Scores of 1 Dec 2026.
Affected products
As the CNA lists them.
| Product | Versions |
|---|---|
| Linux |
affected from d24af13e2e2358a602740c7817ea90da43d3e740, before b1ae9f617f8a5c848d9205b8e228c6f0d1af754b affected from d24af13e2e2358a602740c7817ea90da43d3e740, before 85e4ea1049c70fb99de5c6057e835d151fb647da
Other versions: unaffected
|
| Linux |
affected 5.17 unaffected before 5.17 unaffected from 5.18.11 up to and including 5.18.* unaffected 5.19 and later
Other versions: affected
|
Is my server affected?
This CVE is in the Linux kernel. Compare the running kernel with the fixed kernel version of your distribution, and reboot after a kernel update:
uname -r
# Debian, Ubuntu: does the changelog of the running kernel name the CVE?
zgrep -l CVE-2022-49655 /usr/share/doc/linux-image-$(uname -r)/changelog.Debian.gz
# RHEL, Rocky, Alma
rpm -q --changelog kernel | grep CVE-2022-49655
With Trivy, on the host and for a container image. When a package is affected, it prints the installed and the fixed version:
trivy rootfs --scanners vuln / | grep CVE-2022-49655
trivy image --scanners vuln IMAGE | grep CVE-2022-49655
Vulnpocalypse makes this comparison every day for the package lists of your servers and container images, including language packages (npm, PyPI, Go, Maven and others), and sends the command that installs the fix. Start free with one server and one domain or read how to install the collector.
References
Other references
- https://git.kernel.org/stable/c/b1ae9f617f8a5c848d9205b8e228c6f0d1af754b git.kernel.org
- https://git.kernel.org/stable/c/85e4ea1049c70fb99de5c6057e835d151fb647da git.kernel.org
Source: the record CVE-2022-49655 of the CVE List (CVE Program), CVE Terms of Use; EPSS of FIRST. The text of the record is shown as published. Data sources and licences.
Vulnpocalypse