exploit the possibilities
Home Files News &[SERVICES_TAB]About Contact Add New

Google Nexus 9 SensorHub Firmware Downgrade

Google Nexus 9 SensorHub Firmware Downgrade
Posted May 9, 2017
Authored by Roee Hay

Google Nexus 9 SensorHub firmware suffers from a downgrade vulnerability.

tags | advisory
advisories | CVE-2017-0582
SHA-256 | 2e333ae95fe2406ff357ae559841fa415ab16be941f0e11c2c726abab2919d30

Google Nexus 9 SensorHub Firmware Downgrade

Change Mirror Download
Title:
====
Google Nexus 9 SensorHub Firmware Downgrade Vulnerability

Identifier:
========
CVE-2017-0582

Product:
=======
Google Nexus 9

Vulnerable Version:
================
Nexus 9 Android Builds before N4F27B - May 2017, i.e. before bootloader 3.50.0.0143.

Mitigation:
=========
Install N4F27B or later (bootloader version 3.50.0.0143).

Severity:
=======
Moderate

Technical Details:
==============
The Nexus 9 device contains a SoC manufactured by Cywee which implements a "Sensor Hub". The SoC is an STM32F401B/C ARM Cortext-M4 MCU, managed by a driver available under drivers/i2c/chips/CwMcuSensor.c. The platform communicates with SensorHub via I2C bus #0 and 4 GPIO ports.

Upon the platform boot, the CwMcuSensor driver queries the firmware's version (I2C register 0x10). If it does not match the one found in the vendor's partition (/vendor/firmware/sensor_hub.img), it switches to the bootloader mode, and upgrades the firmware (again, via I2C). Please note that the firmware is not signed.

By issuing a proprietary fastboot oem command: 'sensorhubflash', a physical attacker / malicious charger / malicious headphones (via the UART interface, exposed by the headphones jack - see our blog post [2]) can downgrade the SensorHub firmware to an old version, saved under the 'SER' partition (/dev/block/mmcblk0p19). This version may contain vulnerabilities which may allow the attacker to compromise the MCU.
One may claim that it is not an issue because the platform would immediately upgrade the firmware upon boot (since its version is different from the one found in the vendor image), however, in Nexus 9, the I2C buses could be accessed via the fastboot interface, by using the fastboot oem {i2cr, i2cw, i2crNoAddr, i2cwNoAddr, i2cdetect} commands. (I2C could also be accessed via UART, in the HBOOT mode. [2]) Thus, the attacker could interact with the old firmware BEFORE it was replaced by the platform using I2C, and thus potentially exploit a security vulnerability which would allow him to return a bogus version identifier, bypassing the platform's check. Please note that the SoC's I2C code runs in privileged mode.

For more details and PoC, visit the Aleph Research Vulnerability Report [1].

Patch:
=====
Google patched the vulnerability on build N4F27B / bootloader 3.50.0.0143 by removing the 'sensorhubflash' bootloader command. In addition, Google restricted access to the I2C buses - The I2C related bootloader commands are no longer available.
Please note that although Google published the advisory on the April 2017 Security Bulletin [3], the patch has been included only since the April 5 2017 Security Patch Level, where the April Nexus 9 image (N4F26X) has the April 1 2017 Security Patch Level, hence it does not contain the patched bootloader.

Credit:
=====
Roee Hay (@roeehay) of Aleph Research, HCL technologies.

References:
==========
[1] Aleph Research Vulnerability Report. https://alephsecurity.com/vulns/aleph-2017010
[2] Attacking Nexus 9 with Malicious Headphones. https://alephsecurity.com/2017/03/08/nexus9-fiq-debugger/
[3] Google's Security Bulletin (April 2017). https://source.android.com/security/bulletin/2017-04-01#eop-in-htc-oem-fastboot-command


::DISCLAIMER::
----------------------------------------------------------------------------------------------------------------------------------------------------

The contents of this e-mail and any attachment(s) are confidential and intended for the named recipient(s) only.
E-mail transmission is not guaranteed to be secure or error-free as information could be intercepted, corrupted,
lost, destroyed, arrive late or incomplete, or may contain viruses in transmission. The e mail and its contents
(with or without referred errors) shall therefore not attach any liability on the originator or HCL or its affiliates.
Views or opinions, if any, presented in this email are solely those of the author and may not necessarily reflect the
views or opinions of HCL or its affiliates. Any form of reproduction, dissemination, copying, disclosure, modification,
distribution and / or publication of this message without the prior written consent of authorized representative of
HCL is strictly prohibited. If you have received this email in error please delete it and notify the sender immediately.
Before opening any email and/or attachments, please check them for viruses and other defects.

----------------------------------------------------------------------------------------------------------------------------------------------------



Login or Register to add favorites

File Archive:

April 2024

  • Su
  • Mo
  • Tu
  • We
  • Th
  • Fr
  • Sa
  • 1
    Apr 1st
    10 Files
  • 2
    Apr 2nd
    26 Files
  • 3
    Apr 3rd
    40 Files
  • 4
    Apr 4th
    6 Files
  • 5
    Apr 5th
    26 Files
  • 6
    Apr 6th
    0 Files
  • 7
    Apr 7th
    0 Files
  • 8
    Apr 8th
    22 Files
  • 9
    Apr 9th
    14 Files
  • 10
    Apr 10th
    10 Files
  • 11
    Apr 11th
    13 Files
  • 12
    Apr 12th
    14 Files
  • 13
    Apr 13th
    0 Files
  • 14
    Apr 14th
    0 Files
  • 15
    Apr 15th
    30 Files
  • 16
    Apr 16th
    10 Files
  • 17
    Apr 17th
    22 Files
  • 18
    Apr 18th
    45 Files
  • 19
    Apr 19th
    8 Files
  • 20
    Apr 20th
    0 Files
  • 21
    Apr 21st
    0 Files
  • 22
    Apr 22nd
    11 Files
  • 23
    Apr 23rd
    68 Files
  • 24
    Apr 24th
    23 Files
  • 25
    Apr 25th
    0 Files
  • 26
    Apr 26th
    0 Files
  • 27
    Apr 27th
    0 Files
  • 28
    Apr 28th
    0 Files
  • 29
    Apr 29th
    0 Files
  • 30
    Apr 30th
    0 Files

Top Authors In Last 30 Days

File Tags

Systems

packet storm

© 2022 Packet Storm. All rights reserved.

Services
Security Services
Hosting By
Rokasec
close