{"id":"CVE-2026-58213","aliases":["CVE-2026-58213","GHSA-qrcv-3558-gj4f","BIT-NATS-2026-58213","GO-2026-7000"],"related":[],"kind":"vulnerability","state":"published","title":"NATS Server: MQTT SUBSCRIBE Protocol Injection via Leaf Node/Route Forwarding allows arbitrary NATS command injection","summary":"NATS Server is a high-performance server for NATS.io, the cloud and edge native messaging system. Prior to 2.14.1 and 2.12.9, an MQTT client could include protocol control characters in subscription filters that were later forwarded as NATS protocol data to route or leafnode connections, corrupting the forwarded protocol stream and allowing injection of unintended NATS protocol operations. This issue is fixed in versions 2.14.1 and 2.12.9.","summarySource":"cvelist","descriptions":[{"lang":"en","text":"NATS Server is a high-performance server for NATS.io, the cloud and edge native messaging system. Prior to 2.14.1 and 2.12.9, an MQTT client could include protocol control characters in subscription filters that were later forwarded as NATS protocol data to route or leafnode connections, corrupting the forwarded protocol stream and allowing injection of unintended NATS protocol operations. This issue is fixed in versions 2.14.1 and 2.12.9.","source":"cvelist"},{"lang":"en","text":"### 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\nThe NATS Server supports MQTT clients and can bridge MQTT activity into NATS subjects across routes and leafnode connections.\n\n### Problem Description\n\nAn MQTT client could include protocol control characters in subscription filters that were later forwarded as NATS protocol data to route or leafnode connections.\n\nThis could corrupt the forwarded protocol stream and allow injection of unintended NATS protocol operations, potentially across cluster nodes or accounts where route or gateway connections are present.\n\nAnonymous MQTT deployments are higher risk because no credentials are required to reach the affected parser. Authenticated deployments are still affected for clients allowed to create MQTT subscriptions.\n\n### Affected Versions\n\nVersions v2.14.0, v2.12.8 and below are vulnerable. The issue is fixed in v2.14.1 and v2.12.9.\n\n### Workarounds\n\nDisable anonymous MQTT access where it is not required. Deployments that need MQTT have no known complete workaround other than upgrading.\n\n### References\n\n * GHSA advisory: <https://github.com/nats-io/nats-server/security/advisories/GHSA-qrcv-3558-gj4f>\n * Credit: @thesecguy45","format":"markdown","source":"ghsa"},{"lang":"en","text":"NATS Server: MQTT SUBSCRIBE Protocol Injection via Leaf Node/Route Forwarding allows arbitrary NATS command injection in github.com/nats-io/nats-server/v2","format":"markdown","source":"go"},{"lang":"es","text":"NATS Server es un servidor de alto rendimiento para NATS.io, el sistema de mensajería nativo de la nube y del borde. Antes de 2.14.1 y 2.12.9, un cliente MQTT podía incluir caracteres de control de protocolo en filtros de suscripción que luego eran reenviados como datos del protocolo NATS a conexiones de ruta o de nodo hoja, corrompiendo el flujo del protocolo reenviado y permitiendo la inyección de operaciones de protocolo NATS no intencionadas. Este problema está solucionado en las versiones 2.14.1 y 2.12.9.","source":"nvd"}],"published":"2026-07-08T19:52:12.148Z","modified":"2026-11-23T20:41:34.329Z","severity":{"scorer":"GitHub_M","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:L/A:N","score":7.1,"rating":"HIGH"},"severities":[{"scorer":"GitHub_M","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:L/A:N","score":7.1,"rating":"HIGH"},{"scorer":"GitHub","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:L/A:N","score":7.1,"rating":"HIGH"},{"scorer":"Bitnami Vulnerability Database","scheme":"rating","rating":"HIGH"}],"cwes":["CWE-74"],"affected":[{"ranges":[{"version":"< 2.12.9","status":"affected"},{"version":">= 2.14.0-RC.1, < 2.14.1","status":"affected"}],"vendor":"nats-io","product":"nats-server","source":"cvelist"},{"ranges":[{"type":"semver","introduced":"0","status":"affected","fixed":"2.12.9"}],"ecosystem":"Go","package":"github.com/nats-io/nats-server/v2","purl":"pkg:golang/github.com/nats-io/nats-server/v2","source":"ghsa"},{"ranges":[{"type":"semver","introduced":"2.14.0-RC.1","status":"affected","fixed":"2.14.1"}],"ecosystem":"Go","package":"github.com/nats-io/nats-server/v2","purl":"pkg:golang/github.com/nats-io/nats-server/v2","source":"ghsa"},{"ranges":[{"type":"semver","introduced":"0","status":"affected","fixed":"2.12.9"},{"type":"semver","introduced":"2.14.0-RC.1","status":"affected","fixed":"2.14.1"}],"ecosystem":"Go","package":"github.com/nats-io/nats-server/v2","purl":"pkg:golang/github.com/nats-io/nats-server/v2","source":"go"},{"ranges":[{"status":"affected","fixed":"2.12.9"},{"status":"affected","introduced":"2.14.0","fixed":"2.14.1"}],"vendor":"linuxfoundation","product":"nats-server","cpe":"cpe:2.3:a:linuxfoundation:nats-server:*:*:*:*:*:*:*:*","source":"nvd"},{"ranges":[{"type":"semver","introduced":"0","status":"affected","fixed":"2.12.9"},{"type":"semver","introduced":"2.14.0","status":"affected","fixed":"2.14.1"}],"ecosystem":"Bitnami","package":"nats","purl":"pkg:bitnami/nats","source":"bitnami"}],"references":[{"url":"https://github.com/nats-io/nats-server/security/advisories/GHSA-qrcv-3558-gj4f","tags":["advisory","vendor-advisory","web","x-refsource-confirm"],"sources":["cvelist","ghsa","go","nvd","bitnami"]},{"url":"https://github.com/nats-io/nats-server/pull/8163","tags":["fix","issue-tracking","patch","web","x-refsource-misc"],"sources":["cvelist","ghsa","go","nvd","bitnami"]},{"url":"https://github.com/nats-io/nats-server/pull/8164","tags":["fix","issue-tracking","patch","web","x-refsource-misc"],"sources":["cvelist","ghsa","go","nvd","bitnami"]},{"url":"https://github.com/nats-io/nats-server/commit/366837cfc65ab9ccb4f98193c65e8daf238582d8","tags":["fix","patch","web","x-refsource-misc"],"sources":["cvelist","ghsa","go","nvd","bitnami"]},{"url":"https://github.com/nats-io/nats-server/commit/64ebae40051ee497c481e10f316238faf0de1736","tags":["fix","patch","web","x-refsource-misc"],"sources":["cvelist","ghsa","go","nvd","bitnami"]},{"url":"https://github.com/nats-io/nats-server/commit/f14856b9e57a36818f43851cb69b6e33670885c9","tags":["fix","patch","web","x-refsource-misc"],"sources":["cvelist","ghsa","go","nvd","bitnami"]},{"url":"https://github.com/nats-io/nats-server/releases/tag/v2.12.9","tags":["article","release-notes","web","x-refsource-misc"],"sources":["cvelist","ghsa","go","nvd","bitnami"]},{"url":"https://github.com/nats-io/nats-server/releases/tag/v2.14.1","tags":["article","release-notes","web","x-refsource-misc"],"sources":["cvelist","ghsa","go","nvd","bitnami"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2026-58213","tags":["advisory","web"],"sources":["ghsa","go","bitnami"]},{"url":"https://github.com/nats-io/nats-server","tags":["package"],"sources":["ghsa"]}],"credits":[],"assigner":"GitHub_M","ssvc":{"scorer":"CISA-ADP","exploitation":"none","automatable":"no","technicalImpact":"partial","date":"2026-07-09T13:32:57.416Z"},"sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2026-58213","url":"https://www.cve.org/CVERecord?id=CVE-2026-58213","licence":"CVE Terms of Use","modified":"2026-07-09T13:33:07.155Z"},{"source":"ghsa","name":"GitHub Advisory Database","id":"GHSA-qrcv-3558-gj4f","url":"https://github.com/advisories/GHSA-qrcv-3558-gj4f","licence":"CC-BY-4.0","modified":"2026-11-23T20:41:34.329Z"},{"source":"go","name":"Go Vulnerability Database","id":"GO-2026-7000","url":"https://pkg.go.dev/vuln/GO-2026-7000","licence":"CC-BY-4.0","modified":"2026-11-23T20:41:34.329Z"},{"source":"nvd","name":"NVD","id":"CVE-2026-58213","url":"https://nvd.nist.gov/vuln/detail/CVE-2026-58213","licence":"Public domain","modified":"2026-10-25T17:10:00.197Z"},{"source":"bitnami","name":"Bitnami Vulnerability Database","id":"BIT-NATS-2026-58213","url":"https://osv.dev/vulnerability/BIT-NATS-2026-58213","licence":"Apache-2.0","modified":"2026-11-23T20:41:34.329Z"}],"updatedAt":"2026-11-25T22:59:27.416Z","epss":{"score":0.00324,"percentile":0.27407,"date":"2026-12-01T12:00:22.000Z"}}