CVE-2026-49265 Details
Description
OAuthLib is an implementation of the OAuth request-signing logic for Python 3.6+. From 3.0.0 until 4.0.0, OAuthLib's PKCE checks in oauthlib/oauth2/rfc6749/grant_types/authorization_code.py compare attacker-supplied code_verifier values with stored challenges using ordinary string equality in code_challenge_method_plain and code_challenge_method_s256. Because the comparison can return after a length difference or the first mismatching character, repeated token endpoint measurements can reveal common-prefix timing information that could potentially allow recovery of the code_verifier, unauthorized access-token acquisition, and account takeover. Practical exploitation requires an intercepted, single-use authorization code and enough measurements to overcome real-world network noise; the local timing benchmark does not establish practical remote account takeover, so the weakness remains a defense-in-depth concern. This issue is fixed in version 4.0.0.
A timing attack vulnerability has been identified in OAuthLib's implementation of the Proof Key for Code Exchange (PKCE) in the Authorization Code Grant flow, specifically in versions 3.0.0 prior to 4.0.0. The vulnerability arises because the `code_challenge_method_plain` and `code_challenge_method_s256` functions compare the `code_verifier` values with stored challenges using standard string equality. This method of comparison can be exploited to create a timing oracle, allowing an attacker to recover the `code_verifier` and gain unauthorized access to access tokens, potentially leading to account takeover. Exploitation requires interception of a single-use authorization code and repeated measurements of the token endpoint response times to bypass network noise, making this primarily a defense-in-depth concern.
Users can upgrade to OAuthLib version 4.0.0 or later, where this vulnerability has been fixed.
Metrics
CVSS 4.0 Severity and Vector Strings:
CVSS 3.x Severity and Vector Strings:
No data available for CVSS Version 2.0 on this CVE.
Volerion
Assessed Oct 13, 2026CISA-ADP
Assessed Oct 13, 2026References to Advisories, Solutions, and Tools
By selecting these links, you will be leaving this site. These are references gathered from the official CVE record and are not endorsed by Volerion.
| URL | Source(s) | Tag(s) |
|---|---|---|
| https://github.com/oauthlib/oauthlib/commit/74664d3fe037a354e180e305135c6bab1747a6b0 | [email protected] | Source CodeVendor |
| https://github.com/oauthlib/oauthlib/pull/963 | [email protected] | Source CodeVendor |
| https://github.com/oauthlib/oauthlib/releases/tag/v4.0.0 | [email protected] | Release NotesVendor |
| https://github.com/oauthlib/oauthlib/security/advisories/GHSA-xpv3-w29h-x7cv | [email protected] | AdvisoryExploitRemedyVendor |
| https://github.com/pypa/advisory-database/tree/main/vulns/oauthlib/PYSEC-2026-4114.yaml | [email protected] | AdvisoryBundle |
Weakness Enumeration
| CWE-ID | CWE Name | Source |
|---|---|---|
| CWE-208 | Observable Timing Discrepancy | [email protected] |
Affected Products
| Product | Versions |
|---|---|
| OAuthLib | >= 3.0.0, < 4.0.0 (semver) |
CPE
Remediation
| |
Change History
2 change records found show changes
| Date | Action | Recorded By |
|---|---|---|
| Oct 13, 2026 | CVE Modified | CISA-ADP |
| Oct 13, 2026 | New CVE Received | [email protected] |
Volerion