Name | CVE-2024-35960 |
Description | In the Linux kernel, the following vulnerability has been resolved: net/mlx5: Properly link new fs rules into the tree Previously, add_rule_fg would only add newly created rules from the handle into the tree when they had a refcount of 1. On the other hand, create_flow_handle tries hard to find and reference already existing identical rules instead of creating new ones. These two behaviors can result in a situation where create_flow_handle 1) creates a new rule and references it, then 2) in a subsequent step during the same handle creation references it again, resulting in a rule with a refcount of 2 that is not linked into the tree, will have a NULL parent and root and will result in a crash when the flow group is deleted because del_sw_hw_rule, invoked on rule deletion, assumes node->parent is != NULL. This happened in the wild, due to another bug related to incorrect handling of duplicate pkt_reformat ids, which lead to the code in create_flow_handle incorrectly referencing a just-added rule in the same flow handle, resulting in the problem described above. Full details are at [1]. This patch changes add_rule_fg to add new rules without parents into the tree, properly initializing them and avoiding the crash. This makes it more consistent with how rules are added to an FTE in create_flow_handle. |
Source | CVE (at NVD; CERT, LWN, oss-sec, fulldisc, Red Hat, Ubuntu, Gentoo, SUSE bugzilla/CVE, GitHub advisories/code/issues, web search, more) |
References | DLA-3840-1, DLA-3842-1, ELA-1116-1 |
The table below lists information on source packages.
Source Package | Release | Version | Status |
---|---|---|---|
linux (PTS) | jessie, jessie (lts) | 3.16.84-1 | vulnerable |
stretch (security) | 4.9.320-2 | vulnerable | |
stretch (lts), stretch | 4.9.320-3 | vulnerable | |
buster (security), buster, buster (lts) | 4.19.316-1 | fixed | |
bullseye | 5.10.223-1 | fixed | |
bullseye (security) | 5.10.226-1 | fixed | |
bookworm | 6.1.106-3 | fixed | |
bookworm (security) | 6.1.112-1 | fixed | |
sid, trixie | 6.11.5-1 | fixed | |
linux-4.19 (PTS) | jessie, jessie (lts) | 4.19.316-1~deb8u1 | fixed |
stretch (security) | 4.19.232-1~deb9u1 | vulnerable | |
stretch (lts), stretch | 4.19.316-1~deb9u1 | fixed | |
linux-5.10 (PTS) | buster, buster (lts) | 5.10.226-1~deb10u1 | fixed |
buster (security) | 5.10.218-1~deb10u1 | fixed |
The information below is based on the following data on fixed versions.
Package | Type | Release | Fixed Version | Urgency | Origin | Debian Bugs |
---|---|---|---|---|---|---|
linux | source | jessie | (unfixed) | end-of-life | ||
linux | source | stretch | (unfixed) | end-of-life | ||
linux | source | buster | 4.19.316-1 | DLA-3840-1 | ||
linux | source | bullseye | 5.10.216-1 | |||
linux | source | bookworm | 6.1.90-1 | |||
linux | source | (unstable) | 6.8.9-1 | |||
linux-4.19 | source | jessie | 4.19.316-1~deb8u1 | ELA-1116-1 | ||
linux-4.19 | source | stretch | 4.19.316-1~deb9u1 | ELA-1116-1 | ||
linux-5.10 | source | buster | 5.10.216-1~deb10u1 | DLA-3842-1 |
https://git.kernel.org/linus/7c6782ad4911cbee874e85630226ed389ff2e453 (6.9-rc4)