CVE-2026-13214: Stack buffer overflow in OCPP GetConfiguration key parsing
The OCPP 1.6 client in subsys/net/lib/ocpp/ocpp_j.c contains a stack buffer overflow in parse_getconfig_msg(). When handling a GetConfiguration request from the central system, the handler copied the attacker-controlled JSON "key" string into the caller's fixed 50-byte stack buffer (skey[CISTR50], declared in subsys/net/lib/ocpp/ocpp.c) using an unbounded strcpy(). The parsed key value points directly into the receive buffer, so its length is bounded only by the message size (CONFIG_OCPP_RECV_BUFFER_SIZE, default 2048).
The GetConfiguration message is delivered over the WebSocket connection that the charge point opens to its configured central system. The reader thread ocpp_wsreader() reads the message into ui->recv_buf and dispatches it to parse_getconfig_msg() via the PDU function table. An attacker who controls the central system endpoint, or a man-in-the-middle on an unencrypted connection, can send a GetConfiguration request whose "key" field exceeds 50 bytes and overflow the reader thread's stack with attacker-chosen bytes.
The consequence is a remotely triggerable stack smash on the OCPP reader thread: at minimum a denial of service, and plausibly remote code execution depending on build-time hardening such as stack canaries and MPU configuration. The fix replaces the strcpy() with a bounded strncpy(key, payload.key[0], CISTR50 - 1) followed by explicit NUL termination, matching the bounded copies already used by the sibling handlers.
Security readout for executives and security teams
Plain-English summary
A malicious or compromised charging-management server can send an oversized configuration key to a charge point using Zephyr’s OCPP 1.6 client. This can corrupt memory and crash the device; code execution is considered plausible but is not confirmed and depends on device hardening.
Executive priority
Treat as an urgent firmware remediation for internet-connected or operationally critical charge points using the affected client. Prioritize devices connecting over unencrypted networks or to central systems with weaker administrative controls. A crash could disrupt charging operations, while the worst-case confidentiality and integrity impact depends on whether device protections prevent code execution.
Technical view
In Zephyr 4.3.0, parse_getconfig_msg() uses unbounded strcpy() to copy an attacker-controlled JSON key into a 50-byte stack buffer. The key can approach the configured receive-buffer size, 2048 bytes by default. The resulting stack overflow affects the OCPP WebSocket reader thread. The published fix bounds the copy and explicitly terminates the string.
Likely exposure
Exposure is limited to Zephyr 4.3.0 deployments using the affected OCPP 1.6 client and processing GetConfiguration messages. The charge point initiates the WebSocket connection, so the practical threat is a malicious or compromised configured central system, or interception where transport is unencrypted. Other versions or products are not established as affected by this bundle.
Exploitation context
No active exploitation is established: the bundle states that this CVE is not in KEV and provides no cited exploitation report. Triggering requires delivery of a crafted GetConfiguration message through the OCPP connection. Denial of service is the minimum expected impact; remote code execution remains plausible rather than demonstrated.
Researcher notes
The vulnerable destination is skey[CISTR50] in ocpp.c, while parsing occurs in ocpp_j.c. Attacker-controlled data originates in the receive buffer and is bounded primarily by CONFIG_OCPP_RECV_BUFFER_SIZE. Researchers should evaluate compiler canaries, MPU configuration, thread-stack layout, and restart behavior when assessing impact. The supplied evidence does not demonstrate reliable code execution or identify exploitation in the wild.
Mitigation direction
Apply a Zephyr release containing fix commit afbf880b04188ae53451a0ade4ac62b654fdff34.
If immediate upgrading is unavailable, backport the published bounded-copy fix and explicit NUL termination.
Require encrypted, authenticated OCPP WebSocket connections to reduce central-system impersonation and interception risk.
Restrict charge points to trusted central-system endpoints and investigate unauthorized configuration changes.
Validation and detection
Inventory charge-point firmware using Zephyr 4.3.0 and the OCPP 1.6 client.
Confirm the deployed source includes the published bounded copy and explicit string termination.
Verify OCPP connections use encryption, authenticate the central system, and reject untrusted endpoints.
Review device telemetry for reader-thread crashes or resets associated with GetConfiguration processing.
Test the remediation safely with oversized keys in an isolated, authorized environment and confirm stable rejection or truncation.
Generated from the cited source records. This long-tail analysis has not been individually reviewed by a named human.
Potential ATT&CK relevance
Conservative CVE-to-ATT&CK context
These mappings and lookup hints may be relevant to the vulnerability behavior, CWE, affected product, or exposure path. Glexia-inferred context is not an official MITRE, ATT&CK, CWE, or CVE Program mapping.
ATT&CK lookup starting points
Use these exact CWE pages and searches to review the Glexia ATT&CK library from this CVE's weakness and description context.
cwe · low confidence lookup
CWE-787: Exact CWE lookup
Use the exact CWE identifier as the starting point before reviewing related ATT&CK behavior. Open the exact CWE lookup page first, then review the ATT&CK searches from that MITRE weakness context. This is a Glexia lookup hint, not an official ATT&CK mapping.
The CVE wording references code or command execution, so execution technique review may help defensive triage. This is a Glexia inferred lookup path, not an official MITRE, ATT&CK, or CVE Program mapping.
These fields come from the CVE record and ADP containers, not from Glexia's Take. They preserve time-varying source decisions such as CISA SSVC, KEV status, CVSS metrics, and provider references.
1CVSS vectors
3Timeline events
1ADP providers
3Source links
SSVC decision data
CISA-ADPCISA Coordinator
Timestamp
Version
2.0.3
Exploitation: noneAutomatable: yesTechnical Impact: total
CVSS vector scores
1 official score
We collect every scored CVSS vector available in the official CNA and ADP containers. When more than one version is present, the table keeps the source vectors side by side instead of collapsing them into the highest score.
CWE links open Glexia weakness intelligence pages with official CWE context, developer remediation guidance, and related CVE mappings.
CWE-787 · source CWE mapping
Out-of-bounds Write
Out-of-bounds Write represents a recurring weakness pattern that can create exploitable paths when design, validation, or implementation controls are missing.