mirror of
https://github.com/qi4L/JYso.git
synced 2026-09-23 15:21:52 +08:00
base64编码输出Payload
This commit is contained in:
@@ -9,6 +9,7 @@ import com.qi4l.jndi.gadgets.utils.StringUtil;
|
||||
import com.qi4l.jndi.gadgets.utils.dirty.DirtyDataWrapper;
|
||||
import org.apache.commons.cli.*;
|
||||
|
||||
import java.io.ByteArrayOutputStream;
|
||||
import java.io.FileOutputStream;
|
||||
import java.io.OutputStream;
|
||||
import java.util.*;
|
||||
@@ -19,7 +20,7 @@ import static com.qi4l.jndi.gadgets.utils.StringUtil.isFromExploit;
|
||||
public class ysoserial {
|
||||
|
||||
public static CommandLine cmdLine;
|
||||
public static Object PAYLOAD = null;
|
||||
public static Object PAYLOAD = null;
|
||||
|
||||
public static void ysoserial(String[] args) {
|
||||
final Options options = getOptions();
|
||||
@@ -68,6 +69,10 @@ public class ysoserial {
|
||||
Config.FILE = cmdLine.getOptionValue("file");
|
||||
}
|
||||
|
||||
if (cmdLine.hasOption("base64")) {
|
||||
Config.BASE64 = true;
|
||||
}
|
||||
|
||||
if (cmdLine.hasOption("password")) {
|
||||
Config.PASSWORD_ORI = cmdLine.getOptionValue("password");
|
||||
Config.PASSWORD = generatePassword(Config.PASSWORD_ORI);
|
||||
@@ -172,6 +177,7 @@ public class ysoserial {
|
||||
}
|
||||
System.exit(0);
|
||||
}
|
||||
|
||||
private static Options getOptions() {
|
||||
Options options = new Options();
|
||||
options.addOption("y", "ysoserial", false, "Java deserialization");
|
||||
@@ -199,6 +205,7 @@ public class ysoserial {
|
||||
options.addOption("utf", "utf8-Overlong-Encoding", false, "UTF-8 Overlong Encoding Bypass waf");
|
||||
options.addOption("he1", "Hessian1", false, "Hessian1 Output");
|
||||
options.addOption("he2", "Hessian2", false, "Hessian2 Output");
|
||||
options.addOption("b64", "base64", false, "base64 encoding");
|
||||
return options;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user