I am trying to remove all the vulnerable log4j dependencies from my maven project.
I am using log4j 2.16 dependency in my pom and have added exclusions for log4j and sl4j in other dependencies.
Still, whenever I run the maven package goal it downloads log4j 1.2.12 jar.
[INFO] Copying 1 resource
[INFO]
[INFO] --- maven-compiler-plugin:3.1:compile (default-compile) @ Test ---
Downloading: https://repo.maven.apache.org/maven2/log4j/log4j/1.2.12/log4j-1.2.12.pom
Downloaded: https://repo.maven.apache.org/maven2/log4j/log4j/1.2.12/log4j-1.2.12.pom (145 B at 0.1 KB/sec)
Downloading: https://repo.maven.apache.org/maven2/log4j/log4j/1.2.12/log4j-1.2.12.jar
Downloaded: https://repo.maven.apache.org/maven2/log4j/log4j/1.2.12/log4j-1.2.12.jar (350 KB at 101.6 KB/sec)
I even ran the mvn dependency:tree
command and it only shows log4j 2.16.
What could be the cause for it to download log4j 1.2.12 jar?