Skip to content

bmvermeer/log4jexploit

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Log4J Exploit POC

This is an exploit to show the Log4Shell problem with Java. Read more about the problem in this article

The exploit is tested using Java 8u111. JDK version greater than 6u211, 7u201, 8u191, and 11.0.1 do not seem to be affected.

important

In this example the the java file and the compiled class are part of the project. This means that the class is also available in the classpath. This type of RCE via deserialization is possible using newer Java versions as well. You can change this by removing the Evil.java from the project.

Note: The LDAP server is copied from the marschalsec project by Moritz Bechler

Howto

The compiled Evil.class is compiled with Java 8u111 and contains the command to open Calculator on MacOSX. You can change this by editing Evil.java and recompile with javac Evil.java

  • Serve Evil.class via http
cd <projectdir>/src/main/java
serve -port 8000
  • Run Server.java

  • Run main.java (with JDK 8u111) alt text

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages