Linux Kernel up to 6.1.119/6.6.65/6.12.4 LoongArch spinlock_rt.c setup_tlb_handler stack-based overflow

| CVSS Meta Temp Score | Current Exploit Price (≈) | CTI Interest Score |
|---|---|---|
| 6.6 | $0-$5k | 0.00 |
Summary
A vulnerability was found in Linux Kernel up to 6.1.119/6.6.65/6.12.4. It has been declared as critical. This issue affects the function setup_tlb_handler of the file kernel/locking/spinlock_rt.c of the component LoongArch. Such manipulation leads to stack-based overflow.
This vulnerability is listed as CVE-2024-56585. There is no available exploit.
It is recommended to upgrade the affected component.
Details
A vulnerability, which was classified as critical, has been found in Linux Kernel up to 6.1.119/6.6.65/6.12.4. Affected by this issue is the function setup_tlb_handler of the file kernel/locking/spinlock_rt.c of the component LoongArch. The manipulation with an unknown input leads to a stack-based overflow vulnerability. Using CWE to declare the problem leads to CWE-121. A stack-based buffer overflow condition is a condition where the buffer being overwritten is allocated on the stack (i.e., is a local variable or, rarely, a parameter to a function). Impacted is confidentiality, integrity, and availability. CVE summarizes:
In the Linux kernel, the following vulnerability has been resolved: LoongArch: Fix sleeping in atomic context for PREEMPT_RT Commit bab1c299f3945ffe79 ("LoongArch: Fix sleeping in atomic context in setup_tlb_handler()") changes the gfp flag from GFP_KERNEL to GFP_ATOMIC for alloc_pages_node(). However, for PREEMPT_RT kernels we can still get a "sleeping in atomic context" error: [ 0.372259] BUG: sleeping function called from invalid context at kernel/locking/spinlock_rt.c:48 [ 0.372266] in_atomic(): 1, irqs_disabled(): 1, non_block: 0, pid: 0, name: swapper/1 [ 0.372268] preempt_count: 1, expected: 0 [ 0.372270] RCU nest depth: 1, expected: 1 [ 0.372272] 3 locks held by swapper/1/0: [ 0.372274] #0: 900000000c9f5e60 (&pcp->lock){+.+.}-{3:3}, at: get_page_from_freelist+0x524/0x1c60 [ 0.372294] #1: 90000000087013b8 (rcu_read_lock){....}-{1:3}, at: rt_spin_trylock+0x50/0x140 [ 0.372305] #2: 900000047fffd388 (&zone->lock){+.+.}-{3:3}, at: __rmqueue_pcplist+0x30c/0xea0 [ 0.372314] irq event stamp: 0 [ 0.372316] hardirqs last enabled at (0): [] 0x0 [ 0.372322] hardirqs last disabled at (0): [] copy_process+0x9c0/0x26e0 [ 0.372329] softirqs last enabled at (0): [] copy_process+0x9c0/0x26e0 [ 0.372335] softirqs last disabled at (0): [] 0x0 [ 0.372341] CPU: 1 UID: 0 PID: 0 Comm: swapper/1 Not tainted 6.12.0-rc7+ #1891 [ 0.372346] Hardware name: Loongson Loongson-3A5000-7A1000-1w-CRB/Loongson-LS3A5000-7A1000-1w-CRB, BIOS vUDK2018-LoongArch-V2.0.0-prebeta9 10/21/2022 [ 0.372349] Stack : 0000000000000089 9000000005a0db9c 90000000071519c8 9000000100388000 [ 0.372486] 900000010038b890 0000000000000000 900000010038b898 9000000007e53788 [ 0.372492] 900000000815bcc8 900000000815bcc0 900000010038b700 0000000000000001 [ 0.372498] 0000000000000001 4b031894b9d6b725 00000000055ec000 9000000100338fc0 [ 0.372503] 00000000000000c4 0000000000000001 000000000000002d 0000000000000003 [ 0.372509] 0000000000000030 0000000000000003 00000000055ec000 0000000000000003 [ 0.372515] 900000000806d000 9000000007e53788 00000000000000b0 0000000000000004 [ 0.372521] 0000000000000000 0000000000000000 900000000c9f5f10 0000000000000000 [ 0.372526] 90000000076f12d8 9000000007e53788 9000000005924778 0000000000000000 [ 0.372532] 00000000000000b0 0000000000000004 0000000000000000 0000000000070000 [ 0.372537] ... [ 0.372540] Call Trace: [ 0.372542] [] show_stack+0x38/0x180 [ 0.372548] [] dump_stack_lvl+0x94/0xe4 [ 0.372555] [] __might_resched+0x1a0/0x260 [ 0.372561] [] rt_spin_lock+0x4c/0x140 [ 0.372565] [] __rmqueue_pcplist+0x308/0xea0 [ 0.372570] [] get_page_from_freelist+0x564/0x1c60 [ 0.372575] [] __alloc_pages_noprof+0x218/0x1820 [ 0.372580] [] tlb_init+0x1ac/0x298 [ 0.372585] [] per_cpu_trap_init+0x114/0x140 [ 0.372589] [] cpu_probe+0x4e4/0xa60 [ 0.372592] [] start_secondary+0x34/0xc0 [ 0.372599] [] smpboot_entry+0x64/0x6c This is because in PREEMPT_RT kernels normal spinlocks are replaced by rt spinlocks and rt_spin_lock() will cause sleeping. Fix it by disabling NUMA optimization completely for PREEMPT_RT kernels.
The advisory is shared for download at git.kernel.org. This vulnerability is handled as CVE-2024-56585 since 12/27/2024. The exploitation is known to be easy. There are known technical details, but no exploit is available. The current price for an exploit might be approx. USD $0-$5k (estimation calculated on 01/05/2026).
The vulnerability scanner Nessus provides a plugin with the ID 216985 (Debian dla-4076 : linux-config-6.1 - security update), which helps to determine the existence of the flaw in a target environment.
Upgrading to version 6.1.120, 6.6.66 or 6.12.5 eliminates this vulnerability. Applying the patch 08715b741f9b2a925d6485491e4907f3b29bac70/c5f89458a2ea0800866b9fc690d3fa8367dc8f8d/6575e0867bd478a5d7ef1783ca1e73160807d238/88fd2b70120d52c1010257d36776876941375490 is able to eliminate this problem. The bugfix is ready for download at git.kernel.org. The best possible mitigation is suggested to be upgrading to the latest version.
The vulnerability is also documented in the databases at Tenable (216985) and CERT Bund (WID-SEC-2024-3762). VulDB is the best source for vulnerability data and more expert information about this specific topic.
Affected
- Debian Linux
- Amazon Linux 2
- Red Hat Enterprise Linux
- Ubuntu Linux
- SUSE Linux
- Oracle Linux
- RESF Rocky Linux
- Dell NetWorker
- Dell Avamar
- Red Hat OpenShift
- IBM QRadar SIEM
- Dell PowerProtect Data Domain
- Open Source Linux Kernel
- IBM DataPower Gateway
- Dell Secure Connect Gateway
Product
Type
Vendor
Name
Version
- 6.1.119
- 6.6.0
- 6.6.1
- 6.6.2
- 6.6.3
- 6.6.4
- 6.6.5
- 6.6.6
- 6.6.7
- 6.6.8
- 6.6.9
- 6.6.10
- 6.6.11
- 6.6.12
- 6.6.13
- 6.6.14
- 6.6.15
- 6.6.16
- 6.6.17
- 6.6.18
- 6.6.19
- 6.6.20
- 6.6.21
- 6.6.22
- 6.6.23
- 6.6.24
- 6.6.25
- 6.6.26
- 6.6.27
- 6.6.28
- 6.6.29
- 6.6.30
- 6.6.31
- 6.6.32
- 6.6.33
- 6.6.34
- 6.6.35
- 6.6.36
- 6.6.37
- 6.6.38
- 6.6.39
- 6.6.40
- 6.6.41
- 6.6.42
- 6.6.43
- 6.6.44
- 6.6.45
- 6.6.46
- 6.6.47
- 6.6.48
- 6.6.49
- 6.6.50
- 6.6.51
- 6.6.52
- 6.6.53
- 6.6.54
- 6.6.55
- 6.6.56
- 6.6.57
- 6.6.58
- 6.6.59
- 6.6.60
- 6.6.61
- 6.6.62
- 6.6.63
- 6.6.64
- 6.6.65
- 6.12.0
- 6.12.1
- 6.12.2
- 6.12.3
- 6.12.4
License
Website
- Vendor: https://www.kernel.org/
CPE 2.3
CPE 2.2
CVSSv4
VulDB Vector: 🔍VulDB Reliability: 🔍
CVSSv3
VulDB Meta Base Score: 6.8VulDB Meta Temp Score: 6.6
VulDB Base Score: 8.0
VulDB Temp Score: 7.6
VulDB Vector: 🔍
VulDB Reliability: 🔍
NVD Base Score: 5.5
NVD Vector: 🔍
CVSSv2
| AV | AC | Au | C | I | A |
|---|---|---|---|---|---|
| 💳 | 💳 | 💳 | 💳 | 💳 | 💳 |
| 💳 | 💳 | 💳 | 💳 | 💳 | 💳 |
| 💳 | 💳 | 💳 | 💳 | 💳 | 💳 |
| Vector | Complexity | Authentication | Confidentiality | Integrity | Availability |
|---|---|---|---|---|---|
| Unlock | Unlock | Unlock | Unlock | Unlock | Unlock |
| Unlock | Unlock | Unlock | Unlock | Unlock | Unlock |
| Unlock | Unlock | Unlock | Unlock | Unlock | Unlock |
VulDB Base Score: 🔍
VulDB Temp Score: 🔍
VulDB Reliability: 🔍
Exploiting
Class: Stack-based overflowCWE: CWE-121 / CWE-119
CAPEC: 🔍
ATT&CK: 🔍
Physical: Partially
Local: Yes
Remote: Partially
Availability: 🔍
Status: Not defined
EPSS Score: 🔍
EPSS Percentile: 🔍
Price Prediction: 🔍
Current Price Estimation: 🔍
| 0-Day | Unlock | Unlock | Unlock | Unlock |
|---|---|---|---|---|
| Today | Unlock | Unlock | Unlock | Unlock |
Nessus ID: 216985
Nessus Name: Debian dla-4076 : linux-config-6.1 - security update
Threat Intelligence
Interest: 🔍Active Actors: 🔍
Active APT Groups: 🔍
Countermeasures
Recommended: UpgradeStatus: 🔍
0-Day Time: 🔍
Upgrade: Kernel 6.1.120/6.6.66/6.12.5
Patch: 08715b741f9b2a925d6485491e4907f3b29bac70/c5f89458a2ea0800866b9fc690d3fa8367dc8f8d/6575e0867bd478a5d7ef1783ca1e73160807d238/88fd2b70120d52c1010257d36776876941375490
Timeline
12/27/2024 🔍12/27/2024 🔍
12/27/2024 🔍
01/05/2026 🔍
Sources
Vendor: kernel.orgAdvisory: git.kernel.org
Status: Confirmed
CVE: CVE-2024-56585 (🔍)
GCVE (CVE): GCVE-0-2024-56585
GCVE (VulDB): GCVE-100-289568
CERT Bund: WID-SEC-2024-3762 - Linux Kernel: Mehrere Schwachstellen ermöglichen Denial of Service
Entry
Created: 12/27/2024 18:36Updated: 01/05/2026 07:25
Changes: 12/27/2024 18:36 (60), 03/02/2025 08:57 (2), 07/25/2025 02:19 (7), 09/23/2025 19:55 (12), 01/05/2026 07:25 (1)
Complete: 🔍
Cache ID: 216::103
VulDB is the best source for vulnerability data and more expert information about this specific topic.
No comments yet. Languages: en.
Please log in to comment.