Closed MartinKayJr closed 1 week ago
Sounds like a fun idea :slightly_smiling_face: @MartinKayJr sure, you can create an external jadx plugin. I added plugins support just recently, so it very limited right now, but it is possible to add menu item and implement all logic in additional window. You can use https://github.com/jadx-decompiler/jadx-example-plugin project as a template. If you have any question, feel free to ask.
I'll follow up on it
Sounds like a fun idea 🙂 @MartinKayJr sure, you can create an external jadx plugin. I added plugins support just recently, so it very limited right now, but it is possible to add menu item and implement all logic in additional window. You can use https://github.com/jadx-decompiler/jadx-example-plugin project as a template. If you have any question, feel free to ask.
It's very important to add ChatGpt as plugin to auto comment decompliled java code.
It's so powerful that it can save too much times for us.
to add this feature , please support customizing openai api url
for example, this is auto-commented code by chatgpt:
` /**
@param context The application context. */ public MMNotification(Context context) { this.context = null; com.tencent.mm.app.f fVar = com.tencent.mm.app.f.f32130d;
// Listener for RevokeMsgEvent
IListener
@Override
public boolean callback(RevokeMsgEvent revokeMsgEvent) {
MsgInfo msgInfo;
RevokeMsgEvent revokeMsgEvent2 = revokeMsgEvent;
if (revokeMsgEvent2 != null && (msgInfo = revokeMsgEvent2.f35048d.f35051c) != null) {
MMNotification mMNotification = MMNotification.this;
mMNotification.getClass();
if (msgInfo.isSend() == 1) {
// Log a warning for sender notification
Log.warn("MicroMsg.MMNotification", "notifyRevorkMessage is sender, msgid:%d ", Long.valueOf(msgInfo.msgSvrId()));
} else {
int m15 = MMNotification.m(msgInfo);
String content = msgInfo.getContent();
int type = msgInfo.getType();
if (mMNotification.f48482i.preNotificationCheck(msgInfo.talker(), msgInfo, m15, true)) {
mMNotification.msgInfo = msgInfo;
String talker = msgInfo.talker();
mMNotification.f48476a = talker;
mMNotification.f48478d = "";
Log.info("MicroMsg.MMNotification", "notifyRevorkMessage talker:%s msgid:%d type:%d tipsFlag:%d content:%s", talker, Long.valueOf(msgInfo.msgSvrId()), Integer.valueOf(type), Integer.valueOf(m15), Util.secPrint(content));
mMNotification.handler.sendMessageDelayed(mMNotification.wrapMessage(mMNotification.f48476a, content, type, m15, 1), 200L);
} else {
Log.warn("MicroMsg.MMNotification", "[no notification], preNotificationCheck");
}
}
}
return false;
}
};
// Listener for SendMsgFailNotificationEvent
IListener
@Override
public boolean callback(SendMsgFailNotificationEvent sendMsgFailNotificationEvent) {
SendMsgFailNotificationEvent sendMsgFailNotificationEvent2 = sendMsgFailNotificationEvent;
if (sendMsgFailNotificationEvent2 != null) {
sendMsgFailNotificationEvent2.f35176d.getClass();
sendMsgFailNotificationEvent2.f35176d.getClass();
MMNotification.this.showSendMsgFailNotification(null, 0);
}
return false;
}
};
this.f48484l = false; this.context = context; this.f48476a = ""; this.f48478d = ""; this.f48477b = ""; this.f48481g = 0L; this.f48480f = false; this.f48483j = new di.e();
// Add this instance to the listener list synchronized (wb2.h.f297354d) { if (!((ArrayList) wb2.h.f297354d).contains(this)) { ((ArrayList) wb2.h.f297354d).add(this); } }
// Set this instance as the SendMsgFailNotificationEvent listener if (dd0.f.f161839s == null) { dd0.f.f161839s = this; }
// Activate the listeners iListener2.alive(); iListener.alive(); }
`
Owner of project doesn't want to do it right now, he politely suggested that you should add that plugin. GPT-4 is paid, GPT-3 is not as powerful. Conclusion: There is a chance to use reverse engineered bing chat api into jadx or as android studio plugin in combination with smalidea, apktool d .apk, jdbc forward for breakpoints.
Owner of project doesn't want to do it right now, he politely suggested that you should add that plugin. GPT-4 is paid, GPT-3 is not as powerful. Conclusion: There is a chance to use reverse engineered bing chat api into jadx or as android studio plugin in combination with smalidea, apktool d .apk, jdbc forward for breakpoints.
Okay, when I am free, I'll do it by myself. Thank you for reminding
This would be very helpful, glad if someone can implement it!
Owner of project doesn't want to do it right now, he politely suggested that you should add that plugin. GPT-4 is paid, GPT-3 is not as powerful. Conclusion: There is a chance to use reverse engineered bing chat api into jadx or as android studio plugin in combination with smalidea, apktool d .apk, jdbc forward for breakpoints.
Okay, when I am free, I'll do it by myself. Thank you for reminding
A GPT plugin would be very helpful. If you, or anyone, could work on a GPT plugin, take a look at gpt4free
Hello, I recently built a plugin called jadx-ai-view-plugin that provides AI analysis of a class/method in a seperate view. It may be what you are all looking for, it also supports gpt4free as suggested above. Thanks @MartinKayJr for the prompt and thanks @skylot for the help.
@Devilx86 nice, thanks :+1: Also, recently @samanL33T add jadx-xvision-plugin into jadx-plugins-list, it also support LLM integrations into jadx.
I think two plugins is enough, so I will close this issue :slightly_smiling_face:
@Devilx86 This is awesome.
Describe your idea: During my 4-day, about 28-hour test, I manually copied the code into chatgpt, and passed this passage
I need you to be able to handle longer messages.
Let the variable names and method names of the following code change as the name implies, the original meaning of the code cannot be changed, the order cannot be changed, and the unprocessed ones remain as they are, the number of lines of the code cannot be optimized, the code cannot be omitted, the code cannot be deleted or added, and the naming conflict cannot be allowed . The original name should be written above them in the form of a comment, keep the comment. Line comments must be added to Each line of code to explain the meaning of the code, and comments between multiple lines of code also need to be marked.
Let chatgpt restore the semantic analysis of the code. There is no doubt that chatgpt is easy to handler obfuscated code, ollvm, and spend instructions.
This directly defeats all security tools that lower the barrier to analysis.
Originally, it took me 30 days to analyze thousands of classes and 100,000 lines of code. I completed it in 4 days (28 hours) with manual chatgpt.
So I want to connect the gpt engine to jadx, complete the selection of the specified class, analyze the specified class or package, introduce a new code display window to generate for the gpt engine, and use it as a major update in the new era of jadx.
Application scenarios: remove ollvm, remove instructions, automatically rename after semantic analysis, automatically generate comments, etc.