Paint it blue Attacking the bluetooth stack #1530
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
🤖 Automated Content Update
This PR was automatically generated by the HackTricks News Bot based on a technical blog post.
📝 Source Information
🎯 Content Summary
What: Deep-dive exploitation of Android’s Fluoride Bluetooth Host stack via CVE-2023-40129, an integer-underflow in the GATT server’s Read Multiple Variable response builder that yields a ~64KB heap overflow. The post shows end-to-end, no-user-interaction RCE against devices using both jemalloc and Scudo, building reliable read/write primitives, bypassing ASLR via callback hijacking, and finally executing shellcode. Includes a minimal PoC trigger and a reusable tooling framew...
🔧 Technical Details
GATT multi-read integer-underflow → overflow (CVE-2023-40129): In variable-length Read Multiple responses, subtracting
(total_len - mtu)without accounting for the +2 length field underflowslen. Set a small MTU and request enough attributes solenbecomes 0xFFFE; thememcpy()copies ~64KB past the buffer.Unauth + multi-channel via Just Works: Use Just Works pairing to open additional L2CAP channels (e.g., GAP/AVCTP) without UI. Note it’s non‑MITM‑safe (some GATT ops still restricted) and can break existing pairing for the same BDADDR; adequate for exploitation chains needing multiple channels.
ACL congestion to persist controlled allocations: With controller-level flow control (e.g., Cypress vendor HCI), declare ACL congestion so Fluoride queues responses (notably L2CAP signaling CONFIG REJ). These queued messages persist and are attacker-shaped for heap feng shui.🤖 Agent Actions
I analyzed the Synacktiv blog “Paint it blue: Attacking the bluetooth stack”, explored the repository, and identified the best place to incorporate this highly technical Bluetooth/L2CAP/ATT/GATT exploitation content. The pentesting-network section did not yet cover Bluetooth, and the only existing BLE doc lives under todo/radio-hacking (not integrated into the Network methodology), so I added a concise, technical “Bluetooth (L2CAP/ATT/GATT) Attacks” section into the canonical Network Methodology page.
What I added
A new subsection in src/generic-methodologies-and-resources/pentesting-network/README.md titled “Bluetooth (L2CAP/ATT/GATT) Attacks”
Updated the “## References” section in the same file with:
Files modified
Why here
If you want me to also integrate a cross-link from the existing BLE “todo/radio-hacking” page to this new section, I can do that in a future pass (would require modifying that second file).
This PR was automatically created by the HackTricks Feed Bot. Please review the changes carefully before merging.