Prohibit JNDI remote invoke

This commit is contained in:
Glavo
2021-12-11 10:28:02 +08:00
committed by Yuhui Huang
parent bcb29ef792
commit 5ffbd16800

View File

@@ -181,6 +181,9 @@ public class DefaultLauncher extends Launcher {
// Fix RCE vulnerability of log4j2 // Fix RCE vulnerability of log4j2
res.addDefault("-Dlog4j2.formatMsgNoLookups=", "true"); res.addDefault("-Dlog4j2.formatMsgNoLookups=", "true");
res.addDefault("-Djava.rmi.server.useCodebaseOnly=", "true");
res.addDefault("-Dcom.sun.jndi.rmi.object.trustURLCodebase=", "false");
res.addDefault("-Dcom.sun.jndi.cosnaming.object.trustURLCodebase=", "false");
} }
Proxy proxy = options.getProxy(); Proxy proxy = options.getProxy();