jad
是一个C++编写的跨平台的Java反编译命令行工具,可使用jad
命令反编译class文件,jad
最新版本是发布于2006年的1.5.8g
,距今,已有14年没更新了。
反编译示例:jad TestHelloWorld.class
JAD
参数如下:
Jad accepts the following options:
-a - annotate the output with JVM bytecodes (default: off)
-af - same as -a, but output fully qualified names when annotating
-clear - clear all prefixes, including the default ones (can be abbreviated as -cl)
-b - output redundant braces (e.g., if(a) { b(); }, default: off)
-d
- directory for output files (will be created when necessary)
-dead - try to decompile dead parts of code (if any) (default: off)
-disass - disassemble method bytecodes (no JAVA source generated)
-f - output fully qualified names for classes/fields/methods (default: off)
-ff - output class fields before methods (default: after methods)
-i - output default initializers for all non-final fields
-l - split strings into pieces of maximum chars (default: off)
-lnc - annotate the output with line numbers (default: off)
-lradix - display long integers using the specified radix (8, 10 or 16)
-nl - split strings on newline character (default: off)
-nocast - don't generate auxiliary casts
-nocode - don't generate the source code for methods
-noconv - don't convert Java identifiers (default: convert)
-noctor - suppress the empty constructors
-nodos - do not check for class files written in DOS mode (CR before NL, default: check)
-nofd - don't disambiguate fields with the same names by adding signatures to their names (default: do)
-noinner - turn off the support of inner classes (default: on)
-nolvt - ignore Local Variable Table information
-nonlb - don't output a newline before opening brace (default: do)
-o - overwrite output files without confirmation (default: off)
-p - send decompiled code to STDOUT (e.g., for piping)
-pi - pack imports into one line after imports (default: 3)
-pv - pack fields with identical types into one line (default: off)
-pa - prefix for all packages in generated source files
-pc - prefix for classes with numerical names (default: _cls)
-pf - prefix for fields with numerical names (default: _fld)
-pe - prefix for unused exception names (default: _ex)
-pl - prefix for locals with numerical names (default: _lcl)
-pm - prefix for methods with numerical names (default: _mth)
-pp - prefix for method parms with numerical names (default: _prm)
-r - restore package directory structrure
-radix - display integers using the specified radix (8, 10 or 16)
-s - output file extension (by default '.jad')
-safe - generate additional casts to disambiguate methods/fields (default: off)
-space - output space between keyword (if/for/while/etc) and expression (default: off)
-stat - display the total number of processed classes/methods/fields
-t - use tabs instead of spaces for indentation
-t - use spaces for indentation (default: 4)
-v - display method names being decompiled
-8 - convert UNICODE strings into 8-bit strings
using the current ANSI code page (Win32 only)
-& - redirect STDERR to STDOUT (Win32 only)
官方网站:http://www.kpdus.com/jad.html#general
版本下载:http://www.javadecompilers.com/jad