{"id":"CVE-2025-24976","aliases":["EUVD-2025-3999","GHSA-phw4-mc57-4hwc","GO-2025-3460","openSUSE-SU-2025:14889-1"],"status":"published","title":"Distribution's token authentication allows attacker to inject an untrusted signing key in a JWT","description":"Distribution is a toolkit to pack, ship, store, and deliver container content. Systems running registry versions 3.0.0-beta.1 through 3.0.0-rc.2 with token authentication enabled may be vulnerable to an issue in which token authentication allows an attacker to inject an untrusted signing key in a JSON web token (JWT). The issue lies in how the JSON web key (JWK) verification is performed. When a JWT contains a JWK header without a certificate chain, the code only checks if the KeyID (`kid`) matches one of the trusted keys, but doesn't verify that the actual key material matches. A fix for the issue is available at commit 5ea9aa028db65ca5665f6af2c20ecf9dc34e5fcd and expected to be a part of version 3.0.0-rc.3. There is no way to work around this issue without patching if the system requires token authentication.","severity":{"version":"4.0","score":6.6,"vector":"CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:H/VA:N/SC:N/SI:N/SA:N/E:U","level":"medium","assessor":"cna","from":"cve"},"epss":{"day":"2026-11-09","score":0.00353,"percentile":0.29284,"model":"v2026.06.15"},"facts":{"in_kev":false,"known_exploited":false,"public_exploit":false,"fix_available":true},"cwes":["CWE-639"],"published":"2025-02-11T15:48:59Z","modified":"2026-10-28T02:30:53Z","fixes":[{"ecosystem":"Go","package":"github.com/distribution/distribution/v3","fixed_in":["3.0.0-rc.3"],"sources":["ghsa"]}],"affected":[{"source":"ghsa","ecosystem":"Go","package":"github.com/distribution/distribution/v3","ranges":[{"type":"UNPARSED","raw":"\u003e 3.0.0-beta.1, \u003c 3.0.0-rc.3","events":[{"fixed":"3.0.0-rc.3"}]}]},{"source":"osv","ecosystem":"Go","package":"github.com/distribution/distribution","ranges":[{"type":"SEMVER","events":[{"introduced":"0"}]}]},{"source":"osv","ecosystem":"openSUSE:Tumbleweed","package":"govulncheck-vulndb","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0.0.20250312T181707-1.1"}]}],"bundled":31}],"products":[{"vendor":"distribution","product":"distribution"}],"references":[{"url":"https://github.com/distribution/distribution/security/advisories/GHSA-phw4-mc57-4hwc","tags":["x_refsource_CONFIRM","advisory"]},{"url":"https://github.com/distribution/distribution/commit/f4a500caf68169dccb0b54cb90523e68ee1ac2be","tags":["x_refsource_MISC","fix"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2025-24976","tags":["advisory"]},{"url":"https://github.com/advisories/GHSA-phw4-mc57-4hwc"},{"url":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2025/24xxx/CVE-2025-24976.json","tags":["advisory"]},{"url":"https://github.com/distribution/distribution/commit/5ea9aa028db65ca5665f6af2c20ecf9dc34e5fcd","tags":["fix"]},{"url":"","tags":["advisory"]},{"url":"https://www.suse.com/security/cve/CVE-2024-57603","tags":["web"]},{"url":"https://www.suse.com/security/cve/CVE-2024-57604","tags":["web"]},{"url":"https://www.suse.com/security/cve/CVE-2025-0426","tags":["web"]},{"url":"https://www.suse.com/security/cve/CVE-2025-1243","tags":["web"]},{"url":"https://www.suse.com/security/cve/CVE-2025-1293","tags":["web"]},{"url":"https://www.suse.com/security/cve/CVE-2025-1412","tags":["web"]},{"url":"https://www.suse.com/security/cve/CVE-2025-20051","tags":["web"]},{"url":"https://www.suse.com/security/cve/CVE-2025-22870","tags":["web"]},{"url":"https://www.suse.com/security/cve/CVE-2025-22952","tags":["web"]},{"url":"https://www.suse.com/security/cve/CVE-2025-23387","tags":["web"]},{"url":"https://www.suse.com/security/cve/CVE-2025-23388","tags":["web"]},{"url":"https://www.suse.com/security/cve/CVE-2025-23389","tags":["web"]},{"url":"https://www.suse.com/security/cve/CVE-2025-24016","tags":["web"]},{"url":"https://www.suse.com/security/cve/CVE-2025-24526","tags":["web"]},{"url":"https://www.suse.com/security/cve/CVE-2025-24806","tags":["web"]},{"url":"https://www.suse.com/security/cve/CVE-2025-24976","tags":["web"]},{"url":"https://www.suse.com/security/cve/CVE-2025-25196","tags":["web"]},{"url":"https://www.suse.com/security/cve/CVE-2025-25199","tags":["web"]},{"url":"https://www.suse.com/security/cve/CVE-2025-25204","tags":["web"]},{"url":"https://www.suse.com/security/cve/CVE-2025-25279","tags":["web"]},{"url":"https://www.suse.com/security/cve/CVE-2025-25294","tags":["web"]},{"url":"https://www.suse.com/security/cve/CVE-2025-27088","tags":["web"]},{"url":"https://www.suse.com/security/cve/CVE-2025-27090","tags":["web"]},{"url":"https://www.suse.com/security/cve/CVE-2025-27100","tags":["web"]},{"url":"https://www.suse.com/security/cve/CVE-2025-27112","tags":["web"]},{"url":"https://www.suse.com/security/cve/CVE-2025-27144","tags":["web"]},{"url":"https://www.suse.com/security/cve/CVE-2025-27155","tags":["web"]},{"url":"https://www.suse.com/security/cve/CVE-2025-27414","tags":["web"]},{"url":"https://www.suse.com/security/cve/CVE-2025-27421","tags":["web"]},{"url":"https://www.suse.com/security/cve/CVE-2025-27507","tags":["web"]},{"url":"https://www.suse.com/security/cve/CVE-2025-27509","tags":["web"]}],"sources":{"cve":[{"id":"CVE-2025-24976","title":"Distribution's token authentication allows attacker to inject an untrusted signing key in a JWT","description":"Distribution is a toolkit to pack, ship, store, and deliver container content. Systems running registry versions 3.0.0-beta.1 through 3.0.0-rc.2 with token authentication enabled may be vulnerable to an issue in which token authentication allows an attacker to inject an untrusted signing key in a JSON web token (JWT). The issue lies in how the JSON web key (JWK) verification is performed. When a JWT contains a JWK header without a certificate chain, the code only checks if the KeyID (`kid`) matches one of the trusted keys, but doesn't verify that the actual key material matches. A fix for the issue is available at commit 5ea9aa028db65ca5665f6af2c20ecf9dc34e5fcd and expected to be a part of version 3.0.0-rc.3. There is no way to work around this issue without patching if the system requires token authentication.","status":"published","published":"2025-02-11T15:48:59.7Z","modified":"2026-01-23T17:04:22.154Z","cvss":[{"version":"4.0","score":6.6,"vector":"CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:H/VA:N/SC:N/SI:N/SA:N/E:U","level":"medium","assessor":"cna"}],"cwes":["CWE-639"],"updated_at":"2026-11-02T14:32:44.11109Z"}],"euvd":[{"id":"EUVD-2025-3999","description":"Distribution is a toolkit to pack, ship, store, and deliver container content. Systems running registry versions 3.0.0-beta.1 through 3.0.0-rc.2 with token authentication enabled may be vulnerable to an issue in which token authentication allows an attacker to inject an untrusted signing key in a JSON web token (JWT). The issue lies in how the JSON web key (JWK) verification is performed. When a JWT contains a JWK header without a certificate chain, the code only checks if the KeyID (`kid`) matches one of the trusted keys, but doesn't verify that the actual key material matches. A fix for the issue is available at commit 5ea9aa028db65ca5665f6af2c20ecf9dc34e5fcd and expected to be a part of version 3.0.0-rc.3. There is no way to work around this issue without patching if the system requires token authentication.","status":"published","published":"2025-02-11T15:48:59Z","modified":"2026-01-23T17:04:22Z","cvss":[{"version":"4.0","score":6.6,"vector":"CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:H/VA:N/SC:N/SI:N/SA:N/E:U","level":"medium"}],"updated_at":"2026-11-02T19:48:48.084617Z"}],"ghsa":[{"id":"GHSA-phw4-mc57-4hwc","title":"Distribution's token authentication allows to inject an untrusted signing key in a JWT","description":"### Impact\n\nSystems running registry version \u003e `3.0.0-beta.1` with token authentication enabled.\n\n### Patches\n\nUpdate to at least `v3.0.0-rc.3`\n\n### Workarounds\n\nThere is no way to work around this issue without patching if your system requires token authentication.\n\n### References\n\nThe issue lies in how the JWK verification is performed. When a JWT contains a JWK header without a certificate chain, the code only checks if the KeyID (`kid`) matches one of the trusted keys, but doesn't verify that the actual key material matches.\n\nHere's the problematic flow:\n\n1. An attacker generates their own key pair\n2. They create a JWT and include their public key in the JWK header\n3. They set the `kid` in the JWK to match one of the trusted keys' IDs (which they could potentially discover)\n4. They sign the JWT with their private key\n5. The registry only checks if the `kid` exists in the trusted keys map but then uses the attacker's public key from the JWK to verify the signature","status":"published","published":"2025-02-11T17:57:58Z","modified":"2026-01-23T17:04:31Z","cvss":[{"version":"4.0","score":8.7,"vector":"CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:H/VA:N/SC:N/SI:N/SA:N","level":"high"}],"cwes":["CWE-639"],"updated_at":"2026-11-02T14:39:19.525691Z"}],"nvd":[{"id":"CVE-2025-24976","description":"Distribution is a toolkit to pack, ship, store, and deliver container content. Systems running registry versions 3.0.0-beta.1 through 3.0.0-rc.2 with token authentication enabled may be vulnerable to an issue in which token authentication allows an attacker to inject an untrusted signing key in a JSON web token (JWT). The issue lies in how the JSON web key (JWK) verification is performed. When a JWT contains a JWK header without a certificate chain, the code only checks if the KeyID (`kid`) matches one of the trusted keys, but doesn't verify that the actual key material matches. A fix for the issue is available at commit 5ea9aa028db65ca5665f6af2c20ecf9dc34e5fcd and expected to be a part of version 3.0.0-rc.3. There is no way to work around this issue without patching if the system requires token authentication.","status":"published","published":"2025-02-11T16:15:52.163Z","modified":"2026-06-17T08:59:54.903Z","cvss":[{"version":"4.0","score":6.6,"vector":"CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:H/VA:N/SC:N/SI:N/SA:N/E:U/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X","level":"medium","assessor":"secondary"}],"cwes":["CWE-639"],"updated_at":"2026-11-02T14:10:50.916773Z"}],"osv":[{"id":"CVE-2025-24976","title":"Distribution's token authentication allows attacker to inject an untrusted signing key in a JWT","description":"Distribution is a toolkit to pack, ship, store, and deliver container content. Systems running registry versions 3.0.0-beta.1 through 3.0.0-rc.2 with token authentication enabled may be vulnerable to an issue in which token authentication allows an attacker to inject an untrusted signing key in a JSON web token (JWT). The issue lies in how the JSON web key (JWK) verification is performed. When a JWT contains a JWK header without a certificate chain, the code only checks if the KeyID (`kid`) matches one of the trusted keys, but doesn't verify that the actual key material matches. A fix for the issue is available at commit 5ea9aa028db65ca5665f6af2c20ecf9dc34e5fcd and expected to be a part of version 3.0.0-rc.3. There is no way to work around this issue without patching if the system requires token authentication.","status":"published","published":"2025-02-11T15:48:59.7Z","modified":"2026-10-28T02:30:53.373547898Z","cvss":[{"version":"4.0","score":6.6,"vector":"CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:H/VA:N/SC:N/SI:N/SA:N/E:U","level":"medium"}],"cwes":["CWE-639"],"updated_at":"2026-11-02T15:44:47.386092Z"},{"id":"GO-2025-3460","title":"Distribution's token authentication allows attacker to inject an untrusted signing key in a JWT in github.com/distribution/distribution","description":"Distribution's token authentication allows attacker to inject an untrusted signing key in a JWT in github.com/distribution/distribution","status":"published","published":"2025-03-03T19:22:09Z","modified":"2026-02-04T02:22:56.13631Z","updated_at":"2026-11-02T15:47:01.728182Z"},{"id":"openSUSE-SU-2025:14889-1","title":"govulncheck-vulndb-0.0.20250312T181707-1.1 on GA media","description":"These are all security issues fixed in the govulncheck-vulndb-0.0.20250312T181707-1.1 package on the GA media of openSUSE Tumbleweed.","status":"published","published":"2025-03-13T00:00:00Z","modified":"2026-02-04T04:02:14.938926Z","updated_at":"2026-11-02T16:58:37.399567Z"}]}}
