PyJWT is a Python implementation of JSON Web Token standards. Prior to 2.14.0, PyJWT is_pem_format is affected because lazy PEM regular expression backtracks extensively. This occurs when a certificate-like input contains repeated BEGIN markers without a matching END marker. As a result, is_pem_format performs unbounded backtracking while searching for a PEM end marker. Consequently, an attacker can cause intensive CPU consumption. This issue is fixed in version 2.14.0.
The product uses a regular expression with a worst-case computational complexity that is inefficient and possibly exponential.
| Name | Vendor | Start Version | End Version |
|---|---|---|---|
| Pyjwt | Pyjwt_project | * | 2.14.0 (excluding) |
| Pyjwt | Ubuntu | upstream | * |