# GHSA-mf4f-j588-5xm8: Apache Log4j Remote Code Execution

> Attackers can execute arbitrary code remotely by controlling log messages in applications using vulnerable Log4j2 versions.

- **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:** 14 Dec 2021

## What is GHSA-mf4f-j588-5xm8?

GHSA-mf4f-j588-5xm8 is a code injection vulnerability in org.opencastproject:opencast-common, published on 14 Dec 2021. An attacker can exploit it over the internet without logging in, with no action from the victim.

### Official description

### Impact

Opencast uses an Apache Log4j2 version which, combined with older JDK versions, can be used for remote code execution attacks which have been found to be actively exploited.

Apache Log4j2 <=2.14.1 JNDI features is not sufficiently protected. An attacker who can control log messages or log message parameters can execute arbitrary code when message lookup substitution is enabled.

### Who is affected

- Opencast before 9.10 or 10.6 are affected
    - Log4j version: all 2.x versions before 2.15.0 are affected

### Patches

The issue has been fixed in Opencast 9.10 and 10.6.

### Workarounds

The vulnerability can be mitigated by setting system property `log4j2.formatMsgNoLookups` to `true`.

### References

- [Opencast pull request mitigating the vulnerability](https://github.com/opencast/opencast/pull/3253)
- [CVE-2021-44228 Detail](https://nvd.nist.gov/vuln/detail/CVE-2021-44228)
- [Analysis and Remediation Guidance to the Log4j Zero-Day RCE (CVE-2021-44228) Vulnerability](https://www.veracode.com/blog/security-news/urgent-analysis-and-remediation-guidance-log4j-zero-day-rce-cve-2021-44228)
- [VE-2021-44228 – Log4j 2 Vulnerability Analysis](https://www.randori.com/blog/cve-2021-44228/)

### For more information

If you have any questions or comments about this advisory:
* Open an issue in [our issue tracker](https://github.com/opencast/opencast/issues)
* Email us at [security@opencast.org](mailto:security@opencast.org)

### Note about dependencies

This issue affects many Java applications. Please also verify these are not vulnerable.

## Which versions are affected by GHSA-mf4f-j588-5xm8?

4 open source packages ship an affected version, including org.opencastproject:opencast-common.


| Package | Ecosystem | Affected | Fixed in |
| --- | --- | --- | --- |
| `org.opencastproject:opencast-common` | Maven | All versions | 9.10 |
| `org.opencastproject:opencast-common` | Maven | All versions | 9.10 |
| `org.opencastproject:opencast-common` | Maven | From 10.0 | 10.6 |
| `org.opencastproject:opencast-common` | Maven | From 10.0 | 10.6 |

## How do I fix GHSA-mf4f-j588-5xm8?

Upgrade org.opencastproject:opencast-common to a fixed version for your release line: 9.10 or 10.6.

## Is GHSA-mf4f-j588-5xm8 being exploited?

There is no known exploitation of GHSA-mf4f-j588-5xm8 in the wild and no public exploit code.

## Fix prompt for AI coding agents

```text
Check this codebase for GHSA-mf4f-j588-5xm8 and fix it if it is affected.

What it is: GHSA-mf4f-j588-5xm8 is a code injection vulnerability in org.opencastproject:opencast-common, published on 14 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-mf4f-j588-5xm8 in the wild and no public exploit code.

Affected packages and fixed versions:
- org.opencastproject:opencast-common (Maven): affected all versions; fixed in 9.10
- org.opencastproject:opencast-common (Maven): affected all versions; fixed in 9.10
- org.opencastproject:opencast-common (Maven): affected from 10.0; fixed in 10.6
- org.opencastproject:opencast-common (Maven): affected from 10.0; fixed in 10.6

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-mf4f-j588-5xm8/ (Markdown: https://insights.sbomify.com/GHSA-mf4f-j588-5xm8/index.md)
```

## Sources

- OSV: https://osv.dev/vulnerability/GHSA-mf4f-j588-5xm8

---
From sbomify Insights: https://insights.sbomify.com/GHSA-mf4f-j588-5xm8/
Summaries are generated and may contain mistakes; the official description above is the record.
