Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Java Decompiler [closed]

Tags:

Can you recommend a Java decompiler for Eclipse? My other questions is what restrictions is there for using a decompiled code from an other Java program? Illegal or what? I dont know much about licenses. Thanks for reading.

like image 768
MartK Avatar asked Dec 07 '10 09:12

MartK


People also ask

How do I decompile a Java file?

class without source default to Class Decompiler Viewer . Now, click on the class or methods, press F3 , and the plugin will automatically decompile the Java class.

How do you make a jar not Decompoled?

The best you can hope for is to make it very hard to read (replace all symbols with combinations of 'l' and '1' and 'O' and '0', put in lots of useless code and so on).

Is decompiling code possible?

It is impossible use decompilation for original source code reproduction because original code identifiers, such as variable and function names, are rarely stored in computer code. However, code containing metadata or debugging information may include identifiers.


2 Answers

I'd suggest the one that pops up on google, which is the JD Java decompiler. It works really nice.

As for the restrictions, you'd have to read a license of particular software, there might be written that any way of decompilation is forbidden.

like image 152
Mirek Pluta Avatar answered Oct 02 '22 00:10

Mirek Pluta


I like JadClipse - but it shows its age in places. You will need:

  • a jad binary
  • jadClipse installed
  • point the Eclipse preferences to the above jad binary
  • tell it to produce line numbers and align for debugging

There are several shortcomings:

  • code is produced sequentially, if byte code was rearranged so something comes late in the byte code but was early in the original source jad does not rewind to put the disassembled code to the right line.
  • jad does not understand Java 5 + 6 bytecode very well.
like image 40
Thorbjørn Ravn Andersen Avatar answered Oct 02 '22 00:10

Thorbjørn Ravn Andersen