explaingit

0whitedev/detranspiler

21PythonAudience · developerComplexity · 4/5LicenseSetup · hard

TLDR

A Python tool for reverse engineers that recovers Java source code from compiled native binary files, with optional Ghidra integration and a confidence-scored HTML report.

Mindmap

mindmap
  root((detranspiler))
    What it does
      Recovers Java from native binaries
      Confidence-scored methods
      Multi-step pipeline
    Inputs
      DLL files Windows
      SO files Linux
      Exports imports strings
    Outputs
      Java-like source files
      HTML analysis report
      Interactive class graph
      Per-method C files
    Optional Tools
      Ghidra decompilation
      Java runtime
    Interfaces
      Command-line tool
      Desktop GUI
    Platform
      Windows Linux macOS
Click or tap to explore — scroll the page freely

Code map

Detail Auto

An interactive map of this repo's files and how they connect — its source is parsed live in your browser. Click Visualize to build it.

filefunction / class

Things people build with this

USE CASE 1

Recover readable Java-like source code from a .dll or .so file where the original Java bytecode was compiled into native code.

USE CASE 2

Generate a confidence-scored HTML report and interactive relationship graph showing how Java classes connect to native functions in a protected application.

USE CASE 3

Analyze a transpiler-protected Android app's native library to understand which Java methods were converted and how they map back to JNI calls.

Tech stack

PythonJavaGhidra

Getting it running

Difficulty · hard Time to first run · 1h+

Requires Python 3.10+, a Java runtime for decompilation, and optionally Ghidra which significantly improves results.

Use freely for any purpose including commercial use, as long as you keep the copyright notice.

In plain English

Detranspiler is a Python tool for people who work in reverse engineering and need to recover Java source code from native binary files. Some Java applications ship parts of their logic inside compiled native libraries (files like DLLs on Windows or SO files on Linux) rather than in standard Java bytecode. Detranspiler targets those applications and tries to rebuild readable Java-like source from what is left inside the binary. The tool works as a multi-step pipeline. It reads the native binary, scans its exports, imports, and strings for clues about how Java methods were originally structured, and then calls an optional external tool called Ghidra to decompile the native code into C-like pseudocode. From there it traces how the binary registers and calls Java methods through a standard interface called JNI, and merges everything it finds across several recovery layers to produce the best available version of each method body. The process is designed around cases where a protection tool or transpiler has converted Java bytecode into native code, making the original source hard to read. After a run, the tool produces several outputs: recovered Java-like source files, a human-readable HTML report with recovery metrics, an interactive graph showing how Java classes connect to native functions, and per-method C files linked to their Java declarations. It is honest about confidence, marking each recovered method with a level from minimal to high rather than claiming perfect results. The tool comes with both a command-line interface and an optional desktop GUI. The GUI lets you configure an analysis, browse recovered source files, view the HTML report and the interactive relationship graph, and run environment diagnostics, all without using a terminal. The GUI requires an optional extra install step. Detranspiler is licensed under the MIT license and works on Windows, Linux, and macOS. Python 3.10 or newer is required. A Java runtime is recommended for the decompilation step, and Ghidra is optional but improves results significantly when available.

Copy-paste prompts

Prompt 1
I have a .dll file from a Java application that used native compilation to obfuscate its source. Use detranspiler to analyze it and show me the recovered Java-like source code for the most important methods.
Prompt 2
Walk me through setting up Ghidra integration with detranspiler on Windows so I can improve the confidence scores on recovered Java methods from a native binary.
Prompt 3
I want to understand how detranspiler traces JNI method bindings inside a native binary. Explain the recovery pipeline and show me an example of how it maps a native export back to its original Java method signature.
Open on GitHub → Explain another repo

← 0whitedev on gitmyhub — every repo by this author, as a profile.

Verify against the repo before relying on details.