CVE-2022-50212
netfilter: nf_tables: do not allow CHAIN_ID to refer to another table
Check your servers for CVE-2022-50212
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-50212 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:
netfilter: nf_tables: do not allow CHAIN_ID to refer to another table
When doing lookups for chains on the same batch by using its ID, a chain from a different table can be used. If a rule is added to a table but refers to a chain in a different table, it will be linked to the chain in table2, but would have expressions referring to objects in table1.
Then, when table1 is removed, the rule will not be removed as its linked to a chain in table2. When expressions in the rule are processed or removed, that will lead to a use-after-free.
When looking for chains by ID, use the table that was used for the lookup by name, and only return chains belonging to that same table.
Severity (CVSS)
CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
- Attack vector
- local: the attacker needs local access, or a user has to open a prepared file
- Attack complexity
- low: an attack works without special conditions
- Privileges required
- low: the attacker needs an ordinary user account
- User interaction
- none: nobody has to click or open anything
- Scope
- unchanged: the damage stays inside the vulnerable component
- Impact
- confidentiality high, integrity high, availability high: what an attacker can read (confidentiality), change (integrity) or stop (availability)
Exploitation
EPSS 0.24%: the probability of exploitation activity in the next 30 days, from the EPSS model of FIRST. The score is higher than 16.7% of all scored CVEs. Scores of 1 Dec 2026.
Affected products
As the CNA lists them.
| Product | Versions |
|---|---|
| Linux |
affected from 837830a4b439bfeb86c70b0115c280377c84714b, before 9e7dcb88ec8e85e4a8ad0ea494ea2f90f32d2583 affected from 837830a4b439bfeb86c70b0115c280377c84714b, before 91501513016903077f91033fa5d2aa26cac399b2 affected from 837830a4b439bfeb86c70b0115c280377c84714b, before 0f49613a213d918af790c1276f79da741968de11 affected from 837830a4b439bfeb86c70b0115c280377c84714b, before 58e863f64ee3d0879297e5e53b646e4b91e59620 affected from 837830a4b439bfeb86c70b0115c280377c84714b, before 95f466d22364a33d183509629d0879885b4f547e
Other versions: unaffected
|
| Linux |
affected 5.9 unaffected before 5.9 unaffected from 5.10.137 up to and including 5.10.* unaffected from 5.15.61 up to and including 5.15.* unaffected from 5.18.18 up to and including 5.18.* unaffected from 5.19.2 up to and including 5.19.* unaffected 6.0 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-50212 /usr/share/doc/linux-image-$(uname -r)/changelog.Debian.gz
# RHEL, Rocky, Alma
rpm -q --changelog kernel | grep CVE-2022-50212
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-50212
trivy image --scanners vuln IMAGE | grep CVE-2022-50212
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/9e7dcb88ec8e85e4a8ad0ea494ea2f90f32d2583 git.kernel.org
- https://git.kernel.org/stable/c/91501513016903077f91033fa5d2aa26cac399b2 git.kernel.org
- https://git.kernel.org/stable/c/0f49613a213d918af790c1276f79da741968de11 git.kernel.org
- https://git.kernel.org/stable/c/58e863f64ee3d0879297e5e53b646e4b91e59620 git.kernel.org
- https://git.kernel.org/stable/c/95f466d22364a33d183509629d0879885b4f547e git.kernel.org
Source: the record CVE-2022-50212 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