Quadratic time timedelta validation in Pydantic V1
Summary
| CVE | CVE-2026-133421 |
|---|---|
| State | PUBLISHED |
| Assigner | Pydantic |
| Source Priority | CVE Program / NVD first with legacy fallback |
| Published | 2026-11-20 08:18:32 UTC |
| Updated | 2026-11-20 18:18:47 UTC |
| Description | Validating an untrusted ISO 8601 duration string into a timedelta field with Pydantic V1 takes quadratic time: an input of a few dozen kilobytes takes seconds to validate. The iso8601_duration_re regular expression used to parse ISO 8601 durations (in pydantic/datetime_parse.py) contains an unescaped ".", which also matches digits. On a string of digits, the repeated groups overlap and the regex engine backtracks in quadratic time. The issue was fixed in commit 62791e66a9f8f118e465ed760c9e2ede9ae3055e. Users relying on the pydantic.v1 namespace in Pydantic V2 should upgrade to 2.14.2 or later. Impact: denial of service through validation of untrusted input. Affected are applications validating untrusted strings into timedelta fields. |
Risk And Classification
Primary CVSS: v4.0 6.9 MEDIUM from 7cec5f2f-3032-4006-8740-31f605ffab5f
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:L/SC:N/SI:N/SA:N/E:X/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
Problem Types: CWE-1333 | CWE-1333 CWE-1333: Inefficient Regular Expression Complexity
| Version | Source | Type | Score | Severity | Vector |
|---|---|---|---|---|---|
| 4.0 | 7cec5f2f-3032-4006-8740-31f605ffab5f | Secondary | 6.9 | MEDIUM | CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:L/SC:N/SI:N/SA:N/E:X/C... |
| 4.0 | CNA | DECLARED | 6.9 | MEDIUM | CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:L/SC:N/SI:N/SA:N |
CVSS v4.0 Breakdown
Attack Vector
NetworkAttack Complexity
LowAttack Requirements
NonePrivileges Required
NoneUser Interaction
NoneConfidentiality
NoneIntegrity
NoneAvailability
LowSub Conf.
NoneSub Integrity
NoneSub Availability
NoneCVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:L/SC:N/SI:N/SA:N/E:X/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
Vendor Declared Affected Products
References
| Reference | Source | Link | Tags |
|---|---|---|---|
| github.com/pydantic/pydantic/releases/tag/v2.14.2 | 7cec5f2f-3032-4006-8740-31f605ffab5f | github.com | |
| github.com/pydantic/pydantic/security/advisories/GHSA-jfv7-ghgv-gx4x | 7cec5f2f-3032-4006-8740-31f605ffab5f | github.com | |
| github.com/pydantic/pydantic/commit/62791e66a9f8f118e465ed760c9e2ede9ae3... | 7cec5f2f-3032-4006-8740-31f605ffab5f | github.com | |
| github.com/pydantic/pydantic/blob/v1.10.26/pydantic/datetime_parse.py | 7cec5f2f-3032-4006-8740-31f605ffab5f | github.com | |
| CVE Program record | CVE.ORG | www.cve.org | canonical |
| NVD vulnerability detail | NVD | nvd.nist.gov | canonical, analysis |
Vendor Comments And Credit
Discovery Credit
CNA: edibleShell (en)
CNA: SounLabs (en)
CNA: iamibi (en)
There are currently no legacy QID mappings associated with this CVE.