mirror of
https://github.com/TheOfficialFloW/bd-jb
synced 2024-11-24 18:02:19 -05:00
Move security manager checks.
This commit is contained in:
parent
fab3db6d51
commit
1d8fab5dd3
@ -29,8 +29,7 @@ class Exploit implements Runnable {
|
||||
|
||||
for (int i = 0; i < exploits.length; i++) {
|
||||
try {
|
||||
exploits[i].trigger();
|
||||
if (System.getSecurityManager() == null) {
|
||||
if (exploits[i].trigger()) {
|
||||
break;
|
||||
}
|
||||
} catch (Exception e) {
|
||||
|
@ -57,6 +57,6 @@ public class ExploitServiceProxyImpl implements ExploitSandboxInterface {
|
||||
Class payloadClass = urlClassLoader.loadClass(PAYLOAD_CLASS_NAME);
|
||||
payloadClass.newInstance();
|
||||
|
||||
return true;
|
||||
return System.getSecurityManager() == null;
|
||||
}
|
||||
}
|
||||
|
@ -44,7 +44,7 @@ public class ExploitUserPrefsImpl implements ExploitSandboxInterface {
|
||||
// Instantiate the payload class.
|
||||
PayloadClassLoader.getInstance().newPayload();
|
||||
|
||||
return true;
|
||||
return System.getSecurityManager() == null;
|
||||
}
|
||||
} finally {
|
||||
// Restore userprefs file.
|
||||
|
Loading…
Reference in New Issue
Block a user