CVE-2025-38306

Source
https://nvd.nist.gov/vuln/detail/CVE-2025-38306
Import Source
https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2025-38306.json
JSON Data
https://api.osv.dev/v1/vulns/CVE-2025-38306
Downstream
Published
2025-07-10T07:42:16Z
Modified
2025-10-22T13:31:33.128144Z
Summary
fs/fhandle.c: fix a race in call of has_locked_children()
Details

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

fs/fhandle.c: fix a race in call of haslockedchildren()

maydecodefh() is calling haslockedchildren() while holding no locks. That's an oopsable race...

The rest of the callers are safe since they are holding namespace_sem and are guaranteed a positive refcount on the mount in question.

Rename the current haslockedchildren() to _haslocked_children(), make it static and switch the fs/namespace.c users to it.

Make haslockedchildren() a wrapper for _haslockedchildren(), calling the latter under readseqlockexcl(&mountlock).

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
620c266f394932e5decc4b34683a75dfc59dc2f4
Fixed
6482c3dccbfb8d20e2856ce67c75856859930b3f
Type
GIT
Repo
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
Events
Introduced
620c266f394932e5decc4b34683a75dfc59dc2f4
Fixed
287c7d34eedd37af1272dfb3b6e8656f4f026424
Type
GIT
Repo
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
Events
Introduced
620c266f394932e5decc4b34683a75dfc59dc2f4
Fixed
1f282cdc1d219c4a557f7009e81bc792820d9d9a

Affected versions

v6.*

v6.10
v6.10-rc2
v6.10-rc3
v6.10-rc4
v6.10-rc5
v6.10-rc6
v6.10-rc7
v6.11
v6.11-rc1
v6.11-rc2
v6.11-rc3
v6.11-rc4
v6.11-rc5
v6.11-rc6
v6.11-rc7
v6.12
v6.12-rc1
v6.12-rc2
v6.12-rc3
v6.12-rc4
v6.12-rc5
v6.12-rc6
v6.12-rc7
v6.12.1
v6.12.10
v6.12.11
v6.12.12
v6.12.13
v6.12.14
v6.12.15
v6.12.16
v6.12.17
v6.12.18
v6.12.19
v6.12.2
v6.12.20
v6.12.21
v6.12.22
v6.12.23
v6.12.24
v6.12.25
v6.12.26
v6.12.27
v6.12.28
v6.12.29
v6.12.3
v6.12.30
v6.12.31
v6.12.32
v6.12.33
v6.12.34
v6.12.35
v6.12.36
v6.12.37
v6.12.38
v6.12.39
v6.12.4
v6.12.40
v6.12.41
v6.12.42
v6.12.43
v6.12.44
v6.12.45
v6.12.5
v6.12.6
v6.12.7
v6.12.8
v6.12.9
v6.13
v6.13-rc1
v6.13-rc2
v6.13-rc3
v6.13-rc4
v6.13-rc5
v6.13-rc6
v6.13-rc7
v6.14
v6.14-rc1
v6.14-rc2
v6.14-rc3
v6.14-rc4
v6.14-rc5
v6.14-rc6
v6.14-rc7
v6.15
v6.15-rc1
v6.15-rc2
v6.15-rc3
v6.15-rc4
v6.15-rc5
v6.15-rc6
v6.15-rc7
v6.15.1
v6.15.2

Linux / Kernel

Package

Name
Kernel

Affected ranges

Type
ECOSYSTEM
Events
Introduced
6.11.0
Fixed
6.12.46
Type
ECOSYSTEM
Events
Introduced
6.13.0
Fixed
6.15.3