{"id":"CVE-2021-46743","aliases":["CVE-2021-46743","GHSA-8xf4-w7qw-pjjw"],"related":[],"kind":"vulnerability","state":"published","title":"Firebase PHP-JWT key/algorithm type confusion","summary":"In Firebase PHP-JWT before 6.0.0, an algorithm-confusion issue (e.g., RS256 / HS256) exists via the kid (aka Key ID) header, when multiple types of keys are loaded in a key ring. This allows an attacker to forge tokens that validate under the incorrect key. NOTE: this provides a straightforward way to use the PHP-JWT library unsafely, but might not be considered a vulnerability in the library itself.","summarySource":"cvelist","descriptions":[{"lang":"en","text":"In Firebase PHP-JWT before 6.0.0, an algorithm-confusion issue (e.g., RS256 / HS256) exists via the kid (aka Key ID) header, when multiple types of keys are loaded in a key ring. This allows an attacker to forge tokens that validate under the incorrect key. NOTE: this provides a straightforward way to use the PHP-JWT library unsafely, but might not be considered a vulnerability in the library itself.","source":"cvelist"},{"lang":"es","text":"En Firebase PHP-JWT versiones anteriores a 6.0.0, se presenta un problema de confusión de algoritmos (por ejemplo, RS256 / HS256) por medio del encabezado kid (también se conoce como Key ID), cuando son cargados varios tipos de claves en un llavero. Esto permite a un atacante falsificar tokens que son comprobados bajo la clave incorrecta. NOTA: esto proporciona una forma directa de usar la biblioteca PHP-JWT de forma no segura, pero podría no considerarse una vulnerabilidad en la propia biblioteca","source":"nvd"}],"published":"2022-03-29T06:40:18.000Z","modified":"2026-06-17T04:15:25.123Z","severity":{"scorer":"NVD","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:N","score":9.1,"rating":"CRITICAL"},"severities":[{"scorer":"GitHub","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:N","score":9.1,"rating":"CRITICAL"},{"scorer":"NVD","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:N","score":9.1,"rating":"CRITICAL"},{"scorer":"NVD","scheme":"CVSS:2.0","vector":"AV:N/AC:M/Au:N/C:P/I:P/A:N","score":5.8,"rating":"MEDIUM"}],"cwes":["CWE-347","CWE-843"],"affected":[{"ranges":[{"version":"n/a","status":"affected"}],"source":"cvelist"},{"ranges":[{"type":"ecosystem","introduced":"0","status":"affected","fixed":"6.0.0"}],"ecosystem":"Packagist","package":"firebase/php-jwt","purl":"pkg:composer/firebase/php-jwt","source":"ghsa"},{"ranges":[{"status":"affected","fixed":"6.0.0"}],"vendor":"google","product":"firebase_php-jwt","cpe":"cpe:2.3:a:google:firebase_php-jwt:*:*:*:*:*:*:*:*","source":"nvd"}],"references":[{"url":"https://github.com/firebase/php-jwt/issues/351","tags":["exploit","third-party-advisory","web","x-refsource-misc","x-transferred"],"sources":["cvelist","ghsa","nvd"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2021-46743","tags":["advisory"],"sources":["ghsa"]},{"url":"https://github.com/FriendsOfPHP/security-advisories/blob/master/firebase/php-jwt/CVE-2021-46743.yaml","tags":["web"],"sources":["ghsa"]},{"url":"https://github.com/firebase/php-jwt","tags":["package"],"sources":["ghsa"]},{"url":"https://github.com/firebase/php-jwt/releases/tag/v6.0.0","tags":["web"],"sources":["ghsa"]}],"credits":[],"assigner":"mitre","sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2021-46743","url":"https://www.cve.org/CVERecord?id=CVE-2021-46743","licence":"CVE Terms of Use","modified":"2024-08-04T05:17:41.727Z"},{"source":"ghsa","name":"GitHub Advisory Database","id":"GHSA-8xf4-w7qw-pjjw","url":"https://github.com/advisories/GHSA-8xf4-w7qw-pjjw","licence":"CC-BY-4.0","modified":"2023-11-08T04:07:27.311Z"},{"source":"nvd","name":"NVD","id":"CVE-2021-46743","url":"https://nvd.nist.gov/vuln/detail/CVE-2021-46743","licence":"Public domain","modified":"2026-06-17T04:15:25.123Z"}],"updatedAt":"2026-11-25T22:58:07.275Z","epss":{"score":0.00916,"percentile":0.61226,"date":"2026-12-01T12:00:22.000Z"}}