| From bippy-1.2.0 Mon Sep 17 00:00:00 2001 |
| From: Greg Kroah-Hartman <gregkh@kernel.org> |
| To: <linux-cve-announce@vger.kernel.org> |
| Reply-to: <cve@kernel.org>, <linux-kernel@vger.kernel.org> |
| Subject: CVE-2025-37997: netfilter: ipset: fix region locking in hash types |
| |
| Description |
| =========== |
| |
| In the Linux kernel, the following vulnerability has been resolved: |
| |
| netfilter: ipset: fix region locking in hash types |
| |
| Region locking introduced in v5.6-rc4 contained three macros to handle |
| the region locks: ahash_bucket_start(), ahash_bucket_end() which gave |
| back the start and end hash bucket values belonging to a given region |
| lock and ahash_region() which should give back the region lock belonging |
| to a given hash bucket. The latter was incorrect which can lead to a |
| race condition between the garbage collector and adding new elements |
| when a hash type of set is defined with timeouts. |
| |
| The Linux kernel CVE team has assigned CVE-2025-37997 to this issue. |
| |
| |
| Affected and fixed versions |
| =========================== |
| |
| Issue introduced in 5.4.24 with commit 5dd9488ae41070b69d2f4acb580f77db5705f9ca and fixed in 5.4.294 with commit 00cfc5fad1491796942a948808afb968a0a3f35b |
| Issue introduced in 5.6 with commit f66ee0410b1c3481ee75e5db9b34547b4d582465 and fixed in 5.10.238 with commit 226ce0ec38316d9e3739e73a64b6b8304646c658 |
| Issue introduced in 5.6 with commit f66ee0410b1c3481ee75e5db9b34547b4d582465 and fixed in 5.15.183 with commit 82c1eb32693bc48251d92532975e19160987e5b9 |
| Issue introduced in 5.6 with commit f66ee0410b1c3481ee75e5db9b34547b4d582465 and fixed in 6.1.139 with commit aa77294b0f73bb8265987591460cd25b8722c3df |
| Issue introduced in 5.6 with commit f66ee0410b1c3481ee75e5db9b34547b4d582465 and fixed in 6.6.91 with commit a3dfec485401943e315c394c29afe2db8f9481d6 |
| Issue introduced in 5.6 with commit f66ee0410b1c3481ee75e5db9b34547b4d582465 and fixed in 6.12.29 with commit e2ab67672b2288521a6146034a971f9a82ffc5c5 |
| Issue introduced in 5.6 with commit f66ee0410b1c3481ee75e5db9b34547b4d582465 and fixed in 6.14.7 with commit 6e002ecc1c8cfdfc866b9104ab7888da54613e59 |
| Issue introduced in 5.6 with commit f66ee0410b1c3481ee75e5db9b34547b4d582465 and fixed in 6.15 with commit 8478a729c0462273188263136880480729e9efca |
| Issue introduced in 5.5.8 with commit a469bab3386aebff33c59506f3a95e35b91118fd |
| |
| Please see https://www.kernel.org for a full list of currently supported |
| kernel versions by the kernel community. |
| |
| Unaffected versions might change over time as fixes are backported to |
| older supported kernel versions. The official CVE entry at |
| https://cve.org/CVERecord/?id=CVE-2025-37997 |
| will be updated if fixes are backported, please check that for the most |
| up to date information about this issue. |
| |
| |
| Affected files |
| ============== |
| |
| The file(s) affected by this issue are: |
| net/netfilter/ipset/ip_set_hash_gen.h |
| |
| |
| Mitigation |
| ========== |
| |
| The Linux kernel CVE team recommends that you update to the latest |
| stable kernel version for this, and many other bugfixes. Individual |
| changes are never tested alone, but rather are part of a larger kernel |
| release. Cherry-picking individual commits is not recommended or |
| supported by the Linux kernel community at all. If however, updating to |
| the latest release is impossible, the individual changes to resolve this |
| issue can be found at these commits: |
| https://git.kernel.org/stable/c/00cfc5fad1491796942a948808afb968a0a3f35b |
| https://git.kernel.org/stable/c/226ce0ec38316d9e3739e73a64b6b8304646c658 |
| https://git.kernel.org/stable/c/82c1eb32693bc48251d92532975e19160987e5b9 |
| https://git.kernel.org/stable/c/aa77294b0f73bb8265987591460cd25b8722c3df |
| https://git.kernel.org/stable/c/a3dfec485401943e315c394c29afe2db8f9481d6 |
| https://git.kernel.org/stable/c/e2ab67672b2288521a6146034a971f9a82ffc5c5 |
| https://git.kernel.org/stable/c/6e002ecc1c8cfdfc866b9104ab7888da54613e59 |
| https://git.kernel.org/stable/c/8478a729c0462273188263136880480729e9efca |