Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

ThexXTURBOXx/dex2jar

 
 

Repository files navigation

dex2jar

Workflow status

This is Nico Mexis' fork of the dex2jar project which aims to fix most issues.

Fixed issues

  • Fixed many StringIndexOutOfBoundsExceptions relating to signatures
  • Fixed TypeTransformer related issues
  • Fixed many NullPointerExceptions and other crashes
  • Fixed grammar of error messages
  • Update libraries (especially ASM)
  • Library fat-jar can be used for other projects (Automatically produced by GitHub Actions)
  • Smali now outputs .param instead of the outdated .parameter syntax
  • Reformatted and cleaned up most of the code

Downloads

This fork has builds available in the following formats.
You can also only depend on a single module, if needed. The following sections include all the modules.

Maven

The builds are available on Maven Central.

<dependency>
    <groupId>de.femtopedia.dex2jar</groupId>
    <artifactId>dex2jar</artifactId>
    <version>VERSION</version>
</dependency>

Gradle

The builds are available on Maven Central.

implementation 'de.femtopedia.dex2jar:dex2jar:VERSION'

GitHub Releases

To download the latest builds, head to the Releases.

Note: The builds in Releases are automatically built by GitHub Actions.

Modules

Tools to work with android .dex and java .class files

  1. dex-reader/writer: Read/write the Dalvik Executable (.dex) file. It features a lightweight API similar with ASM .
  2. d2j-dex2jar: Convert .dex file to .class files (zipped as jar)
  3. smali/baksmali: Disassemble dex to smali files and assemble dex from smali files. Different implementation to smali/baksmali, same syntax, but we support escape in type desc "Lcom/dex2jar\t\u1234;"
  4. other tools: d2j-decrypt-string

Usage

  1. In the root directory run: ./gradlew distZip
  2. cd dex-tools/build/distributions
  3. Unzip the file dex-tools-2.4-SNAPSHOT.zip
  4. Run d2j-dex2jar.sh from the unzipped directory

Example usage:

sh d2j-dex2jar.sh -f ~/path/to/apk_to_decompile.apk

And the output file will be apk_to_decompile-dex2jar.jar.

Example Maven project:

See for example the infamous Bytecode Viewer.

Need help ?

Send an email to nico.mexis@kabelmail.de or post on the issue tracker.

License

Apache 2.0

Languages

  • Java 71.6%
  • Smali 24.8%
  • GAP 2.3%
  • Jasmin 0.7%
  • ANTLR 0.5%
  • Shell 0.1%