Symfony JSONPathに処理を長時間占有される脆弱性
Summary
攻撃者が影響を与えられるJSONPath式を評価すると、PHPのワーカーが長時間CPUを占有される脆弱性です。symfony/json-pathとsymfony/symfonyの7.3.0以上7.4.23未満および8.0.0以上8.1.11未満が対象で、7.4.23と8.1.11で修正されています。修正版へ更新してください。
AI summary
Produced by SecPulse using an external AI model; it may contain mistakes. Check the original description and references below before acting on it.
攻撃者が影響を与えられるJSONPath式を評価すると、PHPのワーカーが長時間CPUを占有される脆弱性です。symfony/json-pathとsymfony/symfonyの7.3.0以上7.4.23未満および8.0.0以上8.1.11未満が対象で、7.4.23と8.1.11で修正されています。修正版へ更新してください。
Affected packages
| Package | Affected → Fixed | |
|---|---|---|
| Symfonysymfony/json-path |
≥ 7.3.0, < 7.4.23→ 7.4.23 ≥ 8.0.0, < 8.1.11→ 8.1.11 |
7.4.23 8.1.11 |
| Symfonysymfony/symfony |
≥ 7.3.0, < 7.4.23→ 7.4.23 ≥ 8.0.0, < 8.1.11→ 8.1.11 |
7.4.23 8.1.11 |
Fix status by distribution
Records published by each distribution for this CVE. Fixed versions differ by release; check each link.
- Debian DEBIAN-CVE-2026-135804 symfony Fix available
- Ubuntu UBUNTU-CVE-2026-135804 symfony No fixed version in this record
Original description The description as published by the source.
The fix for CVE-2026-45756 lowers pcre.backtrack_limit to 10000 around each preg_match() call of the match() and search() filter functions. That limit applies to one starting position, not to one call. PCRE resets its counter at every position it tries a match from. So an unanchored pattern that stays just under the limit is paid once per byte of the subject. Each call also starts from a fresh limit, so chaining clauses in one filter multiplies the work.
Two other paths made the cost of a query grow faster than its size, without any regular expression:
- The filter evaluator scanned the whole expression for logical operators once per node. Its cost grew with the square of the number of chained clauses.
- Queries starting with $ inside a filter, like @.x == $.limit or length($.items), were evaluated again for every node the filter visits.
An application that evaluates an attacker-influenced JSONPath expression can therefore still be made to hold a PHP worker. A document of 2 MB and a query of 2.5 KB take 3.5 minutes of CPU.
JsonCrawler::find() now bounds the total regex work of one call, and throws an exception when that budget is exhausted. Filter expressions are parsed once per query, and absolute queries inside filters are evaluated once per query.
Source: CVE.org (CVE Program・cvelistV5) NVD GitHub Advisory
References
- advisory symfony.com
- advisory github.com
- advisory nvd.nist.gov
- advisory github.com
- package github.com
- patch github.com
- patch github.com
- patch github.com
- web github.com
- web packagist.org