All Projects → decomp → Decomp

decomp / Decomp

Licence: unlicense
Components of a decompilation pipeline.

Programming Languages

go
31211 projects - #10 most used programming language
golang
3204 projects

Projects that are alternatives of or similar to Decomp

Replica
Ghidra Analysis Enhancer 🐉
Stars: ✭ 194 (-43.44%)
Mutual labels:  decompiler, binary-analysis, reverse-engineering
Rellic
Rellic produces goto-free C output from LLVM bitcode
Stars: ✭ 234 (-31.78%)
Mutual labels:  llvm, decompiler, reverse-engineering
sleigh
Unofficial CMake build for Ghidra SLEIGH
Stars: ✭ 54 (-84.26%)
Mutual labels:  decompiler, binary-analysis
doc
Design documents related to the decompilation pipeline.
Stars: ✭ 23 (-93.29%)
Mutual labels:  llvm, decompiler
Ddisasm
A fast and accurate disassembler
Stars: ✭ 325 (-5.25%)
Mutual labels:  binary-analysis, reverse-engineering
Bin2llvm
A binary to LLVM translator
Stars: ✭ 108 (-68.51%)
Mutual labels:  llvm, reverse-engineering
Mcsema
Framework for lifting x86, amd64, aarch64, sparc32, and sparc64 program binaries to LLVM bitcode
Stars: ✭ 2,198 (+540.82%)
Mutual labels:  llvm, binary-analysis
BEFA-Library
High-level library for executable binary file analysis
Stars: ✭ 14 (-95.92%)
Mutual labels:  decompiler, binary-analysis
Tigress protection
Playing with the Tigress binary protection. Break some of its protections and solve some of its challenges. Automatic deobfuscation using symbolic execution, taint analysis and LLVM.
Stars: ✭ 550 (+60.35%)
Mutual labels:  llvm, reverse-engineering
Freki
🐺 Malware analysis platform
Stars: ✭ 285 (-16.91%)
Mutual labels:  binary-analysis, reverse-engineering
Boomerang
Boomerang Decompiler - Fighting the code-rot :)
Stars: ✭ 265 (-22.74%)
Mutual labels:  decompiler, reverse-engineering
Macbook
《macOS软件安全与逆向分析》随书源码
Stars: ✭ 302 (-11.95%)
Mutual labels:  binary-analysis, reverse-engineering
S2e
S2E: A platform for multi-path program analysis with selective symbolic execution.
Stars: ✭ 102 (-70.26%)
Mutual labels:  llvm, reverse-engineering
Qbdi
A Dynamic Binary Instrumentation framework based on LLVM.
Stars: ✭ 801 (+133.53%)
Mutual labels:  llvm, reverse-engineering
Fcd
An optimizing decompiler
Stars: ✭ 622 (+81.34%)
Mutual labels:  llvm, decompiler
anvill
anvill forges beautiful LLVM bitcode out of raw machine code
Stars: ✭ 228 (-33.53%)
Mutual labels:  llvm, decompiler
Idenlib
idenLib - Library Function Identification [This project is not maintained anymore]
Stars: ✭ 322 (-6.12%)
Mutual labels:  binary-analysis, reverse-engineering
Dnpatch
.NET Patcher library using dnlib
Stars: ✭ 249 (-27.41%)
Mutual labels:  decompiler, reverse-engineering
Bytecoder
Rich Domain Model for JVM Bytecode and Framework to interpret and transpile it.
Stars: ✭ 401 (+16.91%)
Mutual labels:  llvm, decompiler
B2r2
B2R2 is a collection of useful algorithms, functions, and tools for binary analysis.
Stars: ✭ 262 (-23.62%)
Mutual labels:  binary-analysis, reverse-engineering

The decomp project

Build Status Coverage Status GoDoc

The aim of this project is to implement a decompilation pipeline composed of independent components interacting through well-defined interfaces, as further described in the design documents of the project.

Installation

go get github.com/decomp/decomp/...

Usage

See example usage at examples/demo, and this comment for further details.

Decompilation pipeline

From a high-level perspective, the components of the decompilation pipeline are conceptually grouped into three modules. Firstly, the front-end translates a source language (e.g. x86 assembly) into LLVM IR; a platform-independent low-level intermediate representation. Secondly, the middle-end structures the LLVM IR by identifying high-level control flow primitives (e.g. pre-test loops, 2-way conditionals). Lastly, the back-end translates the structured LLVM IR into a high-level target programming language (e.g. Go).

The following poster summarizes the current capabilities of the decompilation pipeline, using a composition of independent components to translate LLVM IR to Go.

Poster: Compositional Decompilation

Front-end

Translate machine code (e.g. x86 assembly) to LLVM IR.

Third-party front-end components.

Middle-end

Perform control flow analysis on the LLVM IR to identify high-level control flow primitives (e.g. pre-test loops).

ll2dot

https://godoc.org/github.com/decomp/decomp/cmd/ll2dot

Control flow graph generation tool.

Generate control flow graphs from LLVM IR assembly (*.ll -> *.dot).

restructure

https://godoc.org/github.com/decomp/decomp/cmd/restructure

Control flow recovery tool.

Recover control flow primitives from control flow graphs (*.dot -> *.json).

Back-end

Translate structured LLVM IR to a high-level target language (e.g. Go).

ll2go

https://godoc.org/github.com/decomp/decomp/cmd/ll2go

Go code generation tool.

Decompile LLVM IR assembly to Go source code (*.ll -> *.go).

go-post

https://godoc.org/github.com/decomp/decomp/cmd/go-post

Go post-processing tool.

Post-process Go source code to make it more idiomatic (*.go -> *.go).

Release history

Version 0.2 (2018-01-30)

Primary focus of version 0.2: project-wide compilation speed.

Developing decompilation components should be fun.

There seem to be an inverse correlation between depending on a huge C++ library and having fun developing decompilation components.

Version 0.2 of the decompilation pipeline strives to resolve this issue by leveraging an LLVM IR library written in pure Go. Prior to this release, project-wide compilation could take several hours to complete. Now, they complete in less than 1 minute -- the established hard limit for all future releases.

Version 0.1 (2015-04-21)

Initial release.

Primary focus of version 0.1: compositional decompilation.

Decompilers should be composable and open source.

A decompilation pipeline should be composed of individual components, each with a single purpose and well-defined input and output.

Version 0.1 of the decomp project explores the feasibility of composing a decompilation pipeline from independent components, and the potential of exposing those components to the end-user.

For further background, refer to the Compositional Decompilation using LLVM IR design document.

Roadmap

Version 0.3 (to be released)

Primary focus of version 0.3: type-aware binary lifting.

Decompilers rely on high-quality binary lifting.

The quality of the output IR of the binary lifting front-end fundamentally determines the quality of the output of the entire decompilation pipeline.

Version 0.3 aims to improve the quality of the output LLVM IR by implementing a type-aware binary lifting front-end.

Version 0.4 (to be released)

Primary focus of version 0.4: control flow analysis.

Decompilers should recover high-level control flow primitives.

One of the primary differences between low-level assembly and high-level source code is the use of high-level control flow primitives; e.g. 1-way, 2-way and n-way conditionals (if, if-else and switch), pre- and post-test loops (while and do-while).

Version 0.4 seeks to recover high-level control flow primitives using robust control flow analysis algorithms.

Version 0.5 (to be released)

Primary focus of version 0.5: fault tolerance.

Decompilers should be robust.

Decompilation components should respond well to unexpected states and incomplete analysis.

Version 0.5 focuses on stability, and seeks to stress test the decompilation pipeline using semi-real world software (see the challenge issue series).

Version 0.6 (to be released)

Primary focus of version 0.6: data flow analysis.

Version 0.7 (to be released)

Primary focus of version 0.7: type analysis.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].