☠️
EXFILTRATING
DATA...
01010111 10110010 00101001 11000110 01101100 10011011 00010001 11100101 01000010 10101111
[ <-- BACK_TO_SEARCH ]

CVE-2025-1399

CVE-2025-1399 Out-of-Bounds Access in Libplctag
📅 PUBLISHED: 2025-05-07 07:04 UTC 🔄 UPDATED: 2026-09-23 20:36 UTC
[ PATCH UNDER REVIEW ↓ ] Remains UNDER REVIEW until an independent source confirms the fix
[ DEFENSE PATCH ↓ ]
💣 PoC: None
👁️
Proof of Concept - Indicates if functional exploit code is publicly available, drastically increasing the risk of immediate attacks.
🎯 EPSS: 0.23%
👁️
0.23% probability
5.8× above the median CVE
Tier: ELEVATED
30-day exploitation window · FIRST.org · updated daily
Country: USA License: Commercial
VULNERABLE: version not auto-detected — verify your deployed version locally
CVSS SEVERITY SCALE
9.0–10.0 CRITICAL
7.0–8.9 HIGH
4.0–6.9 MEDIUM
0.1–3.9 LOW
0.0 NONE
3.1
THREAT LEVEL
■ tracking this CVE ✓ independent patch confirmation ⧗ same-origin mirror (GHSA) ⚠ active exploitation verification policy →

Executive Summary

CVE-2025-1399 is a high-severity Out-of-bounds Read vulnerability in the unpack_response function within session.c of the libplctag library, affecting versions 2.0 through 2.6.3. This flaw allows an unauthenticated attacker to trigger an overread of network buffers, potentially leading to information disclosure. The vulnerability resides in the core parsing logic of the library, which is used to communicate with industrial PLCs over the network. While the CVSS score is low (3.1) due to high attack complexity and low impact on confidentiality, the nature of the library (industrial control systems) elevates the risk. No public exploit code or proof-of-concept is available, and the patch status remains unknown.

⚡ AUTOMATE YOUR CVE INTELLIGENCE

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.

›Patch confidence — UNVERIFIED to CONFIRMED, cross-referenced NVD + RHSA + Debian
›Exploit & PoC — poc_status, poc_url, has_exploit. Not in NVD.
›Shodan dorks — ready-made queries to find exposed vulnerable systems
›Detection rules — YARA · Wazuh · Elastic (all plans) · Sigma (Pro)
›pending_fields — know exactly which of 7 fields NVD hasn't processed yet
›Free backfill — data incomplete when you paid? Re-check within 30 days = 0 credits
PAYG €0.08/lookup Standard €19/mo (was €29) · 5k credits Pro €65/mo (was €99) · 20k credits FOUNDING PRICE · LOCKED FOR LIFE · ENDS 31 DEC 2026
[ FROM €19/MO ]
Free sandbox key available
No signup required

Supply Chain & Package Security

This vulnerability affects the libplctag library, which is distributed as a C library and is not part of the NPM, PyPI, Go, or Ruby ecosystems. However, it may be included as a dependency in various industrial automation projects. Users should verify if their projects directly or indirectly depend on libplctag and assess the risk accordingly.

CVSS Breakdown & Threat Level

  • CVSS Score: 3.1 (Low)
  • Vector: CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:L/I:N/A:N
  • Attack Vector (AV): Network (N) – The vulnerability can be exploited remotely.
  • Attack Complexity (AC): High (H) – Exploitation requires specific conditions or knowledge of the target.
  • Privileges Required (PR): None (N) – No authentication needed.
  • User Interaction (UI): None (N) – No user action required.
  • Scope (S): Unchanged (U) – The exploit cannot affect other components.
  • Confidentiality (C): Low (L) – Limited information disclosure possible.
  • Integrity (I): None (N) – No data modification.
  • Availability (A): None (N) – No denial of service.

Threat Level: Low. The high attack complexity and low impact make this vulnerability less likely to be exploited in the wild. However, in an industrial control system (ICS) environment, even limited information disclosure can be dangerous.

Deep Dive & Mechanics

The vulnerability exists in the unpack_response function in session.c. This function is responsible for parsing responses from PLCs. The flaw is an out-of-bounds read, meaning the code reads data from a buffer beyond its allocated size. This can occur when a malicious or malformed network packet is sent to the library, causing it to read memory that it should not access.

The root cause is likely a missing or incorrect bounds check on the length of a field within the response packet. When the library attempts to unpack the response, it trusts the length value provided in the packet without verifying it against the actual buffer size. This allows an attacker to craft a packet with a manipulated length field, causing the library to read beyond the buffer and potentially leak sensitive data from the process's memory.

Vulnerable vs. Patched Code

Since no patch is available, a direct comparison is not possible. However, the vulnerable code pattern can be described:

Vulnerable Code (Conceptual):

void unpack_response(uint8_t *buffer, size_t buffer_len) {
    uint16_t data_len = *(uint16_t *)(buffer + 2); // No bounds check
    // ... read data_len bytes from buffer
    memcpy(dest, buffer + 4, data_len); // Potential overread
}

Patched Code (Expected):

void unpack_response(uint8_t *buffer, size_t buffer_len) {
    if (buffer_len < 4) return; // Minimum size check
    uint16_t data_len = *(uint16_t *)(buffer + 2);
    if (data_len > buffer_len - 4) return; // Bounds check
    // ... read data_len bytes from buffer
    memcpy(dest, buffer + 4, data_len);
}

The patched version adds a check to ensure data_len does not exceed the remaining buffer size.

Exploitation & Lab Setup

Red Team

No public exploit code is available. To develop a proof-of-concept, an attacker would need to:

  1. Setup: Install libplctag version 2.6.3 on a test system.
  2. Craft Packet: Create a malformed CIP (Common Industrial Protocol) response packet with an oversized length field.
  3. Send Packet: Use a tool like Scapy or a custom Python script to send the packet to a service using libplctag.
  4. Observe: Monitor the application for crashes or unexpected memory reads.

Example Python script (conceptual):

import socket

# Craft a malformed packet
packet = b'\x00\x01'  # Header
packet += b'\xff\xff'  # Oversized length (65535)
packet += b'A' * 10    # Payload

sock = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
sock.connect(('target_ip', 44818))
sock.send(packet)
response = sock.recv(1024)
sock.close()

Blue Team

To detect exploitation attempts:

  1. Network Monitoring: Monitor for anomalous CIP packets with unusually large length fields.
  2. Application Logging: Enable debug logging in libplctag to capture parsing errors.
  3. Memory Protection: Use Address Space Layout Randomization (ASLR) and Data Execution Prevention (DEP) to mitigate impact.
  4. IDS/IPS: Deploy signatures to detect malformed CIP packets.

Indicators of Compromise (IOCs)

  • Network IOCs:
    • CIP packets with length fields exceeding 1024 bytes.
    • Packets targeting port 44818 (EtherNet/IP) with malformed structure.
  • Host IOCs:
    • Application crashes in unpack_response function.
    • Memory dumps containing unexpected data.
    • Log entries indicating buffer overread errors.

Detection Engineering

YARA Rule

rule CVE_2025_1399_libplctag_overread {
    meta:
        description = "Detects potential exploitation of CVE-2025-1399 in libplctag"
        author = "Valters IT"
        date = "2025-04-10"
        reference = "CVE-2025-1399"
    strings:
        $s1 = "unpack_response" ascii wide nocase
        $s2 = "session.c" ascii wide nocase
    condition:
        $s1 and $s2
}

Sigma Rule

title: CVE-2025-1399 - libplctag Out-of-bounds Read
id: 12345678-1234-1234-1234-123456789012
status: experimental
description: Detects network traffic attempting to exploit CVE-2025-1399
author: Valters IT
date: 2025-04-10
logsource:
    category: network
    product: suricata
detection:
    selection:
        - dest_port: 44818
        - payload_length: ">1024"
    condition: selection
falsepositives:
    - Legitimate large CIP packets
level: medium

Suricata Rule

alert tcp any any -> any 44818 (msg:"CVE-2025-1399 - libplctag Out-of-bounds Read Attempt"; flow:to_server; content:"|00 00 00 00|"; depth:4; byte_test:2,>,1024,2; sid:1000001; rev:1;)

Remediation & Mitigation

  1. Immediate Actions:
    • Monitor the libplctag project for a patch.
    • Restrict network access to services using libplctag to trusted hosts only.
    • Use a Web Application Firewall (WAF) or IDS to filter malformed packets.
  2. Long-term Fix:
    • Apply the official patch once released.
    • Update to a patched version of libplctag.
    • Conduct a code review of the unpack_response function to ensure proper bounds checking.
  3. Compensating Controls:
    • Implement network segmentation for ICS devices.
    • Use application-level input validation.
    • Enable ASLR and DEP on all systems.

Valters IT
DevSecOps & Cyber Threat Intelligence Expert

◈ SOURCE Analysis & enrichment: valtersit.com/cve/CVE-2025-1399/ · CVE data: NVD/MITRE (public domain) · © 2026 ValtersIT Hub
>_ SYSTEM_CORE: INTEL_ACTIVE
90% TEAM-CURATED // 10% AUTOMATED INGESTION.
ALL PATCH REFERENCES AND VERSION DATA SOURCED FROM NVD + OSV OFFICIAL REGISTRIES.