Advisory

GHSA-w73w-5m7g-f7qc

Also known as: CVE-2020-26160, GO-2020-0017, SNYK-GOLANG-GITHUBCOMDGRIJALVAJWTGO-596515

Summary

Authorization bypass in github.com/dgrijalva/jwt-go

Details

jwt-go allows attackers to bypass intended access restrictions in situations with []string{} for m["aud"] (which is allowed by the specification). Because the type assertion fails, "" is the value of aud. This is a security problem if the JWT token is presented to a service that lacks its own audience check. There is no patch available and users of jwt-go are advised to migrate to golang-jwt at version 3.2.1

Severity

High Basis: The source's own band: HIGH

Dates

Published
2021-05-18 21:08 UTC
Modified
2026-09-10 03:49 UTC

Affected packages and fixes

github.com/dgrijalva/jwt-go

Go · All systems

Affected

  • introduced 0.0.0-20150717181359-44718f8a89b0, last affected 3.2.0 (semver)

Fixed versions

None listed

Fix

No fixed version is listed.

github.com/dgrijalva/jwt-go/v4

Go · All systems

Affected

  • introduced 0, fixed 4.0.0-preview1 (semver)

Fixed versions

4.0.0-preview1

Fix

Fix commands are the export's own generic commands. Ojuju never runs them. Check them against your setup first.

Check your own computer: guard packages check

View this record on OSV.dev

Source

Source: GitHub Advisory Database (reviewed advisories) · CC BY 4.0

Sources & licences