CVE-2023-22665 — jena
MEDIUMCVE-2023-22665 is a medium-severity (CVSS 5.4) Expression Language Injection vulnerability in org.apache.jena:jena. A fix is available for org.apache.jena:jena — see the affected versions and patch details below.
Arbitrary javascript injection in Apache Jena
EPSS Exploitation Probability
Probability of exploitation in the next 30 days, from FIRST.org EPSS.
How urgent is this, really
Where this sits among everything scored
Real-World Exposure
org.apache.jena:jenaReal-time download stats are indexed for npm and PyPI packages. This vulnerability affects Maven packages — download data is not available via public APIs for these ecosystems.
Description
There is insufficient checking of user queries in Apache Jena versions 4.7.0 and earlier, when invoking custom scripts. It allows a remote user to execute arbitrary javascript via a SPARQL query.
Affected Packages
| Ecosystem | Package | Vulnerable range | Fix |
|---|---|---|---|
| ☕Maven | org.apache.jena:jena | all versions | 4.8.0org.apache.jena:jena:4.8.0 |
Affected Products
jenaapacheDetection & mitigation playbook
Open-source dependencyDetect
Scan your dependency tree (package-lock.json, pnpm-lock.yaml, requirements.txt, go.sum, etc.) for org.apache.jena:jena, including transitive dependencies — a direct dependency you never call can still pull in a vulnerable version.
Fix
Update org.apache.jena:jena to 4.8.0 or later, then make sure no transitive (indirect) dependency still pins the vulnerable range — O3 confirms CVE-2023-22665 is resolved across your whole dependency graph.
Workarounds
Stop passing untrusted input into the interpreter or shell: call the affected binary with an argument array rather than a composed command string, reject anything outside a strict allowlist of expected values, and run the component under an account that cannot reach beyond the work it legitimately does.
Frequently Asked Questions
Is CVE-2023-22665 in your dependencies?
Find it across Maven, including transitive dependencies.