Powered by HTML coding Best viewed with |
Home Project page Applet Download FAQ Feedback Documentation License History Links Blue Sky |
Someday I found guavad
, a disassembler for java byte
code (it does similar things like javap -c
). I used
it on a class file, and found that it was possible to reconstruct the
original java code. First I did it by hand on some small routines,
but I soon realized that it was a rather stupid task. So I wrote a
small perl
script that
did this process automatically. At the end of the next day I had my
first working decompiler.
Now while the perl
script is working, it is not easy
to use. You have to decompile the code first with a disassembler, cut
out the code of a single method, and run the perl script on it. I
decided to get the bytecode directly out of the class files and do
this all automatically. I decided to write it in java
now, because it suited best.
Just for the records: the java code is now more than 50 times bigger than the original perl script and is still growing.