nats-io/jwt not enforcing checking of Import token permissions
CVE-2021-3127GHSA-62mh-w5cv-p88c
What to do
Partial vendor fix. Follow the primary source's mitigation guidance and check back for a fix.
This page has no inventory attached, so it cannot say whether you are affected. A vendor fix is not proof that your deployment is fixed.
Affected packages
Go github.com/nats-io/jwt
- Affected
- <= 1.2.2
- Fixed in
- no fixed version recorded
Go github.com/nats-io/jwt/v2
- Affected
- < 2.0.1
- Fixed in
- 2.0.1
Sources
- GitHub Advisory Database and maintainer security advisories on GitHub
GitHub-reviewed advisory GHSA-62mh-w5cv-p88c lists affected ranges: Go github.com/nats-io/jwt/v2 >=0 =0 <=1.2.2
VerifiedObserved Structured GitHub Advisory Database record (type=reviewed) from the GitHub REST API.
Severity and exploitation
- Exploitation
- No confirmed exploitation recorded. Patch Next marks exploitation only from CISA KEV.
- CVSS
- not scored
- EPSS
- CVE-2021-3127: 1.45% estimated exploitation activity in the next 30 days; percentile 73.37 (FIRST EPSS, 2026-11-03). This is a model estimate, not proof of exploitation or customer exposure.
Source description
As published by the source; long descriptions are shortened.
(This advisory is canonically <https://advisories.nats.io/CVE/CVE-2021-3127.txt) Problem Description The NATS server provides for Subjects which are namespaced by Account; all Subjects are supposed to be private to an account, with an Export/Import system used to grant cross-account access to some Subjects. Some Exports are public, such that anyone can import the relevant subjects, and some Exports are private, such that the Import requires a token JWT to prove permission. The JWT library's validation of the bindings in the Import Token incorrectly warned on mismatches, instead of outright rejecting the token. As a result, any account can take an Import token used by any other account and re-use it for themselves because the binding to the importing account is not rejected, and use it to import any Subject from the Exporting account, not just the Subject referenced in the Import Token. The NATS account-server system treats account JWTs as semi-public information, such that an…
Dates and revisions
- Published by the source
- Last modified by the source
- Source last checked
- Revision 1 · created ·
Published from ghsa record GHSA-62mh-w5cv-p88c
Agent brief
Preview the exact text before you copy it. Commands are read-only suggestions; review them before running anything.
# Patch Next advisory brief: CVE-2021-3127 Advisory: nats-io/jwt not enforcing checking of Import token permissions IDs: CVE-2021-3127, GHSA-62mh-w5cv-p88c Record: https://patchnext.com/advisories/cve-2021-3127 (revision 1, source checked 26 Oct 2026, 15:04 UTC) Inventory: none attached. This brief comes from a public page and does not say whether any deployment is affected. Severity: Unrated Exploitation: no confirmed exploitation recorded. Patch Next confirms exploitation only from CISA KEV. Vendor response: Partial vendor fix; fixed versions by package: github.com/nats-io/jwt/v2 2.0.1. A vendor fix does not mean a deployment is fixed. ## Affected components - Go github.com/nats-io/jwt: affected <= 1.2.2 - Go github.com/nats-io/jwt/v2: affected < 2.0.1; fixed in 2.0.1 ## Suggested inspection (read-only) - Go github.com/nats-io/jwt: check the installed version with your package manager. - Go github.com/nats-io/jwt/v2: check the installed version with your package manager. ## Supported action No complete vendor fix is recorded. Follow the primary source's mitigation guidance and check this record again before closing anything. ## Required regression checks - Run the test suite and a production build. - Exercise the features that depend on github.com/nats-io/jwt, github.com/nats-io/jwt/v2. - Repeat the inspection and confirm that only fixed versions remain installed. ## Rollback considerations - Keep the previous lockfile and deployment artifact. Rolling back reinstates the vulnerable version, so apply any documented mitigation while you fix forward. ## Unresolved questions - Which deployments run an affected version? - Exploitation status can change. Check again before lowering the priority. - Mark the work resolved only after the fixed version is verified in production. ## Sources - Verified: https://github.com/advisories/GHSA-62mh-w5cv-p88c (GitHub-reviewed advisory GHSA-62mh-w5cv-p88c lists affected ranges: Go github.com/nats-io/jwt/v2 >=0 =0 <=1.2.2) Commands are suggestions: review each one before running it.
Loading voting…