CVE-2020-27153
High · 8.6CVSS
8.6
EPSS
4.3%
Published
Oct 15, 2020
CISA due date
—
Cloudanix analysis
A problem in Bluetooth software on many Linux devices can let nearby attackers crash the system or possibly run their own code when devices try to connect.
- Exploitation
- Remote Unauthenticated
- Attacker needs
- None
- Complexity
- Low
- Impact
- Remote Code Execution
- Component
- Library
- Class
- Memory Corruption
- Remediation
- Upgrade
- Effort
- Medium
- Patch risk
- Low
What it actually does
Double free in gatttool disconnect_cb() from shared/att.c triggered by redundant disconnect MGMT events during service discovery, resulting in memory corruption that can lead to denial of service or code execution.
Why it matters to the business
Remote attackers can crash Bluetooth daemons or potentially execute code on Linux systems using BlueZ, disrupting device pairing, service discovery, and wireless connectivity for affected products.
How an attack unfolds
An attacker within Bluetooth range sends crafted packets that cause multiple MGMT disconnect events during GATT service discovery; the redundant event handling in disconnect_cb performs a double free, corrupting memory and enabling DoS or code execution.
How to fix it
Upgrade BlueZ to version 5.55 or later; apply commit 5a180f2ec9edfacafd95e5fed20d36fe8e077f07 in the bluez/bluez GIT repository. Disable unnecessary Bluetooth services until patched.
How to confirm the fix worked
Verify BlueZ version is 5.55 or newer; confirm the listed commit is present in the shared/att.c file; test service discovery does not produce duplicate MGMT events.
Typical attack path
- Establish proximity to a vulnerable BlueZ device
- Initiate Bluetooth connection and trigger service discovery
- Send packets inducing redundant MGMT disconnect events
- Trigger double free in disconnect_cb to corrupt memory
- Leverage corruption for denial of service or code execution
How to detect it
Review Bluetooth daemon logs and MGMT event traces for repeated or anomalous disconnect events during service discovery; inspect crash dumps or memory error reports referencing att.c or gatttool around the time of Bluetooth activity.
What your security team should do
- Immediately update all BlueZ installations to 5.55 or the referenced commit
- Monitor for any remaining unpatched systems given the six-year publication window
- Disable Bluetooth where not required to reduce attack surface
- Review downstream dependents for inherited exposure
The record
In BlueZ before 5.55, a double free was found in the gatttool disconnect_cb() routine from shared/att.c. A remote attacker could potentially cause a denial of service or code execution, during service discovery, due to a redundant disconnect MGMT event.
Affected packages
| Ecosystem | Package | Introduced | Fixed |
|---|---|---|---|
| AlmaLinux:8 | bluez-libs-devel | 0 | 5.52-4.el8.alma |
| Alpine:v3.10 | bluez | 0 | 5.50-r5 |
| Alpine:v3.11 | bluez | 0 | 5.52-r2 |
| Alpine:v3.12 | bluez | 0 | 5.54-r6 |
| Alpine:v3.9 | bluez | 0 | 5.50-r2 |
| Debian:10 | bluez | 0 | 5.50-1.2~deb10u2 |
| Debian:11 | bluez | 0 | 5.55-1 |
| Debian:12 | bluez | 0 | 5.55-1 |
| Debian:13 | bluez | 0 | 5.55-1 |
| Debian:9 | bluez | 0 | 5.43-2+deb9u3 |
| Mageia:7 | bluez | 0 | 5.54-1.1.mga7 |
| Red Hat:enterprise_linux:8::appstream | bluez | 0 | 0:5.52-4.el8 |
| Red Hat:enterprise_linux:8::appstream | bluez-cups | 0 | 0:5.52-4.el8 |
| Red Hat:enterprise_linux:8::appstream | bluez-cups-debuginfo | 0 | 0:5.52-4.el8 |
| Red Hat:enterprise_linux:8::appstream | bluez-debuginfo | 0 | 0:5.52-4.el8 |
| Red Hat:enterprise_linux:8::appstream | bluez-debugsource | 0 | 0:5.52-4.el8 |
| Red Hat:enterprise_linux:8::appstream | bluez-hid2hci | 0 | 0:5.52-4.el8 |
| Red Hat:enterprise_linux:8::appstream | bluez-hid2hci-debuginfo | 0 | 0:5.52-4.el8 |
| Red Hat:enterprise_linux:8::appstream | bluez-libs | 0 | 0:5.52-4.el8 |
| Red Hat:enterprise_linux:8::appstream | bluez-libs-debuginfo | 0 | 0:5.52-4.el8 |
| Red Hat:enterprise_linux:8::appstream | bluez-libs-devel | 0 | 0:5.52-4.el8 |
| Red Hat:enterprise_linux:8::appstream | bluez-obexd | 0 | 0:5.52-4.el8 |
| Red Hat:enterprise_linux:8::appstream | bluez-obexd-debuginfo | 0 | 0:5.52-4.el8 |
| Red Hat:enterprise_linux:8::baseos | bluez | 0 | 0:5.52-4.el8 |
| Red Hat:enterprise_linux:8::baseos | bluez-cups | 0 | 0:5.52-4.el8 |
| Red Hat:enterprise_linux:8::baseos | bluez-cups-debuginfo | 0 | 0:5.52-4.el8 |
| Red Hat:enterprise_linux:8::baseos | bluez-debuginfo | 0 | 0:5.52-4.el8 |
| Red Hat:enterprise_linux:8::baseos | bluez-debugsource | 0 | 0:5.52-4.el8 |
| Red Hat:enterprise_linux:8::baseos | bluez-hid2hci | 0 | 0:5.52-4.el8 |
| Red Hat:enterprise_linux:8::baseos | bluez-hid2hci-debuginfo | 0 | 0:5.52-4.el8 |
| Red Hat:enterprise_linux:8::baseos | bluez-libs | 0 | 0:5.52-4.el8 |
| Red Hat:enterprise_linux:8::baseos | bluez-libs-debuginfo | 0 | 0:5.52-4.el8 |
| Red Hat:enterprise_linux:8::baseos | bluez-libs-devel | 0 | 0:5.52-4.el8 |
| Red Hat:enterprise_linux:8::baseos | bluez-obexd | 0 | 0:5.52-4.el8 |
| Red Hat:enterprise_linux:8::baseos | bluez-obexd-debuginfo | 0 | 0:5.52-4.el8 |
| Red Hat:enterprise_linux:8::crb | bluez | 0 | 0:5.52-4.el8 |
| Red Hat:enterprise_linux:8::crb | bluez-cups | 0 | 0:5.52-4.el8 |
| Red Hat:enterprise_linux:8::crb | bluez-cups-debuginfo | 0 | 0:5.52-4.el8 |
| Red Hat:enterprise_linux:8::crb | bluez-debuginfo | 0 | 0:5.52-4.el8 |
| Red Hat:enterprise_linux:8::crb | bluez-debugsource | 0 | 0:5.52-4.el8 |
| Red Hat:enterprise_linux:8::crb | bluez-hid2hci | 0 | 0:5.52-4.el8 |
| Red Hat:enterprise_linux:8::crb | bluez-hid2hci-debuginfo | 0 | 0:5.52-4.el8 |
| Red Hat:enterprise_linux:8::crb | bluez-libs | 0 | 0:5.52-4.el8 |
| Red Hat:enterprise_linux:8::crb | bluez-libs-debuginfo | 0 | 0:5.52-4.el8 |
| Red Hat:enterprise_linux:8::crb | bluez-libs-devel | 0 | 0:5.52-4.el8 |
| Red Hat:enterprise_linux:8::crb | bluez-obexd | 0 | 0:5.52-4.el8 |
| Red Hat:enterprise_linux:8::crb | bluez-obexd-debuginfo | 0 | 0:5.52-4.el8 |
| Rocky Linux:8 | bluez | 0 | 0:5.52-4.el8 |
| SUSE:Linux Enterprise Module for Basesystem 15 SP1 | bluez | 0 | 5.48-5.28.1 |
| SUSE:Linux Enterprise Module for Basesystem 15 SP2 | bluez | 0 | 5.48-13.3.1 |
| SUSE:Linux Enterprise Module for Desktop Applications 15 SP1 | bluez | 0 | 5.48-5.28.1 |
| SUSE:Linux Enterprise Module for Desktop Applications 15 SP2 | bluez | 0 | 5.48-13.3.1 |
| SUSE:Linux Enterprise Workstation Extension 15 SP1 | bluez | 0 | 5.48-5.28.1 |
| SUSE:Linux Enterprise Workstation Extension 15 SP2 | bluez | 0 | 5.48-13.3.1 |
| Ubuntu:18.04:LTS | bluez | 0 | 5.48-0ubuntu3.5 |
| Ubuntu:20.04:LTS | bluez | 0 | 5.53-0ubuntu3.2 |
| Ubuntu:Pro:16.04:LTS | bluez | 0 | 5.37-0ubuntu5.3+esm1 |
| openSUSE:Leap 15.1 | bluez | 0 | 5.48-lp151.8.15.1 |
| openSUSE:Leap 15.2 | bluez | 0 | 5.48-lp152.12.6.1 |
Related vulnerabilities
- CVE-2023-51589 BlueZ Audio Profile AVRCP parse_media_element Out-Of-Bounds Read Information Disclosure… Also affects bluez-libs-devel
- CVE-2023-27349 BlueZ Audio Profile AVRCP Improper Validation of Array Index Remote Code Execution… Also affects bluez-libs-devel
- CVE-2023-45866 Bluetooth HID Hosts in BlueZ may permit an unauthenticated Peripheral role HID Device to… Also affects bluez-libs-devel
- CVE-2022-39176 BlueZ before 5.59 allows physically proximate attackers to obtain sensitive information… Also affects bluez
- CVE-2022-39177 BlueZ before 5.59 allows physically proximate attackers to cause a denial of service… Also affects bluez
- CVE-2022-0204 A heap overflow vulnerability was found in bluez in versions prior to 5.63. Also affects bluez
- CVE-2019-8921 An issue was discovered in bluetoothd in BlueZ through 5.48. Also affects bluez
- CVE-2019-8922 A heap-based buffer overflow was discovered in bluetoothd in BlueZ through 5.48. Also affects bluez