CVE-2024-35955 kprobes: Fix possible use-after-free issue on kprobe registration
- Published
- Updated
- Exploit status
- No public exploit known
- CISA SSVC
- No known exploitation · automatable: no · technical impact: total
- Technology
- Linux KernelUbuntuDebian
Description
In the Linux kernel, the following vulnerability has been resolved:
kprobes: Fix possible use-after-free issue on kprobe registration
When unloading a module, its state is changing MODULE_STATE_LIVE ->
MODULE_STATE_GOING -> MODULE_STATE_UNFORMED. Each change will take
a time. is_module_text_address() and __module_text_address()
works with MODULE_STATE_LIVE and MODULE_STATE_GOING.
If we use is_module_text_address() and __module_text_address()
separately, there is a chance that the first one is succeeded but the
next one is failed because module->state becomes MODULE_STATE_UNFORMED
between those operations.
In check_kprobe_address_safe(), if the second __module_text_address()
is failed, that is ignored because it expected a kernel_text address.
But it may have failed simply because module->state has been changed
to MODULE_STATE_UNFORMED. In this case, arm_kprobe() will try to modify
non-exist module text address (use-after-free).
To fix this problem, we should not use separated is_module_text_address()
and __module_text_address(), but use only __module_text_address()
once and do try_module_get(module) which is only available with
MODULE_STATE_LIVE.
Upgrade path
13 packages: 12 fixed.
| Package | Affected | Fixed in | Status |
|---|---|---|---|
| debian/linux(Debian 12) | < 6.1.90-1; = 6.1.27-1; = 6.1.37-1; = 6.1.38-1 +18 more | 6.1.90-1 | Fixed |
| debian/linux(Debian 13) | < 6.8.9-1 | 6.8.9-1 | Fixed |
| debian/linux(Debian 14) | < 6.8.9-1 | 6.8.9-1 | Fixed |
| Linux kernel | < 4.19.313; < 5.4.275; < 5.10.216; < 5.15.157 +37 more | 2df2dd27066c, 2df2dd27066cdba8041e46a64362325626bdfb2e, 4.15, 4.19.313, 5.4.275, 5.10.216, 5.15.157, 5.19, 5.20, 6.1.87, 6.6.28, 6.8.7, 6.9, 36b57c7d2f8b, 36b57c7d2f8b7de224980f1a284432846ad71ca0, 93eb31e7c339, 93eb31e7c3399e326259f2caa17be1e821f5a412, 325f3fb551f8, 325f3fb551f8cd672dbbfc4cf58b14f9ee3fc9e8, 5062d1f4f07facbdade0f402d9a04a788f52e26d, 62029bc9ff2c, 62029bc9ff2c17a4e3a2478d83418ec575413808, b5808d400934, b5808d40093403334d939e2c3c417144d12a6f33, d15023fb4073, d15023fb407337028a654237d8968fefdcf87c2f | Fixed |
| Siemens RUGGEDCOM RST2428P | < V3.1 | V3.1 | Fixed |
| Siemens SCALANCE XCM-/XRM-/XCH-/XRH-300 family | < V3.1 | V3.1 | Fixed |
| Siemens SIMATIC S7-1500 TM MFP - GNU/Linux subsystem | < V1.1.1 | V1.1.1 | Fixed |
| ubuntu/linux(Ubuntu 22.04) | < 5.15.0-116.126 | 5.15.0-116.126 | Fixed |
| ubuntu/linux(Ubuntu 24.04) | < 6.8.0-38.38 | 6.8.0-38.38 | Fixed |
| ubuntu/linux-kvm(Ubuntu 22.04) | < 5.15.0-1062.67 | 5.15.0-1062.67 | Fixed |
| ubuntu/linux-raspi(Ubuntu 22.04) | < 5.15.0-1058.61 | 5.15.0-1058.61 | Fixed |
| ubuntu/linux-raspi(Ubuntu 24.04) | < 6.8.0-1007.7 | 6.8.0-1007.7 | Fixed |
| debian linux | = 10.0 | No fix listed | Versions listed |
Affected products
| Product | Affected versions | Fixed in |
|---|---|---|
| debian/linux(Debian:12) | < 6.1.90-1 | 6.1.90-1 |
| debian/linux(Debian:12) | = 6.1.27-1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.37-1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.38-1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.38-2 | No fix listed |
| debian/linux(Debian:12) | = 6.1.38-2~bpo11+1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.38-3 | No fix listed |
| debian/linux(Debian:12) | = 6.1.38-4 | No fix listed |
| debian/linux(Debian:12) | = 6.1.38-4~bpo11+1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.52-1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.55-1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.55-1~bpo11+1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.64-1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.66-1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.67-1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.69-1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.69-1~bpo11+1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.76-1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.76-1~bpo11+1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.82-1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.85-1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.90-1~bpo11+1 | No fix listed |
| debian/linux(Debian:13) | < 6.8.9-1 | 6.8.9-1 |
| debian/linux(Debian:14) | < 6.8.9-1 | 6.8.9-1 |
| ubuntu/linux(Ubuntu:22.04) | < 5.15.0-116.126 | 5.15.0-116.126 |
Show 49 more
| Product | Affected versions | Fixed in |
|---|---|---|
| ubuntu/linux-kvm(Ubuntu:22.04) | < 5.15.0-1062.67 | 5.15.0-1062.67 |
| ubuntu/linux-raspi(Ubuntu:22.04) | < 5.15.0-1058.61 | 5.15.0-1058.61 |
| Linux kernel | >= 1c836bad43f3e2ff71cc397a6e6ccb4e7bd116f8, < b5808d40093403334d939e2c3c417144d12a6f33 | b5808d40093403334d939e2c3c417144d12a6f33 |
| Linux kernel | >= 6a119c1a584aa7a2c6216458f1f272bf1bc93a93, < 93eb31e7c3399e326259f2caa17be1e821f5a412 | 93eb31e7c3399e326259f2caa17be1e821f5a412 |
| Linux kernel | >= 2a49b025c36ae749cee7ccc4b7e456e02539cdc3, < 5062d1f4f07facbdade0f402d9a04a788f52e26d | 5062d1f4f07facbdade0f402d9a04a788f52e26d |
| Linux kernel | >= a1edb85e60fdab1e14db63ae8af8db3f0d798fb6, < 2df2dd27066cdba8041e46a64362325626bdfb2e | 2df2dd27066cdba8041e46a64362325626bdfb2e |
| Linux kernel | >= 28f6c37a2910f565b4f5960df52b2eccae28c891, < 62029bc9ff2c17a4e3a2478d83418ec575413808 | 62029bc9ff2c17a4e3a2478d83418ec575413808 |
| Linux kernel | >= 28f6c37a2910f565b4f5960df52b2eccae28c891, < d15023fb407337028a654237d8968fefdcf87c2f | d15023fb407337028a654237d8968fefdcf87c2f |
| Linux kernel | >= 28f6c37a2910f565b4f5960df52b2eccae28c891, < 36b57c7d2f8b7de224980f1a284432846ad71ca0 | 36b57c7d2f8b7de224980f1a284432846ad71ca0 |
| Linux kernel | >= 28f6c37a2910f565b4f5960df52b2eccae28c891, < 325f3fb551f8cd672dbbfc4cf58b14f9ee3fc9e8 | 325f3fb551f8cd672dbbfc4cf58b14f9ee3fc9e8 |
| Linux kernel | = 4262b6eb057d86c7829168c541654fe0d48fdac8 | No fix listed |
| Linux kernel | = 97e813e6a143edf4208e15c72199c495ed80cea5 | No fix listed |
| Linux kernel | = 16a544f1e013ba0660612f3fe35393b143b19a84 | No fix listed |
| Linux kernel | >= 4.19.256, < 4.19.313 | 4.19.313 |
| Linux kernel | >= 5.4.211, < 5.4.275 | 5.4.275 |
| Linux kernel | >= 5.10.137, < 5.10.216 | 5.10.216 |
| Linux kernel | >= 5.15.61, < 5.15.157 | 5.15.157 |
| Linux kernel | >= 4.14.291, < 4.15 | 4.15 |
| Linux kernel | >= 5.18.18, < 5.19 | 5.19 |
| Linux kernel | >= 5.19.2, < 5.20 | 5.20 |
| Linux kernel | = 6.0 | No fix listed |
| Linux kernel | < 4.19.313 | 4.19.313 |
| Linux kernel | < 5.4.275 | 5.4.275 |
| Linux kernel | < 5.10.216 | 5.10.216 |
| Linux kernel | < 5.15.157 | 5.15.157 |
| Linux kernel | < 6.1.87 | 6.1.87 |
| Linux kernel | < 6.6.28 | 6.6.28 |
| Linux kernel | < 6.8.7 | 6.8.7 |
| Linux kernel | < 6.9 | 6.9 |
| Linux kernel | >= 1c836bad43f3, < b5808d400934 | b5808d400934 |
| Linux kernel | >= 6a119c1a584a, < 93eb31e7c339 | 93eb31e7c339 |
| Linux kernel | >= 2a49b025c36a, < 93eb31e7c339 | 93eb31e7c339 |
| Linux kernel | >= a1edb85e60fd, < 2df2dd27066c | 2df2dd27066c |
| Linux kernel | >= 28f6c37a2910, < 62029bc9ff2c | 62029bc9ff2c |
| Linux kernel | >= 28f6c37a2910, < d15023fb4073 | d15023fb4073 |
| Linux kernel | >= 28f6c37a2910, < 36b57c7d2f8b | 36b57c7d2f8b |
| Linux kernel | >= 28f6c37a2910, < 325f3fb551f8 | 325f3fb551f8 |
| Siemens RUGGEDCOM RST2428P | < V3.1 | V3.1 |
| Siemens SCALANCE XCM-/XRM-/XCH-/XRH-300 family | < V3.1 | V3.1 |
| Siemens SIMATIC S7-1500 TM MFP - GNU/Linux subsystem | < V1.1.1 | V1.1.1 |
| ubuntu/linux(Ubuntu:24.04) | < 6.8.0-38.38 | 6.8.0-38.38 |
| ubuntu/linux-raspi(Ubuntu:24.04) | < 6.8.0-1007.7 | 6.8.0-1007.7 |
| Linux kernel | >= 5.19.2, < 6.1.87 | 6.1.87 |
| Linux kernel | >= 6.2, < 6.6.28 | 6.6.28 |
| Linux kernel | >= 6.7, < 6.8.7 | 6.8.7 |
| Linux kernel | = 6.9-rc1 | No fix listed |
| Linux kernel | = 6.9-rc2 | No fix listed |
| Linux kernel | = 6.9-rc3 | No fix listed |
| debian linux | = 10.0 | No fix listed |
References
- Debian Security Tracker CVE-2024-35955 vendor-advisory
- Ubuntu CVE tracker vendor-advisory
- USN-6893-1 vendor-advisory
- USN-6896-1 vendor-advisory
- USN-6898-1 vendor-advisory
- USN-6893-2 vendor-advisory
- USN-6896-2 vendor-advisory
- USN-6898-2 vendor-advisory
- USN-6896-3 vendor-advisory
- USN-6898-3 vendor-advisory
- USN-6896-4 vendor-advisory
- USN-6896-5 vendor-advisory
- USN-6893-3 vendor-advisory
- USN-6898-4 vendor-advisory
- USN-6917-1 vendor-advisory
- USN-6919-1 vendor-advisory
- USN-6918-1 vendor-advisory
- USN-6927-1 vendor-advisory
- USN-6972-1 vendor-advisory
- USN-6972-2 vendor-advisory
- USN-6972-3 vendor-advisory
- USN-6972-4 vendor-advisory
- USN-7019-1 vendor-advisory
- www.cve.org
- git.kernel.org patch
- git.kernel.org patch
- git.kernel.org patch
- git.kernel.org patch
- git.kernel.org patch
- git.kernel.org patch
- git.kernel.org patch
- git.kernel.org patch
- lists.debian.org mailing-list third-party-advisory
- lists.debian.org mailing-list third-party-advisory
- cert-portal.siemens.com
- cert-portal.siemens.com
- ENISA EUVD EUVD-2024-35673 third-party-advisory