CVE-2025-5828
Executive Summary
CVE-2025-5828 is a critical stack-based buffer overflow vulnerability in the Autel MaxiCharger AC Wallbox Commercial electric vehicle (EV) charger. The flaw resides in the device’s USB frame packet handling, allowing a physically present attacker to trigger remote code execution (RCE) without authentication. With a CVSS score of 6.8 (Medium), the vulnerability is exploitable via physical USB access, enabling full device compromise. No public proof-of-concept (PoC) or patch exists as of this report. The EPSS score is 0.0%, indicating low exploitation likelihood in the wild, but the physical attack vector and lack of authentication make it a high-risk target for targeted attacks on EV charging infrastructure.
This record — and 170,000+ others — are available via the ValtersIT API. One endpoint replaces five: NVD + GitHub CVE + CISA KEV + EPSS + Nuclei + Exploit-DB, unified.
No signup required
Supply Chain & Package Security
This vulnerability is not related to NPM, PyPI, Go, or Ruby packages. It is a firmware-level issue in a proprietary embedded device (Autel EV charger). No open-source package dependencies are involved.
CVSS Breakdown & Threat Level
- Attack Vector (AV): Physical (AV:P) – Requires physical USB connection to the charger.
- Attack Complexity (AC): Low (AC:L) – No special conditions needed.
- Privileges Required (PR): None (PR:N) – No authentication needed.
- User Interaction (UI): None (UI:N) – No user action required.
- Scope (S): Unchanged (S:U) – Exploit affects only the device.
- Confidentiality (C): High (C:H) – Full device data access.
- Integrity (I): High (I:H) – Arbitrary code execution.
- Availability (A): High (A:H) – Potential denial of service or device bricking.
Threat Level: Medium (6.8) – Physical access required, but impact is severe.
Deep Dive & Mechanics
The vulnerability is a classic stack-based buffer overflow (CWE-121) in the USB frame packet handler of the Autel MaxiCharger AC Wallbox Commercial firmware. The device processes USB packets from a connected host (e.g., a laptop or USB drive) without validating the length of user-supplied data before copying it to a fixed-length stack buffer. An attacker can craft a malicious USB frame packet with a payload exceeding the buffer size, overwriting the return address and other stack data. This allows arbitrary code execution in the context of the device’s firmware, typically with root or system-level privileges.
Root Cause: The memcpy or similar function is used without bounds checking on the length field of the USB frame packet. The buffer is allocated on the stack, making it vulnerable to stack smashing.
Attack Vector: Physical USB port access. The attacker connects a malicious USB device (e.g., a USB Rubber Ducky or custom USB gadget) to the charger’s USB port. The charger processes the malicious frame, triggering the overflow.
Impact: Full device compromise – attacker can install persistent malware, exfiltrate charging data, disable the charger, or pivot to the connected EV’s network.
Vulnerable vs. Patched Code
Vulnerable Code (C-like pseudocode):
void handle_usb_frame(uint8_t *frame, uint16_t length) {
char buffer[64]; // Fixed-length stack buffer
// No length validation
memcpy(buffer, frame, length); // Overflow if length > 64
// Process buffer...
}
Patched Code (Hypothetical fix):
void handle_usb_frame(uint8_t *frame, uint16_t length) {
char buffer[64];
if (length > sizeof(buffer)) {
// Reject oversized frame
return;
}
memcpy(buffer, frame, length);
// Process buffer...
}
Note: No official patch is available. The fix would involve adding bounds checking and possibly using a heap-based buffer or dynamic allocation.
Exploitation & Lab Setup
Red Team (Offensive)
Prerequisites:
- Physical access to the Autel MaxiCharger AC Wallbox Commercial USB port.
- A USB device capable of sending custom USB frames (e.g., Raspberry Pi Zero with USB gadget mode, or a USB Rubber Ducky).
- Knowledge of the device’s firmware memory layout (e.g., via reverse engineering).
Exploit Steps:
- Reconnaissance: Connect to the charger’s USB port and enumerate USB endpoints. Identify the vulnerable frame handler (e.g., via fuzzing).
- Craft Payload: Create a USB frame with a length field > 64 bytes. The payload includes shellcode (e.g., ARM or MIPS depending on the device’s CPU) to spawn a reverse shell or execute arbitrary commands.
- Deliver: Send the malicious USB frame to the charger. The overflow overwrites the return address, redirecting execution to the shellcode.
- Post-Exploitation: Maintain persistence (e.g., modify firmware), exfiltrate data, or disable the charger.
Example Payload Structure (Conceptual):
[USB Frame Header] [Length: 0x100] [Padding: 64 bytes] [Return Address: 0xdeadbeef] [Shellcode: ...]
No public exploit code is available.
Blue Team (Defensive)
Detection:
- Monitor USB device connections to the charger (e.g., via syslog or SNMP).
- Use network segmentation to isolate chargers from critical systems.
- Deploy USB device whitelisting (e.g., only allow authorized USB drives).
Mitigation:
- Disable unused USB ports on the charger if possible.
- Apply firmware updates as soon as they become available.
- Use physical security (e.g., locked enclosures) to prevent unauthorized USB access.
Indicators of Compromise (IOCs)
- Network: Unusual outbound connections from the charger (e.g., to unknown IPs on port 4444 for reverse shells).
- USB: Detection of non-standard USB devices (e.g., USB gadget mode devices) connected to the charger.
- Firmware: Modified firmware hash or unexpected processes running on the device.
- Logs: USB frame errors or buffer overflow crashes in device logs.
Example IOC (YARA rule for firmware analysis):
rule CVE_2025_5828_Exploit {
meta:
description = "Detects shellcode or exploit artifacts for CVE-2025-5828"
author = "Valters IT"
date = "2025-04-10"
strings:
$shellcode = { 31 c0 50 68 2f 2f 73 68 68 2f 62 69 6e 89 e3 50 53 89 e1 b0 0b cd 80 } // Linux x86 execve /bin/sh
$overflow_pattern = { 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 } // 0x41 padding
condition:
any of them
}
Detection Engineering
YARA Rule
rule CVE_2025_5828_USB_Frame_Overflow {
meta:
description = "Detects malicious USB frames targeting Autel MaxiCharger AC Wallbox"
author = "Valters IT"
date = "2025-04-10"
reference = "CVE-2025-5828"
strings:
$usb_header = { 55 53 42 43 } // "USBC" USB frame header (example)
$long_length = { 00 41 } // Length > 64 bytes (0x4100 = 16640)
condition:
$usb_header and $long_length and filesize > 100
}
Sigma Rule
title: CVE-2025-5828 Autel MaxiCharger USB Buffer Overflow Attempt
id: 8a9b7c6d-5e4f-3a2b-1c0d-9e8f7a6b5c4d
status: experimental
description: Detects USB frames with excessive length sent to Autel EV chargers
author: Valters IT
date: 2025-04-10
logsource:
product: linux
service: syslog
detection:
selection:
- "USB frame length exceeded"
- "buffer overflow detected"
condition: selection
falsepositives:
- Legitimate firmware updates (rare)
level: high
Suricata Rule
alert tcp any any -> any any (msg:"CVE-2025-5828 Autel USB Frame Overflow Attempt"; content:"|55 53 42 43|"; offset:0; depth:4; content:"|00 41|"; distance:4; within:2; sid:1000001; rev:1;)
Note: Suricata rule assumes USB over TCP (e.g., USB/IP). For direct USB, use host-based detection.
Remediation & Mitigation
Immediate Actions:
- Disable USB ports on the charger if not required for operation.
- Physical security: Enclose chargers in locked cabinets to prevent unauthorized USB access.
- Monitor logs for USB-related errors or crashes.
Long-Term Fix:
- Apply firmware patch from Autel when available (no patch as of this report).
- Implement input validation in USB frame handling (bounds checking).
- Use stack canaries and ASLR in firmware.
Workaround:
- Use network-based charging management instead of USB for configuration.
Valters IT
Cyber Threat Intelligence Division
Report generated: 2025-04-10
What is this? Security researchers use these exact search queries on Shodan.io (a search engine for internet-connected devices) to find vulnerable systems globally. You can copy these dorks to see if your organization's IP space is exposed.
💣 PoC CODE AVAILABLE
Exploit code for this CVE is tracked in our database.
Access poc_code via API Pro.