CVE-2025-38100

Source
https://nvd.nist.gov/vuln/detail/CVE-2025-38100
Import Source
https://storage.googleapis.com/osv-test-cve-osv-conversion/osv-output/CVE-2025-38100.json
JSON Data
https://api.test.osv.dev/v1/vulns/CVE-2025-38100
Downstream
Related
Published
2025-07-03T08:35:09.487Z
Modified
2025-11-28T02:35:37.706775Z
Summary
x86/iopl: Cure TIF_IO_BITMAP inconsistencies
Details

In the Linux kernel, the following vulnerability has been resolved:

x86/iopl: Cure TIFIOBITMAP inconsistencies

iobitmapexit() is invoked from exitthread() when a task exists or when a fork fails. In the latter case the exitthread() cleans up resources which were allocated during fork().

iobitmapexit() invokes taskupdateiobitmap(), which in turn ends up in tssupdateiobitmap(). tssupdateiobitmap() operates on the current task. If current has TIFIOBITMAP set, but no bitmap installed, tssupdateiobitmap() crashes with a NULL pointer dereference.

There are two issues, which lead to that problem:

1) iobitmapexit() should not invoke taskupdateio_bitmap() when the task, which is cleaned up, is not the current task. That's a clear indicator for a cleanup after a failed fork().

2) A task should not have TIFIOBITMAP set and neither a bitmap installed nor IOPL emulation level 3 activated.

 This happens when a kernel thread is created in the context of
 a user space thread, which has TIF_IO_BITMAP set as the thread
 flags are copied and the IO bitmap pointer is cleared.

 Other than in the failed fork() case this has no impact because
 kernel threads including IO workers never return to user space and
 therefore never invoke tss_update_io_bitmap().

Cure this by adding the missing cleanups and checks:

1) Prevent iobitmapexit() to invoke taskupdateio_bitmap() if the to be cleaned up task is not the current task.

2) Clear TIFIOBITMAP in copythread() unconditionally. For user space forks it is set later, when the IO bitmap is inherited in iobitmap_share().

For paranoia sake, add a warning into tssupdateio_bitmap() to catch the case, when that code is invoked with inconsistent state.

Database specific
{
    "cna_assigner": "Linux",
    "osv_generated_from": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2025/38xxx/CVE-2025-38100.json"
}
References

Affected packages

Git / git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git

Affected ranges

Type
GIT
Repo
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
Events
Introduced
ea5f1cd7ab494f65f50f338299eabb40ad6a1767
Fixed
d64b7b05a827f98d068f412969eef65489b0cf03
Fixed
2dace5e016c991424a3dc6e83b1ae5dca8992d08
Fixed
aa5ce1485562f20235b4c759eee5ab0c41d2c220
Fixed
2cfcbe1554c119402e7382de974c26b0549899fe
Fixed
b3b3b6366dc8eb5b22edba9adc4bff3cdacfd64c
Fixed
73cfcc8445585b8af7e18be3c9246b851fdf336c
Fixed
8b68e978718f14fdcb080c2a7791c52a0d09bc6d

Linux / Kernel

Package

Name
Kernel

Affected ranges

Type
ECOSYSTEM
Events
Introduced
5.5.0
Fixed
5.10.239
Type
ECOSYSTEM
Events
Introduced
5.11.0
Fixed
5.15.186
Type
ECOSYSTEM
Events
Introduced
5.16.0
Fixed
6.1.142
Type
ECOSYSTEM
Events
Introduced
6.2.0
Fixed
6.6.94
Type
ECOSYSTEM
Events
Introduced
6.7.0
Fixed
6.12.34
Type
ECOSYSTEM
Events
Introduced
6.13.0
Fixed
6.15.3