# GHSA-xxfh-x98p-j8fr: Remote code injection in Log4j (through pax-logging-log4j2)

> Attackers can execute arbitrary code remotely via Log4j injection in pax-logging, requiring immediate library upgrades.

- **Severity:** Not scored
- **Exploited in the wild:** Not known
- **Login needed:** Not needed
- **Attackable:** Over the internet
- **Victim action needed:** Not needed
- **Fix available:** Yes
- **Published:** 10 Dec 2021

## What is GHSA-xxfh-x98p-j8fr?

GHSA-xxfh-x98p-j8fr is a code injection vulnerability in org.ops4j.pax.logging:pax-logging-log4j2, published on 10 Dec 2021. An attacker can exploit it over the internet without logging in, with no action from the victim.

### Official description

### Impact
Remote Code Execution.

### Patches
Users of pax-logging 1.11.9 should update to 1.11.10.
Users of pax-logging 2.0.10 should update to 2.0.11.

### Workarounds
Set system property `-Dlog4j2.formatMsgNoLookups=true`

### References
https://github.com/advisories/GHSA-jfh8-c2jp-5v3q

## Which versions are affected by GHSA-xxfh-x98p-j8fr?

4 open source packages ship an affected version, including org.ops4j.pax.logging:pax-logging-log4j2.


| Package | Ecosystem | Affected | Fixed in |
| --- | --- | --- | --- |
| `org.ops4j.pax.logging:pax-logging-log4j2` | Maven | All versions | 1.11.10 |
| `org.ops4j.pax.logging:pax-logging-log4j2` | Maven | All versions | 1.11.10 |
| `org.ops4j.pax.logging:pax-logging-log4j2` | Maven | From 2.0.0 | 2.0.11 |
| `org.ops4j.pax.logging:pax-logging-log4j2` | Maven | From 2.0.0 | 2.0.11 |

## How do I fix GHSA-xxfh-x98p-j8fr?

Upgrade org.ops4j.pax.logging:pax-logging-log4j2 to a fixed version for your release line: 1.11.10 or 2.0.11.

## Is GHSA-xxfh-x98p-j8fr being exploited?

There is no known exploitation of GHSA-xxfh-x98p-j8fr in the wild and no public exploit code.

## Fix prompt for AI coding agents

```text
Check this codebase for GHSA-xxfh-x98p-j8fr and fix it if it is affected.

What it is: GHSA-xxfh-x98p-j8fr is a code injection vulnerability in org.ops4j.pax.logging:pax-logging-log4j2, published on 10 Dec 2021. An attacker can exploit it over the internet without logging in, with no action from the victim.
Exploitation: There is no known exploitation of GHSA-xxfh-x98p-j8fr in the wild and no public exploit code.

Affected packages and fixed versions:
- org.ops4j.pax.logging:pax-logging-log4j2 (Maven): affected all versions; fixed in 1.11.10
- org.ops4j.pax.logging:pax-logging-log4j2 (Maven): affected all versions; fixed in 1.11.10
- org.ops4j.pax.logging:pax-logging-log4j2 (Maven): affected from 2.0.0; fixed in 2.0.11
- org.ops4j.pax.logging:pax-logging-log4j2 (Maven): affected from 2.0.0; fixed in 2.0.11

Task:
1. Search the dependency manifests and lockfiles (for example package.json, package-lock.json, requirements.txt, poetry.lock, uv.lock, pom.xml, build.gradle, go.mod, Cargo.lock, Gemfile.lock) and any Dockerfiles for the affected packages, including transitive dependencies.
2. If an affected version is in use, upgrade it to the fixed version for its release line with the project's package manager, so the lockfile is regenerated. Prefer the smallest upgrade that fixes it.
3. If there is no fix, or the upgrade would break the build, do not guess: explain the risk and the safest workaround instead.
4. Run the tests and summarise what changed and why.
5. If nothing in the project is affected, say so and change nothing.

Reference: https://insights.sbomify.com/GHSA-xxfh-x98p-j8fr/ (Markdown: https://insights.sbomify.com/GHSA-xxfh-x98p-j8fr/index.md)
```

## Sources

- OSV: https://osv.dev/vulnerability/GHSA-xxfh-x98p-j8fr

---
From sbomify Insights: https://insights.sbomify.com/GHSA-xxfh-x98p-j8fr/
Summaries are generated and may contain mistakes; the official description above is the record.
