Konloch / bytecode-viewer

A Java 8+ Jar & Android APK Reverse Engineering Suite (Decompiler, Editor, Debugger & More)
https://bytecodeviewer.com
GNU General Public License v3.0
14.63k stars 1.14k forks source link

Template and XPosedGenerator Java Plug-ins Throw Errors #476

Open Mili-NT opened 1 year ago

Mili-NT commented 1 year ago

Both of these were tested on the 2.3.1 release of Android-InsecureBankv2 Running the Template.java upon creating a new plug-in throws the following error:

Please send this error log to https://github.com/Konloch/bytecode-viewer/issues or Konloch at https://the.bytecode.club or konloch@gmail.com If you hold appropriate legal rights to the relevant class/jar/apk file please include that as well. Bytecode Viewer Version: 2.11.2 [Fat Jar], OS: Windows 10, Java: 16.0.2

java.lang.NullPointerException: Cannot invoke "java.io.File.equals(Object)" because "from" is null at com.google.common.io.Files.copy(Files.java:325) at the.bytecode.club.bytecodeviewer.plugin.PluginWriter.runPlugin(PluginWriter.java:192) at the.bytecode.club.bytecodeviewer.plugin.PluginWriter.lambda$buildGUI$1(PluginWriter.java:116) at java.desktop/javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:1972) at java.desktop/javax.swing.AbstractButton$Handler.actionPerformed(AbstractButton.java:2313) at java.desktop/javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:405) at java.desktop/javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:262) at java.desktop/javax.swing.plaf.basic.BasicButtonListener.mouseReleased(BasicButtonListener.java:279) at java.desktop/java.awt.Component.processMouseEvent(Component.java:6617) at java.desktop/javax.swing.JComponent.processMouseEvent(JComponent.java:3342) at java.desktop/java.awt.Component.processEvent(Component.java:6382) at java.desktop/java.awt.Container.processEvent(Container.java:2264) at java.desktop/java.awt.Component.dispatchEventImpl(Component.java:4993) at java.desktop/java.awt.Container.dispatchEventImpl(Container.java:2322) at java.desktop/java.awt.Component.dispatchEvent(Component.java:4825) at java.desktop/java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4934) at java.desktop/java.awt.LightweightDispatcher.processMouseEvent(Container.java:4563) at java.desktop/java.awt.LightweightDispatcher.dispatchEvent(Container.java:4504) at java.desktop/java.awt.Container.dispatchEventImpl(Container.java:2308) at java.desktop/java.awt.Window.dispatchEventImpl(Window.java:2773) at java.desktop/java.awt.Component.dispatchEvent(Component.java:4825) at java.desktop/java.awt.EventQueue.dispatchEventImpl(EventQueue.java:772) at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:721) at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:715) at java.base/java.security.AccessController.doPrivileged(AccessController.java:391) at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:85) at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:95) at java.desktop/java.awt.EventQueue$5.run(EventQueue.java:745) at java.desktop/java.awt.EventQueue$5.run(EventQueue.java:743) at java.base/java.security.AccessController.doPrivileged(AccessController.java:391) at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:85) at java.desktop/java.awt.EventQueue.dispatchEvent(EventQueue.java:742) at java.desktop/java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:203) at java.desktop/java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:124) at java.desktop/java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:113) at java.desktop/java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:109) at java.desktop/java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:101) at java.desktop/java.awt.EventDispatchThread.run(EventDispatchThread.java:90)

Running XPosedGenerator.java returns:

Please send this error log to https://github.com/Konloch/bytecode-viewer/issues or Konloch at https://the.bytecode.club or konloch@gmail.com If you hold appropriate legal rights to the relevant class/jar/apk file please include that as well. Bytecode Viewer Version: 2.11.2 [Fat Jar], OS: Windows 10, Java: 16.0.2

java.lang.NullPointerException: Cannot invoke "the.bytecode.club.bytecodeviewer.resources.ResourceContainer.getClassNode(String)" because "this.container" is null at the.bytecode.club.bytecodeviewer.resources.Resource.getResourceClassNode(Resource.java:53) at the.bytecode.club.bytecodeviewer.BytecodeViewer.getCurrentlyOpenedClassNode(BytecodeViewer.java:359) at XposedGenerator.execute(Unknown Source) at the.bytecode.club.bytecodeviewer.api.Plugin.lambda$executeContainer$0(Plugin.java:88) at java.base/java.util.LinkedHashMap$LinkedValues.forEach(LinkedHashMap.java:647) at the.bytecode.club.bytecodeviewer.api.Plugin.executeContainer(Plugin.java:83) at the.bytecode.club.bytecodeviewer.api.Plugin.run(Plugin.java:49)