GHSA-HMM9-R2M2-QG9W

GHSA-HMM9-R2M2-QG9W is a high-severity null pointer dereference vulnerability in github.com/nats-io/nats-server/v2 (go), affecting versions < 2.1.9. It is fixed in 2.1.9.

Summary

(This advisory is canonically https://advisories.nats.io/CVE/CVE-2020-26521.txt)

Problem Description

The NATS account system has an Operator trusted by the servers, which signs Accounts, and each Account can then create and sign Users within their account. The Operator should be able to safely issue Accounts to other entities which it does not fully trust.

A malicious Account could create and sign a User JWT with a state not created by the normal tooling, such that decoding by the NATS JWT library (written in Go) would attempt a nil dereference, aborting execution.

The NATS Server is known to be impacted by this.

Affected versions

JWT library

  • all versions prior to 1.1.0

NATS Server

  • Version 2 prior to 2.1.9

JWT library

  • Programs would nil dereference and panic, aborting execution by default.

NATS server

  • Denial of Service caused by process termination

Workaround

If your NATS servers do not trust any accounts which are managed by untrusted entities, then malformed User credentials are unlikely to be encountered.

Impact

The application dereferences a null pointer, causing a crash. Typical impact: denial of service via crash.

GHSA-HMM9-R2M2-QG9W has a CVSS score of 7.5 (High). The vector is network-reachable, no privileges required, and no user interaction. A CVSS score reflects the worst-case severity of the vulnerability, not your specific exposure. Whether this affects your application depends on whether the vulnerable code is present and reachable in your environment. A fixed version is available (2.1.9); upgrading removes the vulnerable code path.

Affected versions

github.com/nats-io/nats-server/v2 (< 2.1.9)

Security releases

github.com/nats-io/nats-server/v2 → 2.1.9 (go)

Kodem intelligence

Severity tells you how bad this could be in the worst case. It does not tell you whether you are exposed. Exploitability and impact are functions of runtime truth: whether the vulnerable code is present, reachable, and actually executes in your application. A vulnerable package can sit in your dependency tree and never run.

Kodem, an Intelligent Application Security platform, uses runtime intelligence to reveal which vulnerabilities actually execute in production, so teams prioritize the ones that genuinely matter. Kodem's runtime-powered SCA identifies whether this CVE is reachable in your applications.

See it in your environment

Remediation advice

Upgrade the JWT dependency in any application using it.

Upgrade the NATS server if using NATS Accounts.

Frequently Asked Questions

  1. What is GHSA-HMM9-R2M2-QG9W? GHSA-HMM9-R2M2-QG9W is a high-severity null pointer dereference vulnerability in github.com/nats-io/nats-server/v2 (go), affecting versions < 2.1.9. It is fixed in 2.1.9. The application dereferences a null pointer, causing a crash.
  2. How severe is GHSA-HMM9-R2M2-QG9W? GHSA-HMM9-R2M2-QG9W has a CVSS score of 7.5 (High). This score reflects the worst-case severity of the vulnerability, not your specific exposure. Whether it represents real risk in your environment depends on whether the vulnerable code is present and reachable.
  3. Which versions of github.com/nats-io/nats-server/v2 are affected by GHSA-HMM9-R2M2-QG9W? github.com/nats-io/nats-server/v2 (go) versions < 2.1.9 is affected.
  4. Is there a fix for GHSA-HMM9-R2M2-QG9W? Yes. GHSA-HMM9-R2M2-QG9W is fixed in 2.1.9. Upgrade to this version or later.
  5. Is GHSA-HMM9-R2M2-QG9W exploitable, and should I be worried? Whether GHSA-HMM9-R2M2-QG9W is exploitable in your environment depends on whether the vulnerable code is present and reachable. A CVSS score is a worst-case rating; it does not account for your specific deployment, configuration, or usage patterns. Kodem, an Intelligent Application Security platform, uses runtime intelligence to show which vulnerabilities actually execute in production, so you can focus on the ones that represent real risk. Get a demo
  6. What actually determines whether GHSA-HMM9-R2M2-QG9W is exploitable, and how bad it is? Exploitability and impact are not fixed properties of a CVE. They depend on runtime truth: whether the vulnerable code is present, reachable, and actually executes in your application. A high CVSS score on a dependency that never runs is not the same as real risk. Kodem, an Intelligent Application Security platform, uses runtime intelligence to reveal which vulnerabilities actually execute in production, so teams prioritize the ones that genuinely matter.
  7. How do I fix GHSA-HMM9-R2M2-QG9W? Upgrade github.com/nats-io/nats-server/v2 to 2.1.9 or later.

Other vulnerabilities in github.com/nats-io/nats-server/v2

CVE-2026-27889CVE-2026-33248CVE-2026-33246CVE-2026-33223CVE-2026-33222

Stop the waste.
Protect your environment with Kodem.