CVE-2022-42889
Apache Commons Text prior to 1.10.0 allows RCE when applied to untrusted input due to insecure interpolation defaults
- Published
- Updated
- Reserved
- Assigned by
- apache
Description
Apache Commons Text performs variable interpolation, allowing properties to be dynamically evaluated and expanded. The standard format for interpolation is "${prefix:name}", where "prefix" is used to locate an instance of org.apache.commons.text.lookup.StringLookup that performs the interpolation. Starting with version 1.5 and continuing through 1.9, the set of default Lookup instances included interpolators that could result in arbitrary code execution or contact with remote servers. These lookups are: - "script" - execute expressions using the JVM script execution engine (javax.script) - "dns" - resolve dns records - "url" - load values from urls, including from remote servers Applications using the interpolation defaults in the affected versions may be vulnerable to remote code execution or unintentional contact with remote servers if untrusted configuration values are used. Users are recommended to upgrade to Apache Commons Text 1.10.0, which disables the problematic interpolators by default.
Scores
| Scored by | CVSS | Score | Vector |
|---|---|---|---|
| NVDNVD · Modified | 3.1 | Critical9.8 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H |
- EPSS (exploitation in 30 days)
- 99.9% · top 0.1% of all CVEs (6 Nov 2026)
- CISA SSVC
- Exploitation: none · Automatable: yes · Technical impact: total
The list uses the assigner's score when there is one, then CISA's, then NVD's: Critical 9.8.
Weakness
- Unexpected variable interpolation
- CWE-94 (opens in a new tab)All about CWE-94 and its CVEs
Affected products
Apache Software Foundation · Apache Commons Text
- affected unspecified – ≤ 1.9
- affected 1.5 – < Apache Commons Text*
Affected packages
From reviewed advisories of the GitHub Advisory Database.
- Mavencom.guicedee.services:commons-textGHSA-599f-7c49-w659 (opens in a new tab)
- Mavenorg.apache.commons:commons-textGHSA-599f-7c49-w659 (opens in a new tab)
What to do
Workaround: Upgrade to Apache Commons Text 1.10.0.
References (9)
- https://lists.apache.org/thread/n2bd4vdsgkqh2tm14l1wyc3jyol7s1om (opens in a new tab)x_transferred
- [oss-security] 20221013 CVE-2022-42889: Apache Commons Text prior to 1.10.0 allows RCE when applied to untrusted input due to insecure interpolation defaults (opens in a new tab)mailing-listx_transferred
- [oss-security] 20221017 Re: CVE-2022-42889: Apache Commons Text prior to 1.10.0 allows RCE when applied to untrusted input due to insecure interpolation defaults (opens in a new tab)mailing-listx_transferred
- https://security.netapp.com/advisory/ntap-20221020-0004/ (opens in a new tab)x_transferred
- https://psirt.global.sonicwall.com/vuln-detail/SNWLID-2022-0022 (opens in a new tab)x_transferred
- GLSA-202301-05 (opens in a new tab)vendor-advisoryx_transferred
- 20230214 OXAS-ADV-2022-0002: OX App Suite Security Advisory (opens in a new tab)mailing-listx_transferred
- http://packetstormsecurity.com/files/171003/OX-App-Suite-Cross-Site-Scripting-Server-Side-Request-Forgery.html (opens in a new tab)x_transferred
- http://packetstormsecurity.com/files/176650/Apache-Commons-Text-1.9-Remote-Code-Execution.html (opens in a new tab)x_transferred
Sources
The same CVE in the primary databases and aggregators, to check against.
- CVE.org record (opens in a new tab)
- CVE List JSON (GitHub) (opens in a new tab)
- NVD (opens in a new tab)
- FIRST EPSS (opens in a new tab)
- OSV.dev (opens in a new tab)
- GitHub Advisory GHSA-599f-7c49-w659 (opens in a new tab)
- CIRCL Vulnerability-Lookup (opens in a new tab)
Badge for a README or a ticket
[](https://trackcve.app/cve/CVE-2022-42889)Record last updated .