From be65d22009725645c6d58d6dca2326c8994c2853 Mon Sep 17 00:00:00 2001 From: 36083 Date: Thu, 2 Apr 2026 10:59:26 +0800 Subject: [PATCH] this version only test 2026.1 pass --- .idea/go.imports.xml | 10 ++++++++++ .idea/inspectionProfiles/Project_Default.xml | 10 ++++++++++ .idea/vcs.xml | 6 ++++++ pom.xml | 2 +- src/main/java/top/zunmx/MWindow.java | 5 +++-- .../top/zunmx/ModifyDialogWrapperPeerImpl.java | 15 ++++----------- 6 files changed, 34 insertions(+), 14 deletions(-) create mode 100644 .idea/go.imports.xml create mode 100644 .idea/inspectionProfiles/Project_Default.xml create mode 100644 .idea/vcs.xml diff --git a/.idea/go.imports.xml b/.idea/go.imports.xml new file mode 100644 index 0000000..644cdf0 --- /dev/null +++ b/.idea/go.imports.xml @@ -0,0 +1,10 @@ + + + + + + \ No newline at end of file diff --git a/.idea/inspectionProfiles/Project_Default.xml b/.idea/inspectionProfiles/Project_Default.xml new file mode 100644 index 0000000..ace3249 --- /dev/null +++ b/.idea/inspectionProfiles/Project_Default.xml @@ -0,0 +1,10 @@ + + + + \ No newline at end of file diff --git a/.idea/vcs.xml b/.idea/vcs.xml new file mode 100644 index 0000000..35eb1dd --- /dev/null +++ b/.idea/vcs.xml @@ -0,0 +1,6 @@ + + + + + + \ No newline at end of file diff --git a/pom.xml b/pom.xml index 424419c..ffdf00f 100644 --- a/pom.xml +++ b/pom.xml @@ -6,7 +6,7 @@ org.example jetbrains_cracker - 1.0-SNAPSHOT + 1.1-SNAPSHOT jar 1.8 diff --git a/src/main/java/top/zunmx/MWindow.java b/src/main/java/top/zunmx/MWindow.java index 991b4c6..4b88a69 100644 --- a/src/main/java/top/zunmx/MWindow.java +++ b/src/main/java/top/zunmx/MWindow.java @@ -15,6 +15,7 @@ public class MWindow extends Frame { private Thread searchThread; public static boolean stop = false; private static ArrayList file_paths = new ArrayList(); + private static final String package_name = "intellij.platform.ide.impl.jar"; public static String findAppJar(File dir) { File[] files = dir.listFiles(); @@ -28,7 +29,7 @@ public class MWindow extends Frame { if (libFiles != null) { for (File libFile : libFiles) { if (stop) break; - if (libFile.isFile() && libFile.getName().equalsIgnoreCase("app.jar")) { + if (libFile.isFile() && libFile.getName().equalsIgnoreCase(package_name)) { file_paths.add(file.getAbsolutePath()); break lab1; } @@ -57,7 +58,7 @@ public class MWindow extends Frame { public MWindow() { // 设置窗口标题 - super("JetBrains License Cracker V1.0"); + super("JetBrains License Cracker V1.1"); // 设置窗口布局 setLayout(new BorderLayout()); diff --git a/src/main/java/top/zunmx/ModifyDialogWrapperPeerImpl.java b/src/main/java/top/zunmx/ModifyDialogWrapperPeerImpl.java index 144a694..ab00eab 100644 --- a/src/main/java/top/zunmx/ModifyDialogWrapperPeerImpl.java +++ b/src/main/java/top/zunmx/ModifyDialogWrapperPeerImpl.java @@ -12,7 +12,7 @@ import java.util.Enumeration; import java.util.jar.*; public class ModifyDialogWrapperPeerImpl { - public String filename = ""; + public String filename = "intellij.platform.ide.impl.jar"; public String backupPath = ""; public String middlePath = ""; public String bkPath = ""; @@ -21,6 +21,7 @@ public class ModifyDialogWrapperPeerImpl { private URLClassLoader urlClassLoader; private ClassPool pool = null; private LoaderClassPath jarClassPath = null; + private static final String package_name = "intellij.platform.ide.impl.jar"; public boolean deleteDirectory(String dirPath) { File directory = new File(dirPath); @@ -71,15 +72,7 @@ public class ModifyDialogWrapperPeerImpl { } backupPath = dirPath + "\\" + "JCZ-backup"; middlePath = dirPath + "\\" + "JCZ-middle"; - if (new File(dirPath + "\\" + "app-client.jar").exists()) { - filename = "app-client.jar"; - logList.add("[#] app-client.jar found, using it."); - return dirPath + "\\" + "app-client.jar"; - } else { - filename = "app.jar"; - logList.add("[#] app.jar found, using it."); - return dirPath + "\\" + "app.jar"; - } + return dirPath + "\\" + package_name; } public void crack_it(String dirPath, MyList log_list) throws Exception { @@ -115,7 +108,7 @@ public class ModifyDialogWrapperPeerImpl { } setTitleMethod.insertBefore("{ System.out.println(\"即将打开窗口-->\"+$1);" + "boolean isLSW = false;" + - "try {\n"+ + "try {\n" + " if($1.indexOf(\"许可证\")>-1) {isLSW=true; this.dispose();}\n" + " if($1.indexOf(\"Licenses\")>-1) {isLSW=true; this.dispose();}\n" + " if($1.indexOf(\"管理订阅\")>-1) {isLSW=true; this.dispose();}\n" +