CVE-2026-33248: Github.com/nats io/nats server/v2 Authentication Bypass Vulnerability

MODERATE
Advisory Identifier: GHSA-3f24-pcvm-5jqc
CVSS 4.2
CWE-287 CWE-295
Published
Advisory Summary

CVE-2026-33248 is a MODERATE (CVSS 4.2) authentication bypass vulnerability (CWE-287: Improper Authentication) affecting Github.com/nats io/nats server/v2 libraries in the Go ecosystem. The issue involves nats has mtls verify_and_map authentication bypass via incorrect subject dn matching. Remediation is available by upgrading affected packages to version 2.11.15, 2.12.6.

CVE-2026-33248 at a Glance

CVE Identifier CVE-2026-33248
GHSA Identifier GHSA-3f24-pcvm-5jqc
Severity MODERATE
CVSS v3.1 Base Score 4.2
CWE Classification CWE-287: Improper Authentication
Affected Product Github.com/nats io/nats server/v2
Package Ecosystem Go
Published Date
Last Updated

Security Impact

CVSS: 4.2

The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:U/C:L/I:L/A:N).

Attack Vector Network (AV:N)
Attack Complexity High (AC:H)
Privileges Required Low (PR:L)
User Interaction None (UI:N)
Scope Unchanged (S:U)
Confidentiality Low (C:L)
Integrity Low (I:L)
Availability None (A:N)

How to Fix CVE-2026-33248

To remediate this vulnerability, upgrade all affected Github.com/nats io/nats server/v2 dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.

github.com/nats-io/nats-server/v2 fixed: 2.11.15
Upgrade github.com/nats-io/nats-server/v2 to 2.11.15
github.com/nats-io/nats-server/v2 fixed: 2.12.6
Upgrade github.com/nats-io/nats-server/v2 to 2.12.6
github.com/nats-io/nats-server fixed: Latest secure release
Upgrade github.com/nats-io/nats-server to Latest secure release
Verify Direct and Transitive Dependencies

Run the following command in your project directory to verify that all resolved dependencies use the patched release:

inspect dependencies for github.com/nats-io/nats-server/v2

How to Check if You Are Affected

To determine whether your application is affected by CVE-2026-33248, inspect your project dependencies for Github.com/nats io/nats server/v2:

inspect dependencies for github.com/nats-io/nats-server/v2

Analyze the terminal output to locate any version of Github.com/nats io/nats server/v2 in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 2.11.15), your application is affected.

Note: Verify declared build manifests and deployed runtime container environments.

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under CWE-287: Improper Authentication, where when an actor claims to have a given identity, the product does not prove or insufficiently proves that the claim is correct. In Github.com/nats io/nats server/v2, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.

Source Advisory Statement

### Background NATS.io is a high performance open source pub-sub distributed communication technology, built for the cloud, on-premise, IoT, and edge computing. One authentication model supported is mTLS, deriving the NATS client identity from properties of the TLS Client Certificate. ### Problem Description When using mTLS for client identity, with `verify_and_map` to derive a NATS identity from the client certificate's Subject DN, certain patterns of RDN would not be correctly enforced, allowing for authentication bypass. This does require a valid certificate from a CA already trusted for client certificates, and `DN` naming patterns which the NATS maintainers consider highly unlikely. So this is an unlikely attack. Nonetheless, administrators who have been very sophisticated in their `DN` construction patterns might conceivably be impacted. ### Affected Versions Fixed in nats-server 2.12.6 & 2.11.15 ### Workarounds Developers should review their CA issuing practices.

CVE-2026-33248 Affected Github.com/nats io/nats server/v2 Versions

3 component(s)
Fixed Versions:
2.11.152.12.6
Product / Package Ecosystem Affected Versions Fixed Version
github.com/nats-io/nats-server/v2
Go
< 2.11.15
2.11.15
github.com/nats-io/nats-server/v2
Go
≥ 2.12.0-RC.1
< 2.12.6
2.12.6
github.com/nats-io/nats-server
Go

References

Frequently Asked Questions

What is CVE-2026-33248?
CVE-2026-33248 is a security vulnerability in Github.com/nats io/nats server/v2 involving NATS has mTLS verify_and_map authentication bypass via incorrect Subject DN matching under CWE-287: Improper Authentication.
Which Github.com/nats io/nats server/v2 versions are affected?
Affected versions include releases prior to 2.11.15, 2.12.6 across affected packages: github.com/nats-io/nats-server/v2, github.com/nats-io/nats-server.
What version fixes CVE-2026-33248?
Upgrading to 2.11.15, 2.12.6 (or the latest patched release for your respective branch) resolves the vulnerability.
Is github.com/nats-io/nats-server/v2 affected?
Yes, github.com/nats-io/nats-server/v2 is affected in releases prior to 2.11.15, 2.12.6. Upgrade your dependency to 2.11.15, 2.12.6 or later.
Is github.com/nats-io/nats-server affected?
Yes, github.com/nats-io/nats-server is affected in releases prior to Latest secure release. Upgrade your dependency to Latest secure release or later.
What is the CVSS score of CVE-2026-33248?
CVE-2026-33248 has a CVSS v3.1 base score of 4.2 (MODERATE) with vector string CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:U/C:L/I:L/A:N.
What CWE is associated with CVE-2026-33248?
CVE-2026-33248 is classified under CWE-287: Improper Authentication (When an actor claims to have a given identity, the product does not prove or insufficiently proves that the claim is correct.).
How can I check Go dependencies for CVE-2026-33248?
Run the dependency tree command: 'inspect dependencies for github.com/nats-io/nats-server/v2'. This command lists direct and transitive dependencies in your build configuration so you can verify if a vulnerable version is resolved.
Machine-readable OSV JSON OSV v1.5 Schema
Normalized schema output
{
  "schema_version" : "1.4.0",
  "id" : "GHSA-3f24-pcvm-5jqc",
  "modified" : "2026-03-27T22:10:38Z",
  "published" : "2026-03-24T21:51:08Z",
  "aliases" : [ "CVE-2026-33248" ],
  "summary" : "NATS has mTLS verify_and_map authentication bypass via incorrect Subject DN matching",
  "details" : "### Background\n\nNATS.io is a high performance open source pub-sub distributed communication technology, built for the cloud, on-premise, IoT, and edge computing.\n\nOne authentication model supported is mTLS, deriving the NATS client identity from properties of the TLS Client Certificate.\n\n### Problem Description\n\nWhen using mTLS for client identity, with `verify_and_map` to derive a NATS identity from the client certificate's Subject DN, certain patterns of RDN would not be correctly enforced, allowing for authentication bypass.\n\nThis does require a valid certificate from a CA already trusted for client certificates, and `DN` naming patterns which the NATS maintainers consider highly unlikely.\n\nSo this is an unlikely attack. Nonetheless, administrators who have been very sophisticated in their `DN` construction patterns might conceivably be impacted.\n\n### Affected Versions\n\nFixed in nats-server 2.12.6 & 2.11.15\n\n### Workarounds\n\nDevelopers should review their CA issuing practices.",
  "severity" : [ {
    "type" : "CVSS_V3",
    "score" : "CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:U/C:L/I:L/A:N"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "Go",
      "name" : "github.com/nats-io/nats-server/v2"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "2.11.15"
      } ]
    } ]
  }, {
    "package" : {
      "ecosystem" : "Go",
      "name" : "github.com/nats-io/nats-server/v2"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "2.12.0-RC.1"
      }, {
        "fixed" : "2.12.6"
      } ]
    } ]
  }, {
    "package" : {
      "ecosystem" : "Go",
      "name" : "github.com/nats-io/nats-server"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "WEB",
    "url" : "https://github.com/nats-io/nats-server/security/advisories/GHSA-3f24-pcvm-5jqc"
  }, {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2026-33248"
  }, {
    "type" : "WEB",
    "url" : "https://advisories.nats.io/CVE/secnote-2026-13.txt"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/nats-io/nats-server"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-287", "CWE-295" ],
    "severity" : "MODERATE",
    "github_reviewed" : true,
    "github_reviewed_at" : "2026-03-24T21:51:08Z",
    "nvd_published_at" : "2026-03-25T21:16:47Z"
  }
}