{"schemaVersion":1,"url":"https://cve.openhack.com/cve/CVE-2026-133428","id":"CVE-2026-133428","title":"Quadratic time and memory multi-host URL validation","description":"Validating an untrusted URL with a long scheme and many hosts into a multi-host URL field (e.g. PostgresDsn) takes quadratic time and memory: an input of about a hundred kilobytes takes around a gigabyte of memory to validate.\n\nThe parse_multihost_url() function (in pydantic-core/src/validators/url.rs) parses each host separately, prepending the whole URL prefix (including the scheme) to every one","descriptionLong":"Validating an untrusted URL with a long scheme and many hosts into a multi-host URL field (e.g. PostgresDsn) takes quadratic time and memory: an input of about a hundred kilobytes takes around a gigabyte of memory to validate.\n\nThe parse_multihost_url() function (in pydantic-core/src/validators/url.rs) parses each host separately, prepending the whole URL prefix (including the scheme) to every one of them. As the scheme can be arbitrarily long, and is parsed and stored once per host, both time and memory grow quadratically with the input size. Allowed schemes (e.g. postgres for PostgresDsn) are only checked after parsing, so they don't prevent the issue.\n\nThe issue was fixed in commit b4028f9d87e34750e53be0ba011d70f3c0fcc94e.\n\nImpact: denial of service through validation of untrusted input. Affected are applications validating untrusted strings into multi-host URL fields (PostgresDsn, MongoDsn, NatsDsn, or custom types built on MultiHostUrl).","published":"2026-11-20T07:32:16.979Z","updated":"2026-11-20T07:32:16.979Z","reserved":"2026-11-19T19:47:33.202Z","status":"PUBLISHED","rejected":false,"assigner":"Pydantic","metric":{"version":"4.0","score":6.3,"vector":"CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:N/VI:N/VA:L/SC:N/SI:N/SA:N","rating":"medium","source":"Pydantic"},"metrics":[{"version":"4.0","score":6.3,"vector":"CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:N/VI:N/VA:L/SC:N/SI:N/SA:N","rating":"medium","source":"Pydantic"}],"rating":"medium","products":["pydantic"],"affectedProducts":[{"vendor":"pydantic","product":"pydantic","defaultStatus":"unaffected","versions":[{"version":"2.0.0","lessThan":"2.14.0","status":"affected","versionType":"python"}],"platforms":[]}],"packages":[],"cwes":["CWE-407"],"aliases":[],"references":[{"url":"https://github.com/pydantic/pydantic/security/advisories/GHSA-955g-x97g-8mcp","tags":["vendor-advisory"]},{"url":"https://github.com/pydantic/pydantic/blob/v2.13.5/pydantic-core/src/validators/url.rs#L537","tags":[]},{"url":"https://github.com/pydantic/pydantic/blob/v2.13.5/pydantic-core/src/validators/url.rs#L644-L649","tags":[]},{"url":"https://github.com/pydantic/pydantic/commit/b4028f9d87e34750e53be0ba011d70f3c0fcc94e","tags":[]}],"patchReferenced":false,"fixAvailable":false,"exploitReferenced":false,"kev":false,"kevAdded":null,"kevDue":null,"kevEntry":null,"ssvc":null,"epss":null,"epssPercentile":null,"sources":[{"name":"CVE List","url":"https://www.cve.org/CVERecord?id=CVE-2026-133428","ok":true},{"name":"NVD","url":"https://nvd.nist.gov/vuln/detail/CVE-2026-133428","ok":false,"note":"not found"},{"name":"OSV","url":"https://osv.dev/vulnerability/CVE-2026-133428","ok":false,"note":"no open-source package data"},{"name":"CISA KEV","url":"https://www.cisa.gov/known-exploited-vulnerabilities-catalog","ok":true,"note":"not listed"},{"name":"EPSS","url":"https://api.first.org/data/v1/epss?cve=CVE-2026-133428","ok":false,"note":"no score yet"}],"aiTitle":false,"tech":[],"critical":[],"attention":null}