log4j2 vulnerability

LearnNewTech
1 min readJan 7, 2022

Vulnerability https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2021-44228 is potentially a big security remote code execution issue. It concerns usage of Log4J2, a popular Java logging library.

Apache Log4j2 2.0-beta9 through 2.15.0 (excluding security releases 2.12.2, 2.12.3, and 2.3.1) JNDI features used in configuration, log messages, and parameters do not protect against attacker controlled LDAP and other JNDI related endpoints. An attacker who can control log messages or log message parameters can execute arbitrary code loaded from LDAP servers when message lookup substitution is enabled. From log4j 2.15.0, this behavior has been disabled by default. From version 2.16.0 (along with 2.12.2, 2.12.3, and 2.3.1), this functionality has been completely removed. Note that this vulnerability is specific to log4j-core and does not affect log4net, log4cxx, or other Apache Logging Services projects.

Preferable Log4j Version Use in your Application:2.17.1

Temporary Fix:

Setting log4j2.formatMsgNoLookups to true by adding: “-Dlog4j2.formatMsgNoLookups=true” to the JVM command for starting your application.

--

--