The SentinelOne Annual Threat Report - A Defenders Guide from the FrontlinesThe SentinelOne Annual Threat ReportGet the Report
Experiencing a Breach?Blog
Get StartedContact Us
SentinelOne
  • Platform
    Platform Overview
    • Singularity Platform
      Welcome to Integrated Enterprise Security
    • AI for Security
      Leading the Way in AI-Powered Security Solutions
    • Securing AI
      Accelerate AI Adoption with Secure AI Tools, Apps, and Agents.
    • How It Works
      The Singularity XDR Difference
    • Singularity Marketplace
      One-Click Integrations to Unlock the Power of XDR
    • Pricing & Packaging
      Comparisons and Guidance at a Glance
    Data & AI
    • Purple AI
      Accelerate SecOps with Generative AI
    • Singularity Hyperautomation
      Easily Automate Security Processes
    • AI-SIEM
      The AI SIEM for the Autonomous SOC
    • AI Data Pipelines
      Security Data Pipeline for AI SIEM and Data Optimization
    • Singularity Data Lake
      AI-Powered, Unified Data Lake
    • Singularity Data Lake for Log Analytics
      Seamlessly Ingest Data from On-Prem, Cloud or Hybrid Environments
    Endpoint Security
    • Singularity Endpoint
      Autonomous Prevention, Detection, and Response
    • Singularity XDR
      Native & Open Protection, Detection, and Response
    • Singularity RemoteOps Forensics
      Orchestrate Forensics at Scale
    • Singularity Threat Intelligence
      Comprehensive Adversary Intelligence
    • Singularity Vulnerability Management
      Application & OS Vulnerability Management
    • Singularity Identity
      Identity Threat Detection and Response
    Cloud Security
    • Singularity Cloud Security
      Block Attacks with an AI-Powered CNAPP
    • Singularity Cloud Native Security
      Secure Cloud and Development Resources
    • Singularity Cloud Workload Security
      Real-Time Cloud Workload Protection Platform
    • Singularity Cloud Data Security
      AI-Powered Threat Detection for Cloud Storage
    • Singularity Cloud Security Posture Management
      Detect and Remediate Cloud Misconfigurations
    Securing AI
    • Prompt Security
      Secure AI Tools Across Your Enterprise
  • Why SentinelOne?
    Why SentinelOne?
    • Why SentinelOne?
      Cybersecurity Built for What’s Next
    • Our Customers
      Trusted by the World’s Leading Enterprises
    • Industry Recognition
      Tested and Proven by the Experts
    • About Us
      The Industry Leader in Autonomous Cybersecurity
    Compare SentinelOne
    • Arctic Wolf
    • Broadcom
    • CrowdStrike
    • Cybereason
    • Microsoft
    • Palo Alto Networks
    • Sophos
    • Splunk
    • Trellix
    • Trend Micro
    • Wiz
    Verticals
    • Energy
    • Federal Government
    • Finance
    • Healthcare
    • Higher Education
    • K-12 Education
    • Manufacturing
    • Retail
    • State and Local Government
  • Services
    Managed Services
    • Managed Services Overview
      Wayfinder Threat Detection & Response
    • Threat Hunting
      World-Class Expertise and Threat Intelligence
    • Managed Detection & Response
      24/7/365 Expert MDR Across Your Entire Environment
    • Incident Readiness & Response
      DFIR, Breach Readiness, & Compromise Assessments
    Support, Deployment, & Health
    • Technical Account Management
      Customer Success with Personalized Service
    • SentinelOne GO
      Guided Onboarding & Deployment Advisory
    • SentinelOne University
      Live and On-Demand Training
    • Services Overview
      Comprehensive Solutions for Seamless Security Operations
    • SentinelOne Community
      Community Login
  • Partners
    Our Network
    • MSSP Partners
      Succeed Faster with SentinelOne
    • Singularity Marketplace
      Extend the Power of S1 Technology
    • Cyber Risk Partners
      Enlist Pro Response and Advisory Teams
    • Technology Alliances
      Integrated, Enterprise-Scale Solutions
    • SentinelOne for AWS
      Hosted in AWS Regions Around the World
    • Channel Partners
      Deliver the Right Solutions, Together
    • SentinelOne for Google Cloud
      Unified, Autonomous Security Giving Defenders the Advantage at Global Scale
    • Partner Locator
      Your Go-to Source for Our Top Partners in Your Region
    Partner Portal→
  • Resources
    Resource Center
    • Case Studies
    • Data Sheets
    • eBooks
    • Reports
    • Videos
    • Webinars
    • Whitepapers
    • Events
    View All Resources→
    Blog
    • Feature Spotlight
    • For CISO/CIO
    • From the Front Lines
    • Identity
    • Cloud
    • macOS
    • SentinelOne Blog
    Blog→
    Tech Resources
    • SentinelLABS
    • Ransomware Anthology
    • Cybersecurity 101
  • About
    About SentinelOne
    • About SentinelOne
      The Industry Leader in Cybersecurity
    • Investor Relations
      Financial Information & Events
    • SentinelLABS
      Threat Research for the Modern Threat Hunter
    • Careers
      The Latest Job Opportunities
    • Press & News
      Company Announcements
    • Cybersecurity Blog
      The Latest Cybersecurity Threats, News, & More
    • FAQ
      Get Answers to Our Most Frequently Asked Questions
    • DataSet
      The Live Data Platform
    • S Foundation
      Securing a Safer Future for All
    • S Ventures
      Investing in the Next Generation of Security, Data and AI
  • Pricing
Get StartedContact Us
CVE Vulnerability Database
Vulnerability Database/CVE-2026-37536

CVE-2026-37536: uds-c Buffer Overflow Vulnerability

CVE-2026-37536 is a stack buffer overflow in miaofng/uds-c send_diagnostic_request function that allows memory corruption. This post explains its impact, affected versions, and mitigation steps.

Published: May 7, 2026

CVE-2026-37536 Overview

CVE-2026-37536 is a stack buffer overflow [CWE-121] in the miaofng/uds-c library, an implementation of the Unified Diagnostic Services (UDS) protocol used in automotive Controller Area Network (CAN) stacks. The vulnerable code resides in send_diagnostic_request at commit e506334e270d77b20c0bc259ac6c7d8c9b702b7a (2016-10-05). The function copies attacker-controlled payload bytes into a 6-byte stack buffer without validating payload_length, allowing a 4-byte overflow past the buffer boundary. An adjacent-network attacker on the CAN bus can corrupt stack memory in any process linking the affected library.

Critical Impact

A malformed UDS diagnostic request can overwrite stack memory in the calling process, leading to memory corruption, denial of service, or arbitrary code execution on automotive control units that integrate uds-c.

Affected Products

  • miaofng/uds-c at commit e506334e270d77b20c0bc259ac6c7d8c9b702b7a (2016-10-05)
  • Downstream forks of the UDS-C library, including the OpenXC uds-c repository
  • Automotive firmware and diagnostic tools that link the vulnerable send_diagnostic_request implementation

Discovery Timeline

  • 2026-05-01 - CVE-2026-37536 published to NVD
  • 2026-05-07 - Last updated in NVD database

Technical Details for CVE-2026-37536

Vulnerability Analysis

The uds-c library implements UDS message construction for CAN-based diagnostics. The function send_diagnostic_request builds an outbound diagnostic message on a fixed-size stack buffer sized by the constant MAX_DIAGNOSTIC_PAYLOAD_SIZE, which is defined as 6 bytes. The function writes the service identifier at offset 0, an optional Parameter Identifier (PID) of up to 2 bytes starting at offset 1, and then copies the caller-supplied payload at offset 1 + pid_length using memcpy.

The library accepts a payload of up to MAX_UDS_REQUEST_PAYLOAD_LENGTH bytes, which is defined as 7. The maximum write therefore reaches 1 + 2 + 7 = 10 bytes, overflowing the 6-byte buffer by 4 bytes. The memcpy is performed without comparing payload_length against the remaining buffer space.

Depending on compiler-emitted stack layout, the overflow can corrupt adjacent local variables, saved registers, frame pointers, or the return address. On embedded targets without stack canaries or position-independent execution, this primitive is sufficient to redirect control flow.

Root Cause

The root cause is a missing bounds check before the memcpy call. The function trusts both pid_length and payload_length from the request structure without validating that 1 + pid_length + payload_length does not exceed MAX_DIAGNOSTIC_PAYLOAD_SIZE. The two compile-time constants MAX_DIAGNOSTIC_PAYLOAD_SIZE=6 and MAX_UDS_REQUEST_PAYLOAD_LENGTH=7 are inconsistent, guaranteeing overflow when callers use the documented maximum payload size.

Attack Vector

The attack vector is adjacent network. An attacker with access to the CAN bus, OBD-II port, or any logical channel that feeds UDS request structures into the library can supply a request with pid_length=2 and payload_length=7. This triggers the 4-byte stack overflow. The flaw requires no authentication and no user interaction. Successful exploitation impacts confidentiality, integrity, and availability of the diagnostic process and any privileges it holds on the embedded controller.

No public exploit code is available beyond the proof-of-concept gist referenced in the GitHub Gist PoC. Refer to the upstream miaofng/uds-c repository for the affected source.

Detection Methods for CVE-2026-37536

Indicators of Compromise

  • Unexpected crashes, resets, or watchdog reboots of Electronic Control Units (ECUs) shortly after receiving UDS diagnostic traffic.
  • CAN frames carrying UDS requests with payload lengths at or near 7 bytes combined with multi-byte PIDs.
  • Diagnostic sessions originating from unauthorized tools or unknown CAN node IDs.

Detection Strategies

  • Perform static analysis on firmware images to locate send_diagnostic_request builds derived from commit e506334e, focusing on the absence of a payload_length bounds check before memcpy.
  • Build the affected library with AddressSanitizer or stack canaries (-fstack-protector-strong) and fuzz send_diagnostic_request with malformed payload and PID lengths.
  • Deploy CAN intrusion detection that flags UDS requests violating service-specific length expectations defined in ISO 14229.

Monitoring Recommendations

  • Log all UDS request frames at gateway ECUs, including service ID, sub-function, PID length, and payload length, for offline anomaly review.
  • Alert on repeated UDS requests that result in ECU resets or NegativeResponse codes consistent with malformed input.
  • Monitor diagnostic tool authentication events and correlate them with bus-level UDS traffic to identify unauthorized sessions.

How to Mitigate CVE-2026-37536

Immediate Actions Required

  • Audit firmware and tooling for any link against miaofng/uds-c or its forks at or before commit e506334e270d77b20c0bc259ac6c7d8c9b702b7a.
  • Patch send_diagnostic_request to validate 1 + pid_length + payload_length <= MAX_DIAGNOSTIC_PAYLOAD_SIZE before invoking memcpy, and reject requests that exceed the limit.
  • Reconcile the library constants so MAX_UDS_REQUEST_PAYLOAD_LENGTH cannot exceed MAX_DIAGNOSTIC_PAYLOAD_SIZE - 1 - max_pid_length.
  • Restrict physical and logical access to CAN buses and OBD-II ports on production vehicles and test benches.

Patch Information

No official upstream patch is referenced in the NVD entry. Maintainers and integrators must apply a source-level fix to send_diagnostic_request that enforces a length check before the memcpy, and rebuild dependent firmware. Track the miaofng/uds-c and OpenXC uds-c repositories for upstream remediation.

Workarounds

  • Cap caller-supplied payload_length to MAX_DIAGNOSTIC_PAYLOAD_SIZE - 1 - pid_length in wrapper code that constructs UDS requests.
  • Compile the library with -fstack-protector-strong, -D_FORTIFY_SOURCE=2, and non-executable stack flags to reduce exploitability.
  • Enforce UDS message filtering at central gateway ECUs to drop frames whose advertised payload length exceeds the protocol-defined maximum for the requested service.
bash
# Configuration example: hardened build flags for integrators rebuilding uds-c
CFLAGS="-O2 -fstack-protector-strong -D_FORTIFY_SOURCE=2 -fPIE -Wformat -Wformat-security"
LDFLAGS="-Wl,-z,relro -Wl,-z,now -pie"
make CFLAGS="$CFLAGS" LDFLAGS="$LDFLAGS"

Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.

  • Vulnerability Details
  • TypeBuffer Overflow

  • Vendor/TechMitsubishi

  • SeverityHIGH

  • CVSS Score8.8

  • EPSS Probability0.02%

  • Known ExploitedNo
  • CVSS Vector
  • CVSS:3.1/AV:A/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
  • Impact Assessment
  • ConfidentialityLow
  • IntegrityNone
  • AvailabilityHigh
  • CWE References
  • CWE-121
  • Technical References
  • GitHub Gist PoC

  • GitHub Project Repository

  • GitHub OpenXC Repository
  • Related CVEs
  • CVE-2025-7405: MELSEC iQ-F Auth Bypass Vulnerability

  • CVE-2025-7731: MELSEC iQ-F Information Disclosure Flaw

  • CVE-2025-2399: Mitsubishi CNC Systems DoS Vulnerability

  • CVE-2026-1876: Mitsubishi MELSEC iQ-F FX5-ENET/IP DoS Flaw
Default Legacy - Prefooter | Experience the World’s Most Advanced Cybersecurity Platform

Experience the World’s Most Advanced Cybersecurity Platform

See how our intelligent, autonomous cybersecurity platform can protect your organization now and into the future.

Try SentinelOne
  • Get Started
  • Get a Demo
  • Product Tour
  • Why SentinelOne
  • Pricing & Packaging
  • FAQ
  • Contact
  • Contact Us
  • Customer Support
  • SentinelOne Status
  • Language
  • Platform
  • Singularity Platform
  • Singularity Endpoint
  • Singularity Cloud
  • Singularity AI-SIEM
  • Singularity Identity
  • Singularity Marketplace
  • Purple AI
  • Services
  • Wayfinder TDR
  • SentinelOne GO
  • Technical Account Management
  • Support Services
  • Verticals
  • Energy
  • Federal Government
  • Finance
  • Healthcare
  • Higher Education
  • K-12 Education
  • Manufacturing
  • Retail
  • State and Local Government
  • Cybersecurity for SMB
  • Resources
  • Blog
  • Labs
  • Case Studies
  • Videos
  • Product Tours
  • Events
  • Cybersecurity 101
  • eBooks
  • Webinars
  • Whitepapers
  • Press
  • News
  • Ransomware Anthology
  • Company
  • About Us
  • Our Customers
  • Careers
  • Partners
  • Legal & Compliance
  • Security & Compliance
  • Investor Relations
  • S Foundation
  • S Ventures

©2026 SentinelOne, All Rights Reserved.

Privacy Notice Terms of Use

English