miaofng uds-c Stack Buffer Overflow Vulnerability in send_diagnostic_request

Vulnerability

A stack buffer overflow vulnerability has been identified in the miaofng uds-c library, specifically in commit e506334e. The issue arises in the send_diagnostic_request function, where a 6-byte stack buffer is vulnerable to overflow. The vulnerability occurs because the buffer receives data via memcpy from an attacker-controlled length parameter, without any prior bounds checking. This flaw allows for a payload length that exceeds the buffer's capacity, leading to potential memory corruption.

Impact

Exploitation of this vulnerability causes a stack buffer overflow, which can lead to arbitrary code execution or a crash of the application.

Reproduction

The vulnerability can be reproduced by sending a crafted UDS request that includes a payload length exceeding the maximum buffer size. This can be done by manipulating the request structure to include an oversized payload length, which is then copied into the stack buffer without any bounds validation.

Added: May 1, 2026, 5:25 PM
Updated: May 1, 2026, 5:25 PM

Vulnerability Rating

Custom Algorithm
spread
0.0
impact
7.5
exploitability
7.1
remediation
0.0
relevance
7.2
threat
4.8
urgency
2.9
incentive
0.0

Our algorithm analyzes dozens of metrics to generate these 8 key vulnerability categories, which are then combined to calculate the overall risk score.