{"id":"CVE-2025-30204","state":"PUBLISHED","title":"jwt-go allows excessive memory allocation during header parsing","description":"golang-jwt is a Go implementation of JSON Web Tokens. Starting in version 3.2.0 and prior to versions 5.2.2 and 4.5.2, the function parse.ParseUnverified splits (via a call to strings.Split) its argument (which is untrusted data) on periods. As a result, in the face of a malicious request whose Authorization header consists of Bearer  followed by many period characters, a call to that function incurs allocations to the tune of O(n) bytes (where n stands for the length of the function's argument), with a constant factor of about 16. This issue is fixed in 5.2.2 and 4.5.2.","publishedAt":"2025-03-21T21:42:01.382Z","updatedAt":"2025-04-10T13:03:19.897Z","severity":{"score":7.5,"label":"High","version":"3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H","source":"GitHub_M"},"assigner":"GitHub_M","products":["golang-jwt jwt"],"affected":[{"vendor":"golang-jwt","product":"jwt","versions":[{"version":">= 3.2.0, < 4.5.2","status":"affected"},{"version":">= 5.0.0-rc.1, < 5.2.2","status":"affected"}]}],"references":["https://github.com/golang-jwt/jwt/security/advisories/GHSA-mh63-6h87-95cp","https://github.com/golang-jwt/jwt/commit/0951d184286dece21f73c85673fd308786ffe9c3","https://github.com/golang-jwt/jwt/commit/bf316c48137a1212f8d0af9288cc9ce8e59f1afb","https://security.netapp.com/advisory/ntap-20250404-0002/"],"weaknesses":["CWE-405"],"ingestedAt":"2026-10-29T20:08:55.257Z","source":{"repository":"CVEProject/cvelistV5","path":"cves/2025/30xxx/CVE-2025-30204.json","commit":"556c9d3a8cd17e218bb8e452ba7cd619a384ff47"},"raw":{"dataType":"CVE_RECORD","dataVersion":"5.1","cveMetadata":{"cveId":"CVE-2025-30204","state":"PUBLISHED","datePublished":"2025-03-21T21:42:01.382Z","dateUpdated":"2025-04-10T13:03:19.897Z","assignerShortName":"GitHub_M","assignerOrgId":"a0819718-46f1-4df5-94e2-005712e83aaa","dateReserved":"2025-03-18T18:15:13.849Z"},"containers":{"cna":{"title":"jwt-go allows excessive memory allocation during header parsing","descriptions":[{"lang":"en","value":"golang-jwt is a Go implementation of JSON Web Tokens. Starting in version 3.2.0 and prior to versions 5.2.2 and 4.5.2, the function parse.ParseUnverified splits (via a call to strings.Split) its argument (which is untrusted data) on periods. As a result, in the face of a malicious request whose Authorization header consists of Bearer  followed by many period characters, a call to that function incurs allocations to the tune of O(n) bytes (where n stands for the length of the function's argument), with a constant factor of about 16. This issue is fixed in 5.2.2 and 4.5.2."}],"affected":[{"vendor":"golang-jwt","product":"jwt","versions":[{"version":">= 3.2.0, < 4.5.2","status":"affected"},{"version":">= 5.0.0-rc.1, < 5.2.2","status":"affected"}]}],"references":[{"url":"https://github.com/golang-jwt/jwt/security/advisories/GHSA-mh63-6h87-95cp","name":"https://github.com/golang-jwt/jwt/security/advisories/GHSA-mh63-6h87-95cp","tags":["x_refsource_CONFIRM"]},{"url":"https://github.com/golang-jwt/jwt/commit/0951d184286dece21f73c85673fd308786ffe9c3","name":"https://github.com/golang-jwt/jwt/commit/0951d184286dece21f73c85673fd308786ffe9c3","tags":["x_refsource_MISC"]},{"url":"https://github.com/golang-jwt/jwt/commit/bf316c48137a1212f8d0af9288cc9ce8e59f1afb","name":"https://github.com/golang-jwt/jwt/commit/bf316c48137a1212f8d0af9288cc9ce8e59f1afb","tags":["x_refsource_MISC"]}],"metrics":[{"cvssV3_1":{"attackComplexity":"LOW","attackVector":"NETWORK","availabilityImpact":"HIGH","baseScore":7.5,"baseSeverity":"HIGH","confidentialityImpact":"NONE","integrityImpact":"NONE","privilegesRequired":"NONE","scope":"UNCHANGED","userInteraction":"NONE","vectorString":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H","version":"3.1"}}],"problemTypes":[{"descriptions":[{"cweId":"CWE-405","lang":"en","description":"CWE-405: Asymmetric Resource Consumption (Amplification)","type":"CWE"}]}],"providerMetadata":{"shortName":"GitHub_M","orgId":"a0819718-46f1-4df5-94e2-005712e83aaa","dateUpdated":"2025-04-10T13:03:19.897Z"},"source":{"advisory":"GHSA-mh63-6h87-95cp","discovery":"UNKNOWN"}},"adp":[{"title":"CISA ADP Vulnrichment","metrics":[{"other":{"type":"ssvc","content":{"timestamp":"2025-03-24T14:10:18.281694Z","id":"CVE-2025-30204","options":[{"Exploitation":"none"},{"Automatable":"yes"},{"Technical Impact":"partial"}],"role":"CISA Coordinator","version":"2.0.3"}}}],"providerMetadata":{"shortName":"CISA-ADP","orgId":"134c704f-9b21-4f2e-91b3-4a467353bcc0","dateUpdated":"2025-03-24T14:10:35.776Z"}},{"title":"CVE Program Container","references":[{"url":"https://security.netapp.com/advisory/ntap-20250404-0002/"}],"providerMetadata":{"shortName":"CVE","orgId":"af854a3a-2127-422b-91ae-364da2661108","dateUpdated":"2025-04-04T23:03:13.309Z"}}]}}}