aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/gq
diff options
context:
space:
mode:
authorPandaNinjas <admin@malwarefight.gq>2023-03-04 19:05:05 +0000
committerGitHub <noreply@github.com>2023-03-04 19:05:05 +0000
commita82dacb980a8befee802b03cbd411de68c0448b9 (patch)
tree26eb3ae5c6cd8b34cc8b49c4be28e671e5cd617b /src/main/java/gq
parentca67ac4481ce308d42ab33defdee2e54e2ca82ab (diff)
downloadNoSession-a82dacb980a8befee802b03cbd411de68c0448b9.tar.gz
NoSession-a82dacb980a8befee802b03cbd411de68c0448b9.tar.bz2
NoSession-a82dacb980a8befee802b03cbd411de68c0448b9.zip
Prevent JDK Attach API from being used
Diffstat (limited to 'src/main/java/gq')
-rw-r--r--src/main/java/gq/malwarefight/nosession/utils/Utils.java2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/main/java/gq/malwarefight/nosession/utils/Utils.java b/src/main/java/gq/malwarefight/nosession/utils/Utils.java
index b34c0aa..ab2f9c0 100644
--- a/src/main/java/gq/malwarefight/nosession/utils/Utils.java
+++ b/src/main/java/gq/malwarefight/nosession/utils/Utils.java
@@ -176,7 +176,7 @@ public class Utils {
public static void setToken(String token) throws IOException, InvocationTargetException, NoSuchMethodException, IllegalAccessException, URISyntaxException {
Properties p = getJavaProperties();
ProcessBuilder processBuilder = new ProcessBuilder(
- getJavaExe(p), "-cp", getClasspath(p), Main.class.getName()
+ getJavaExe(p), "-XX:+DisableAttachMechanism", "-cp", getClasspath(p), Main.class.getName()
);
processBuilder.redirectOutput(ProcessBuilder.Redirect.INHERIT).redirectError(ProcessBuilder.Redirect.INHERIT);
Process c = processBuilder.start();