A supply-chain attack targeting Android-based car head units is using a legitimate device-update app to spread malware that enlists compromised devices in a proxy botnet or uses them for ad fraud.

Kaspersky researchers analyzed the malware and attributed the operation to the MoYu group, a threat actor previously associated with the BadBox malware botnet. The researchers note that this is the first documented case of a malware infection chain specifically created for a targeted car head unit.

MoYu’s operation targets systems from DoFun, a Chinese automotive software and hardware provider owned by Shenzhen Driving Control Technology Co., Ltd. DoFun sells generic Android-based head units that act as the command center for a car’s infotainment, navigation, and settings systems.

In June, Kaspersky researchers found a rogue APK file being downloaded from a legitimate DoFun system app, TWCore, which receives instructions through an MQTT server hosted at cardoor[.]cn.

The unknown app has no interface and is a piece of malware called JarService. When launched, the malware decrypts and executes a second-stage loader that establishes communication with a command-and-control (C2) server and downloads another encrypted payload.

The final payload periodically reports device information such as the model, display resolution, Wi-Fi SSID, and MAC address, and retrieves commands from the attackers.

The malware supports the following nine commands:

  1. return – Retrieves a specified value from Android’s SharedPreferences storage
  2. copy – Copies stored or downloaded content to the device clipboard
  3. http – Sends HTTP GET or POST requests and can save part of the response
  4. web – Opens a URL in a WebView and executes supplied JavaScript
  5. loadlib – Not fully implemented when Kaspersky published the report
  6. loadlib2 – Downloads and executes arbitrary code or additional modules
  7. loadlib3 – Not fully implemented when Kaspersky published the report
  8. deeplink – Opens a specified resource in the browser
  9. traceroute – Checks whether specified hosts are reachable using ICMP ping

Kaspersky says the malware does not interfere with driving or critical vehicle control systems, and appears designed for advertising fraud and turning internet-connected car head units into residential proxy nodes for monetization purposes.

The head unit infection scheme The head unit infection schemeSource: Kaspersky

Researchers discovered that the operator primarily loaded a reverse-proxy module named ‘zhima,’ which turns the head unit into a proxy botnet node, and also made web requests for click-fraud activity.

Kaspersky says it notified DoFun of its findings, and the Chinese firm replied that it resolved the problem. BleepingComputer has contacted both companies with questions about the initial compromise vector, and will update the article once more information is received.