CVE-2017-11424
Description
In PyJWT 1.5.0 and below the `invalid_strings` check in `HMACAlgorithm.prepare_key` does not account for all PEM encoded public keys. Specifically, the PKCS1 PEM encoded format would be allowed because it is prefaced with the string `-----BEGIN RSA PUBLIC KEY-----` which is not accounted for. This enables symmetric/asymmetric key confusion attacks against users using the PKCS1 PEM encoded public keys, which would allow an attacker to craft JWTs from scratch.
Predictions
Heuristic predictions, AS-IS, for prioritization only.
Mitigations
No mitigations published for this CVE yet.
The vendor-content worker queues fetches as references arrive (check back in a few minutes). Or โ if you've already worked around this in production โ publish your fix to the community-verified tier.
โ Propose a mitigation on Community โ Mitigations published via the community go through AI scoring + 2 human reviewers + 7-day silent objection window before landing here withsource_tier=community-verified.
OS impact
| OS | Version | Status | Fixed in |
|---|---|---|---|
| debian | 8.0 | affected | |
| debian | 9.0 | affected | |
| debian | bookworm | fixed | 1.4.2-1.1 |
| debian | bullseye | fixed | 1.4.2-1.1 |
| debian | forky | fixed | 1.4.2-1.1 |
| debian | sid | fixed | 1.4.2-1.1 |
| debian | trixie | fixed | 1.4.2-1.1 |
Package impact
| Ecosystem | Package | Vulnerable | Fixed |
|---|---|---|---|
| PyPI | pyjwt | <1.5.1 | 1.5.1 |
Application impact
| Vendor | Product | Versions | Fixed |
|---|---|---|---|
| pyjwt_project | pyjwt | {"endIncluding":"1.5.0"} | |
References
- http://www.debian.org/security/2017/dsa-3979
- https://github.com/jpadilla/pyjwt/pull/277
- https://nvd.nist.gov/vuln/detail/CVE-2017-11424
- https://github.com/jpadilla/pyjwt
- https://github.com/pypa/advisory-database/tree/main/vulns/pyjwt/PYSEC-2017-24.yaml
- https://github.com/advisories/GHSA-r9jw-mwhq-wp62
- https://security-tracker.debian.org/tracker/CVE-2017-11424
Community-verified mitigations for this CVE will appear above when contributors publish them.
Verify integrity in audit chain (admin only). AS-IS.