Skip to main content

CVE-2023-53057: Vulnerability in Linux Linux

High
VulnerabilityCVE-2023-53057cvecve-2023-53057
Published: Fri May 02 2025 (05/02/2025, 15:55:12 UTC)
Source: CVE
Vendor/Project: Linux
Product: Linux

Description

In the Linux kernel, the following vulnerability has been resolved: Bluetooth: HCI: Fix global-out-of-bounds To loop a variable-length array, hci_init_stage_sync(stage) considers that stage[i] is valid as long as stage[i-1].func is valid. Thus, the last element of stage[].func should be intentionally invalid as hci_init0[], le_init2[], and others did. However, amp_init1[] and amp_init2[] have no invalid element, letting hci_init_stage_sync() keep accessing amp_init1[] over its valid range. This patch fixes this by adding {} in the last of amp_init1[] and amp_init2[]. ================================================================== BUG: KASAN: global-out-of-bounds in hci_dev_open_sync ( /v6.2-bzimage/net/bluetooth/hci_sync.c:3154 /v6.2-bzimage/net/bluetooth/hci_sync.c:3343 /v6.2-bzimage/net/bluetooth/hci_sync.c:4418 /v6.2-bzimage/net/bluetooth/hci_sync.c:4609 /v6.2-bzimage/net/bluetooth/hci_sync.c:4689) Read of size 8 at addr ffffffffaed1ab70 by task kworker/u5:0/1032 CPU: 0 PID: 1032 Comm: kworker/u5:0 Not tainted 6.2.0 #3 Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS 1.15.0-1 04 Workqueue: hci1 hci_power_on Call Trace: <TASK> dump_stack_lvl (/v6.2-bzimage/lib/dump_stack.c:107 (discriminator 1)) print_report (/v6.2-bzimage/mm/kasan/report.c:307 /v6.2-bzimage/mm/kasan/report.c:417) ? hci_dev_open_sync (/v6.2-bzimage/net/bluetooth/hci_sync.c:3154 /v6.2-bzimage/net/bluetooth/hci_sync.c:3343 /v6.2-bzimage/net/bluetooth/hci_sync.c:4418 /v6.2-bzimage/net/bluetooth/hci_sync.c:4609 /v6.2-bzimage/net/bluetooth/hci_sync.c:4689) kasan_report (/v6.2-bzimage/mm/kasan/report.c:184 /v6.2-bzimage/mm/kasan/report.c:519) ? hci_dev_open_sync (/v6.2-bzimage/net/bluetooth/hci_sync.c:3154 /v6.2-bzimage/net/bluetooth/hci_sync.c:3343 /v6.2-bzimage/net/bluetooth/hci_sync.c:4418 /v6.2-bzimage/net/bluetooth/hci_sync.c:4609 /v6.2-bzimage/net/bluetooth/hci_sync.c:4689) hci_dev_open_sync (/v6.2-bzimage/net/bluetooth/hci_sync.c:3154 /v6.2-bzimage/net/bluetooth/hci_sync.c:3343 /v6.2-bzimage/net/bluetooth/hci_sync.c:4418 /v6.2-bzimage/net/bluetooth/hci_sync.c:4609 /v6.2-bzimage/net/bluetooth/hci_sync.c:4689) ? __pfx_hci_dev_open_sync (/v6.2-bzimage/net/bluetooth/hci_sync.c:4635) ? mutex_lock (/v6.2-bzimage/./arch/x86/include/asm/atomic64_64.h:190 /v6.2-bzimage/./include/linux/atomic/atomic-long.h:443 /v6.2-bzimage/./include/linux/atomic/atomic-instrumented.h:1781 /v6.2-bzimage/kernel/locking/mutex.c:171 /v6.2-bzimage/kernel/locking/mutex.c:285) ? __pfx_mutex_lock (/v6.2-bzimage/kernel/locking/mutex.c:282) hci_power_on (/v6.2-bzimage/net/bluetooth/hci_core.c:485 /v6.2-bzimage/net/bluetooth/hci_core.c:984) ? __pfx_hci_power_on (/v6.2-bzimage/net/bluetooth/hci_core.c:969) ? read_word_at_a_time (/v6.2-bzimage/./include/asm-generic/rwonce.h:85) ? strscpy (/v6.2-bzimage/./arch/x86/include/asm/word-at-a-time.h:62 /v6.2-bzimage/lib/string.c:161) process_one_work (/v6.2-bzimage/kernel/workqueue.c:2294) worker_thread (/v6.2-bzimage/./include/linux/list.h:292 /v6.2-bzimage/kernel/workqueue.c:2437) ? __pfx_worker_thread (/v6.2-bzimage/kernel/workqueue.c:2379) kthread (/v6.2-bzimage/kernel/kthread.c:376) ? __pfx_kthread (/v6.2-bzimage/kernel/kthread.c:331) ret_from_fork (/v6.2-bzimage/arch/x86/entry/entry_64.S:314) </TASK> The buggy address belongs to the variable: amp_init1+0x30/0x60 The buggy address belongs to the physical page: page:000000003a157ec6 refcount:1 mapcount:0 mapping:0000000000000000 ia flags: 0x200000000001000(reserved|node=0|zone=2) raw: 0200000000001000 ffffea0005054688 ffffea0005054688 000000000000000 raw: 0000000000000000 0000000000000000 00000001ffffffff 000000000000000 page dumped because: kasan: bad access detected Memory state around the buggy address: ffffffffaed1aa00: f9 f9 f9 f9 00 00 00 00 f9 f9 f9 f9 00 00 00 00 ffffffffaed1aa80: 00 00 00 00 f9 f9 f9 f9 00 00 00 00 00 00 00 00 >ffffffffaed1ab00: 00 f9 f9 f9 f9 f9 f9 f9 00 00 00 00 00 00 f9 f9 ---truncated---

AI-Powered Analysis

AILast updated: 07/01/2025, 03:54:49 UTC

Technical Analysis

CVE-2023-53057 is a vulnerability identified in the Linux kernel's Bluetooth subsystem, specifically within the Host Controller Interface (HCI) synchronization code. The flaw arises from an out-of-bounds read in the function hci_init_stage_sync(), which iterates over a variable-length array of initialization stages for Bluetooth devices. The function assumes that each stage element is valid as long as the previous element's function pointer is valid. However, two arrays, amp_init1[] and amp_init2[], lack a terminating invalid element, unlike other similar arrays such as hci_init0[] and le_init2[]. This omission causes hci_init_stage_sync() to read beyond the valid bounds of amp_init1[] and amp_init2[], leading to a global out-of-bounds memory access. The bug was detected by Kernel Address Sanitizer (KASAN) during the execution of the hci_dev_open_sync() function, which is responsible for powering on and initializing Bluetooth HCI devices. The out-of-bounds read involves accessing memory beyond the allocated array, potentially causing undefined behavior, memory corruption, or kernel crashes. The patch fixes this by appending an empty invalid element to the end of amp_init1[] and amp_init2[], preventing the function from reading out of bounds. This vulnerability affects Linux kernel versions containing the faulty code, as identified by the commit hashes provided. No known exploits are currently reported in the wild, and no CVSS score has been assigned yet. The vulnerability is technical and low-level, related to kernel memory safety in Bluetooth device initialization.

Potential Impact

For European organizations, the impact of CVE-2023-53057 depends largely on their use of Linux-based systems with Bluetooth capabilities. Many enterprises and public sector entities in Europe deploy Linux servers, desktops, and embedded devices that may include Bluetooth hardware. Exploitation of this vulnerability could lead to kernel crashes (denial of service) or potentially memory corruption, which might be leveraged for privilege escalation or arbitrary code execution by a local attacker. This risk is particularly relevant for organizations using Linux in environments where Bluetooth devices are enabled and accessible, such as in IoT deployments, industrial control systems, or office environments with Bluetooth peripherals. Disruption of critical services or compromise of sensitive systems could result if attackers exploit this flaw. However, the requirement for local code execution or interaction with Bluetooth initialization reduces the likelihood of remote exploitation. The vulnerability could also affect Linux distributions widely used in Europe, impacting sectors such as finance, healthcare, manufacturing, and government. The absence of known exploits currently limits immediate risk, but timely patching is essential to prevent future attacks.

Mitigation Recommendations

European organizations should take the following specific mitigation steps: 1) Identify all Linux systems with Bluetooth enabled, including servers, desktops, laptops, and embedded devices. 2) Apply the official Linux kernel patches that add the terminating invalid elements to amp_init1[] and amp_init2[] arrays as soon as they are available from trusted Linux distribution vendors or kernel maintainers. 3) If immediate patching is not possible, consider disabling Bluetooth functionality on critical systems to reduce attack surface. 4) Monitor system logs for unusual Bluetooth initialization errors or kernel warnings related to hci_dev_open_sync. 5) Employ kernel hardening techniques such as Kernel Address Sanitizer (KASAN) in testing environments to detect similar memory safety issues proactively. 6) Maintain up-to-date inventories of Linux kernel versions in use and subscribe to security advisories from Linux vendors and the CVE database. 7) Educate system administrators about the risks of Bluetooth-related kernel vulnerabilities and the importance of patch management. These targeted actions go beyond generic advice by focusing on Bluetooth subsystem awareness and kernel patch application.

Need more detailed analysis?Get Pro

Technical Details

Data Version
5.1
Assigner Short Name
Linux
Date Reserved
2025-05-02T15:51:43.547Z
Cisa Enriched
false
Cvss Version
null
State
PUBLISHED

Threat ID: 682d9830c4522896dcbe6e52

Added to database: 5/21/2025, 9:09:04 AM

Last enriched: 7/1/2025, 3:54:49 AM

Last updated: 8/12/2025, 9:26:47 AM

Views: 14

Actions

PRO

Updates to AI analysis are available only with a Pro account. Contact root@offseq.com for access.

Please log in to the Console to use AI analysis features.

Need enhanced features?

Contact root@offseq.com for Pro access with improved analysis and higher rate limits.

Latest Threats