CriticalGHSA-7rjr-3q55-vv33CVE-2021-45046

Incomplete fix for Apache Log4j vulnerability

Published 14 Dec 2021 · Updated 2 Oct 2026

Is your project on an affected org.apache.logging.log4j:log4j-core?

Private repo? Upload its lockfile instead, or connect GitHub to check every repo.

Look after several Java apps? Indie watches up to 15 repos, private ones too, for $5 a month. See Indie

Affected packages

Affected
>=2.13.0 <2.16.0
Fixed in
2.16.0
Update to the fixed version for your release line, for example:mvn versions:use-dep-version -Dincludes=org.apache.logging.log4j:log4j-core -DdepVersion=2.16.0 -DforceVersion=true
Affected
>=2.4.0 <2.12.2
Fixed in
2.12.2
Update to the fixed version for your release line, for example:mvn versions:use-dep-version -Dincludes=org.apache.logging.log4j:log4j-core -DdepVersion=2.12.2 -DforceVersion=true
Affected
>=1.8.0 <1.9.2
Fixed in
1.9.2
Update to the fixed version for your release line, for example:mvn versions:use-dep-version -Dincludes=org.ops4j.pax.logging:pax-logging-log4j2 -DdepVersion=1.9.2 -DforceVersion=true
Affected
>=1.10.0 <1.10.8
Fixed in
1.10.8
Update to the fixed version for your release line, for example:mvn versions:use-dep-version -Dincludes=org.ops4j.pax.logging:pax-logging-log4j2 -DdepVersion=1.10.8 -DforceVersion=true
Affected
>=1.11.0 <1.11.11
Fixed in
1.11.11
Update to the fixed version for your release line, for example:mvn versions:use-dep-version -Dincludes=org.ops4j.pax.logging:pax-logging-log4j2 -DdepVersion=1.11.11 -DforceVersion=true
Affected
>=2.0.0 <2.0.12
Fixed in
2.0.12
Update to the fixed version for your release line, for example:mvn versions:use-dep-version -Dincludes=org.ops4j.pax.logging:pax-logging-log4j2 -DdepVersion=2.0.12 -DforceVersion=true
Affected
<2.3.1
Fixed in
2.3.1
Update to the fixed version for your release line, for example:mvn versions:use-dep-version -Dincludes=org.apache.logging.log4j:log4j-core -DdepVersion=2.3.1 -DforceVersion=true

Details

Impact

The fix to address CVE-2021-44228 in Apache Log4j 2.15.0 was incomplete in certain non-default configurations. This could allow attackers with control over Thread Context Map (MDC) input data when the logging configuration uses a non-default Pattern Layout with either a Context Lookup (for example, $${ctx:loginId}) or a Thread Context Map pattern (%X, %mdc, or %MDC) to craft malicious input data using a JNDI Lookup pattern resulting in a remote code execution (RCE) attack.

Affected packages

Only the org.apache.logging.log4j:log4j-core package is directly affected by this vulnerability. The org.apache.logging.log4j:log4j-api should be kept at the same version as the org.apache.logging.log4j:log4j-core package to ensure compatability if in use.

Mitigation

Log4j 2.16.0 fixes this issue by removing support for message lookup patterns and disabling JNDI functionality by default. This issue can be mitigated in prior releases (< 2.16.0) by removing the JndiLookup class from the classpath (example: zip -q -d log4j-core-*.jar org/apache/logging/log4j/core/lookup/JndiLookup.class).

Log4j 2.15.0 restricts JNDI LDAP lookups to localhost by default. Note that previous mitigations involving configuration such as to set the system property log4j2.formatMsgNoLookups to true do NOT mitigate this specific vulnerability.

Is GHSA-7rjr-3q55-vv33 in any of your client repos?

Checking one package by hand is fine. Checking it across forty client projects is not. NPMscan reads the lockfiles in every GitHub repo you pick, finds each project with an affected org.apache.logging.log4j:log4j-core, and gives you the command that fixes it.

More advisories for org.apache.logging.log4j:log4j-core

  • MediumCVE-2026-34479Apache Log4j 1 to Log4j 2 bridge: silent log event loss in Log4j1XmlLayout due to unescaped XML 1.0 forbidden characters · 10 Apr 2026
  • MediumCVE-2026-34480Apache Log4j Core: Silent log event loss in XmlLayout due to unescaped XML 1.0 forbidden characters · 10 Apr 2026
  • MediumCVE-2026-34478Apache Log4j Core: log injection in `Rfc5424Layout` due to silent configuration incompatibility · 10 Apr 2026
  • MediumCVE-2026-34477Apache Log4j Core: `verifyHostName` attribute silently ignored in TLS configuration · 10 Apr 2026
  • MediumCVE-2025-68161Apache Log4j does not verify the TLS hostname in its Socket Appender · 18 Dec 2025
  • HighCVE-2023-26464Apache Log4j 1.x (EOL) allows Denial of Service (DoS) · 10 Mar 2023
All 12 advisories for org.apache.logging.log4j:log4j-core

References

Advisory data from OSV.dev (opens OSV.dev in a new tab), refreshed daily.