[<prev] [next>] [day] [month] [year] [list]
Message-ID: <2025121635-CVE-2025-40348-4387@gregkh>
Date: Tue, 16 Dec 2025 14:30:35 +0100
From: Greg Kroah-Hartman <gregkh@...uxfoundation.org>
To: linux-cve-announce@...r.kernel.org
Cc: Greg Kroah-Hartman <gregkh@...nel.org>
Subject: CVE-2025-40348: slab: Avoid race on slab->obj_exts in alloc_slab_obj_exts
From: Greg Kroah-Hartman <gregkh@...nel.org>
Description
===========
In the Linux kernel, the following vulnerability has been resolved:
slab: Avoid race on slab->obj_exts in alloc_slab_obj_exts
If two competing threads enter alloc_slab_obj_exts() and one of them
fails to allocate the object extension vector, it might override the
valid slab->obj_exts allocated by the other thread with
OBJEXTS_ALLOC_FAIL. This will cause the thread that lost this race and
expects a valid pointer to dereference a NULL pointer later on.
Update slab->obj_exts atomically using cmpxchg() to avoid
slab->obj_exts overrides by racing threads.
Thanks for Vlastimil and Suren's help with debugging.
The Linux kernel CVE team has assigned CVE-2025-40348 to this issue.
Affected and fixed versions
===========================
Issue introduced in 6.12.54 with commit 715b6a5b41dae39baeaa40d3386b548bb278b9c2 and fixed in 6.12.56 with commit c7af5300d78460fc5037ddc77113ba3dbfe77dc0
Issue introduced in 6.17.4 with commit 07e38a54cabd9b4de7ceb7f075f29ffa463e458a and fixed in 6.17.6 with commit 7c34feda6a9a203c9744281f1b6671b7dad2012d
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-40348
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:
mm/slub.c
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/c7af5300d78460fc5037ddc77113ba3dbfe77dc0
https://git.kernel.org/stable/c/7c34feda6a9a203c9744281f1b6671b7dad2012d
https://git.kernel.org/stable/c/6ed8bfd24ce1cb31742b09a3eb557cd008533eec
Powered by blists - more mailing lists