jmespath.php has CompilerRuntime code injection via unescaped function names
Key facts
- Attack vector
- Network
- Privileges required
- None
- User interaction
- None
- Attack complexity
- Low
- Impact type
- Code execution
- Confidentiality · integrity · availability
- High · High · High
- Fix status
- Fixed
Attack profile from CVSS 3.1 · CNA. Fix status from CNA and GitHub. Impact type from CWE-94.
Summary
jmespath.php allows users to use JMESPath, software for declaratively specifying how to extract elements from a JSON document, in PHP applications with PHP data structures. Versions prior to 2.9.1 can generate and execute attacker-controlled PHP code when `JmesPath\CompilerRuntime` is used with an attacker-controlled JMESPath expression. The compiler emits parsed JMESPath function names into generated PHP source without sufficient escaping. A crafted expression can cause the generated cache file to contain executable attacker-controlled PHP, which is then loaded by the compiler runtime. The issue is patched in `2.9.1` and later. As a workaround, disable `JP_PHP_COMPILE` and do not use `JmesPath\CompilerRuntime` with attacker-controlled expressions. Use the default `AstRuntime` for untrusted expressions. Applications that must continue accepting untrusted JMESPath expressions before upgrading should ensure those expressions are never evaluated by the compiler runtime.
Why it matters now
SSVC decision points
CISA ADP · SSVC 2.0.3
- Exploitation
- Poc
- Automatable
- Yes
- Technical impact
- Total
The decision (Track, Attend, Act) also depends on your mission and well-being impact; see CISA's SSVC guide.
Affected products
| Vendor | Product | Affected versions | Fixed in | Status | Source |
|---|---|---|---|---|---|
| jmespath | jmespath.php | before 2.9.1 | 2.9.1 | Patch available | CNA |
| — | mtdowling/jmespath.php (Packagist) | before 2.9.1 | 2.9.1 | Patch available | GHSA-pcw8-m77r-2528 |
- jmespath.php Vendorjmespath Affected before 2.9.1 Fixed in 2.9.1 Patch available CNA
- mtdowling/jmespath.php (Packagist) Vendor— Affected before 2.9.1 Fixed in 2.9.1 Patch available GHSA-pcw8-m77r-2528
Remediation
- Fix · CNA jmespath.php (jmespath) Fixed in 2.9.1
- Fix · GHSA-pcw8-m77r-2528 mtdowling/jmespath.php (Packagist) Fixed in 2.9.1 Advisory →
Vendor assessments
Timeline
- 2026-10-02 Threatist record created from CVE-2026-54133
- 2026-10-03 Alias added: GHSA-pcw8-m77r-2528
References
More Jmespath vulnerabilities
- TI-2022-14146 jmespath.rb (aka JMESPath for Ruby) before 1.6.1 uses JSON.load in a situation where JSON.parse is preferable. CVSS 3.1CRITICAL 9.8
Sources
- CVE-2026-54133 · CVE Program
- CVE-2026-54133 · NVD
- FIRST EPSS
- GHSA-pcw8-m77r-2528 · GitHub Advisory Database · CC BY 4.0
- CVE-2026-54133 · Red Hat security data · CC BY 4.0
This product uses the NVD API but is not endorsed or certified by the NVD. Sources and licences