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.6k stars 1.14k forks source link

Exception decompiling #313

Open Miscf opened 3 years ago

Miscf commented 3 years ago

// This method has failed to decompile. When submitting a bug report, please provide this stack trace, and (if you hold appropriate legal rights) the relevant class file. // org.benf.cfr.reader.util.ConfusedCFRException: Tried to end blocks [3[TRYBLOCK]], but top level block is 9[UNCONDITIONALDOLOOP] // org.benf.cfr.reader.bytecode.analysis.opgraph.Op04StructuredStatement.processEndingBlocks(Op04StructuredStatement.java:427) // org.benf.cfr.reader.bytecode.analysis.opgraph.Op04StructuredStatement.buildNestedBlocks(Op04StructuredStatement.java:479) // org.benf.cfr.reader.bytecode.analysis.opgraph.Op03SimpleStatement.createInitialStructuredBlock(Op03SimpleStatement.java:607) // org.benf.cfr.reader.bytecode.CodeAnalyser.getAnalysisInner(CodeAnalyser.java:696) // org.benf.cfr.reader.bytecode.CodeAnalyser.getAnalysisOrWrapFail(CodeAnalyser.java:184) // org.benf.cfr.reader.bytecode.CodeAnalyser.getAnalysis(CodeAnalyser.java:129) // org.benf.cfr.reader.entities.attributes.AttributeCode.analyse(AttributeCode.java:96) // org.benf.cfr.reader.entities.Method.analyse(Method.java:397) // org.benf.cfr.reader.entities.ClassFile.analyseMid(ClassFile.java:906) // org.benf.cfr.reader.entities.ClassFile.analyseTop(ClassFile.java:797) // org.benf.cfr.reader.Driver.doClass(Driver.java:58) // org.benf.cfr.reader.CfrDriverImpl.analyse(CfrDriverImpl.java:67) // org.benf.cfr.reader.Main.main(Main.java:48) // the.bytecode.club.bytecodeviewer.decompilers.CFRDecompiler.decompileClassNode(CFRDecompiler.java:131) // the.bytecode.club.bytecodeviewer.gui.ClassViewer$12.doShit(ClassViewer.java:971) // the.bytecode.club.bytecodeviewer.gui.PaneUpdaterThread.run(PaneUpdaterThread.java:57)

So what causes this?

ThexXTURBOXx commented 3 years ago

I am relatively sure, CFR is causing this issue and we can't do much about it. Which class/jar file are you trying to decompile?

If you don't hold the appropriate legal rights of that file, don't upload it!!! Please send us a link to the file.

Miscf commented 3 years ago

I'm trying to decompile a dex file, sorry i haven’t the linke to the file

Miscf commented 3 years ago

In fact, both CFR and Procyon failed.

ThexXTURBOXx commented 3 years ago

Okay, no problem. There are some problems with dex files atm. We will try to investigate the issue when we find some failing DEX/APK.

ThexXTURBOXx commented 3 years ago

Could you please try if this snapshot fixes your issue? https://github.com/Konloch/bytecode-viewer/suites/3473954380/artifacts/82608578