GHSA-52jh-2xxh-pwh6

Suggest an improvement
Source
https://github.com/advisories/GHSA-52jh-2xxh-pwh6
Import Source
https://github.com/github/advisory-database/blob/main/advisories/github-reviewed/2026/03/GHSA-52jh-2xxh-pwh6/GHSA-52jh-2xxh-pwh6.json
JSON Data
https://api.osv.dev/v1/vulns/GHSA-52jh-2xxh-pwh6
Aliases
  • CVE-2026-29785
Downstream
Related
Published
2026-03-24T21:29:06Z
Modified
2026-03-25T19:59:16.170400Z
Severity
  • 7.5 (High) CVSS_V3 - CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H CVSS Calculator
Summary
NATS Server panic via malicious compression on leafnode port
Details

Background

NATS.io is a high performance open source pub-sub distributed communication technology, built for the cloud, on-premise, IoT, and edge computing.

When configured to accept leafnode connections (for a hub/spoke topology of multiple nats-servers), then the default configuration allows for negotiating compression; a malicious remote NATS server can trigger a server panic via that compression.

Problem Description

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).

Context: a NATS server can form various clustering topologies, including local clusters, and superclusters of clusters, but leafnodes allow for separate administrative domains to link together with limited data communication; eg, a server in a moving vehicle might use a local leafnode for agents to connect to, and sync up to a central service as and when available. The leafnode configuration here is where the central server allows other NATS servers to connect into it, almost like regular NATS clients. Documentation examples typically use port 7422 for leafnode communications.

Affected Versions

Version 2, prior to v2.11.14 or v2.12.5

Workarounds

Disable compression on the leafnode port:

leafnodes {
  port: 7422
  compression: off
}
Database specific
{
    "github_reviewed": true,
    "github_reviewed_at": "2026-03-24T21:29:06Z",
    "cwe_ids": [
        "CWE-476"
    ],
    "nvd_published_at": null,
    "severity": "HIGH"
}
References

Affected packages

Go / github.com/nats-io/nats-server/v2

Package

Name
github.com/nats-io/nats-server/v2
View open source insights on deps.dev
Purl
pkg:golang/github.com/nats-io/nats-server/v2

Affected ranges

Type
SEMVER
Events
Introduced
0Unknown introduced version / All previous versions are affected
Fixed
2.11.14

Database specific

source
"https://github.com/github/advisory-database/blob/main/advisories/github-reviewed/2026/03/GHSA-52jh-2xxh-pwh6/GHSA-52jh-2xxh-pwh6.json"

Go / github.com/nats-io/nats-server/v2

Package

Name
github.com/nats-io/nats-server/v2
View open source insights on deps.dev
Purl
pkg:golang/github.com/nats-io/nats-server/v2

Affected ranges

Type
SEMVER
Events
Introduced
2.12.0-RC.1
Fixed
2.12.5

Database specific

source
"https://github.com/github/advisory-database/blob/main/advisories/github-reviewed/2026/03/GHSA-52jh-2xxh-pwh6/GHSA-52jh-2xxh-pwh6.json"