当前位置:网站首页>Decompile jar files (idea environment)
Decompile jar files (idea environment)
2022-07-26 19:52:00 【xsqsharp】
explain
Want to be right about some jar Decompile files , Because now IDEA More people use it , The more convenient way is , have access to IDEA Decompile the plug-ins in .
IDEA plug-in unit
have access to IDEA Medium "Java Bytecode Decompiler", This plug-in is generally built-in , You can use it directly . Find the location of the plug-in .
Java Bytecode Decompiler Location :D:\DevTools\JetBrains\IntelliJ IDEA 2021.1\plugins\java-decompiler\lib\java-decompiler.jar
To decompile jar Bag location :F:\javadecom\helloworld.jar

Open console , Enter the to decompile jar In the directory of the package , Decompile command :
java -cp "D:/DevTools/JetBrains/IntelliJ IDEA 2021.1/plugins/java-decompiler/lib/java-decompiler.jar" org.jetbrains.java.decompiler.main.decompiler.ConsoleDecompiler -dgs=true F:/javadecom/helloworld.jar data
explain
org.jetbrains.java.decompiler.main.decompiler.ConsoleDecompiler: Is the startup class of the plug-in .
data: Is to decompile jar A folder under the package path , It needs to be created in advance , The decompiled results will be placed in this folder .
Carry out orders , An error appears , As shown in the figure below :

Error details :
F:\javadecom>java -cp "D:/DevTools/JetBrains/IntelliJ IDEA 2021.1/plugins/java-decompiler/lib/java-decompiler.jar" org.jetbrains.java.decompiler.main.decompiler.ConsoleDecompiler -dgs=true F:/javadecom/helloworld.jar data
Error: A JNI error has occurred, please check your installation and try again
Exception in thread "main" java.lang.UnsupportedClassVersionError: org/jetbrains/java/decompiler/main/decompiler/ConsoleDecompiler has been compiled by a more recent version of the Java Runtime (class file version 55.0), this version of the Java Runtime only recognizes class file versions up to 52.0
at java.lang.ClassLoader.defineClass1(Native Method)
at java.lang.ClassLoader.defineClass(Unknown Source)
at java.security.SecureClassLoader.defineClass(Unknown Source)
at java.net.URLClassLoader.defineClass(Unknown Source)
at java.net.URLClassLoader.access$100(Unknown Source)
at java.net.URLClassLoader$1.run(Unknown Source)
at java.net.URLClassLoader$1.run(Unknown Source)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at sun.launcher.LauncherHelper.checkAndLoadMain(Unknown Source)
intend JDK11 Compiled code , Can't use JDK8 Decompile .
You need to download one JDK11, After the download , You can specify the use of JDK11 decompile .
- JDK11 Location :D:\DevTools\Java\jdk-11.0.12\bin\java.exe
Specify the use of JDK11 Decompile command :
D:/DevTools/Java/jdk-11.0.12/bin/java.exe -cp "D:/DevTools/JetBrains/IntelliJ IDEA 2021.1/plugins/java-decompiler/lib/java-decompiler.jar" org.jetbrains.java.decompiler.main.decompiler.ConsoleDecompiler -dgs=true F:/javadecom/helloworld.jar data

After decompilation , Will be in data Generate... In directory jar Decompiled file .

Extract the file , Is decompiled code .
边栏推荐
- Do you know the difference between safety test, functional test and penetration test?
- Zhongtian steel uses tdengine in GPS and AIS scheduling
- The authentication type 10 is not supported
- 金仓数据库 KingbaseES SQL 语言参考手册 (18. SQL语句: DROP MATERIALIZED VIEW 到 DROP SYNONYM)
- eadiness probe failed: calico/node is not ready: BIRD is not ready: Error querying BIRD: unable to c
- MySQL subquery usage
- Detailed explanation of Yolo V2
- Ten sorting details
- Linux regularly backs up the database and deletes the data n days ago
- 论文精读:YOLOV2——YOLO9000:Better, Faster, Stronger
猜你喜欢

YOLO V1详解

Redis6

How to compress the traffic consumption of APP under mobile network in IM development

Fair lock process of reentrantlock learning

canvas概述

MySQL tutorial: MySQL database learning classic (from getting started to mastering)

知识管理系统是什么?你需要知道这些

How to uninstall win11 edge? The method tutorial of completely uninstalling win11 edge browser

这22个绘图(可视化)方法很重要,值得收藏!

Zhongtian steel uses tdengine in GPS and AIS scheduling
随机推荐
DOM案例:10秒倒计时-写跳转页面相关的知识
DDL,DQL,DML语句
6种方法帮你搞定SimpleDateFormat类不是线程安全的问题
聊聊如何用 Redis 实现分布式锁?
Solidity中call函数详解
这22个绘图(可视化)方法很重要,值得收藏!
基于华为云 IOT 设计智能称重系统 (STM32)【一】
C# .net 时间戳和时间转换 支持时区
Is qiniu a channel for securities companies? Is it safe to open an account?
Bug 反馈:同步失败
工作13年后,个人的一点软件测试经历及感想……
客户案例|生学教育依托观测云打造可观测智慧教育新生态
NLP learning path
知识管理系统是什么?你需要知道这些
浅析接口测试
Pads draw 2.54mm row needle
Win11 U盘驱动异常怎么调整为正常?
Talk about how to use redis to realize distributed locks?
PHP 替换中文字符的方法
J1: why is redis so fast + basic structure
