All Projects → AlexDenisov → Bitcode_retriever

AlexDenisov / Bitcode_retriever

Licence: mit
Retrieves Bitcode from Mach-O binaries

Programming Languages

c
50402 projects - #5 most used programming language

Labels

Projects that are alternatives of or similar to Bitcode retriever

Unity.Blog.Override App Delegate
A maintainable way to extend / override app delegate in Unity iOS / OSX standalone player. (Much) more at http://eppz.eu/blog/override-app-delegate-unity-ios-osx-1/
Stars: ✭ 28 (-82.93%)
Mutual labels:  mach-o
Macho Kit
A C/Objective-C library for parsing Mach-O files.
Stars: ✭ 416 (+153.66%)
Mutual labels:  mach-o
Segment dumper
Simple example of a Mach-O parser
Stars: ✭ 85 (-48.17%)
Mutual labels:  mach-o
machomachomangler
Tools for mangling Mach-O and PE binaries
Stars: ✭ 39 (-76.22%)
Mutual labels:  mach-o
Cydia
🔥🔥🔥我的微信公众号: Cydia 🔥🔥🔥=> Cydia插件 Logos语言 开发Tweak.xm Cydia Substrate 注入dylib iOS逆向工程开发 越狱Jailbreak deb插件 - fishhook / Frida / iOSOpenDev / Cycript / MachOView / IDA / Hopper Disassembler / MonkeyDev / Class-dump / Theos / Reveal / Dumpdecryptd / FLEX / 汇编Assembly / CaptainHook / lldb/LLVM/XNU/Darwin/iOS Reverse
Stars: ✭ 407 (+148.17%)
Mutual labels:  mach-o
Fcd
An optimizing decompiler
Stars: ✭ 622 (+279.27%)
Mutual labels:  mach-o
Hellosilicon
An attempt with ARM64 assembly on Apple Silicon Macs
Stars: ✭ 220 (+34.15%)
Mutual labels:  mach-o
Filebytes
Library to read and edit files in the following formats: Executable and Linking Format (ELF), Portable Executable (PE), MachO and OAT (Android Runtime)
Stars: ✭ 105 (-35.98%)
Mutual labels:  mach-o
Macho Explorer
A graphical Mach-O viewer for macOS. Powered by Mach-O Kit.
Stars: ✭ 406 (+147.56%)
Mutual labels:  mach-o
Tbd
A command-line tool to create Text-Based Application Programming Interface (TAPI) files from existing binaries
Stars: ✭ 82 (-50%)
Mutual labels:  mach-o
rust-macho
Mach-O File Format Parser for Rust
Stars: ✭ 55 (-66.46%)
Mutual labels:  mach-o
Osx Abi Macho File Format Reference
Mirror of OS X ABI Mach-O File Format Reference
Stars: ✭ 379 (+131.1%)
Mutual labels:  mach-o
Machdump
A very basic C Mach-O Header Dump tool written for practicing purposes. Works With x86 and x86_64 binaries
Stars: ✭ 25 (-84.76%)
Mutual labels:  mach-o
SnakeKit
A C++ library for parsing ObjC Metadata of Mach-O files.
Stars: ✭ 26 (-84.15%)
Mutual labels:  mach-o
Macholibre
Mach-O & Universal Binary Parser
Stars: ✭ 102 (-37.8%)
Mutual labels:  mach-o
Wbblades
基于mach-o解析技术的包大小占比分析、无用类检测、无符号表时的日志符号化 (Based on mach-o technology, a simple and efficient code size detection, useless class detection and unsigned crash log detection )
Stars: ✭ 243 (+48.17%)
Mutual labels:  mach-o
Hookcase
Tool for reverse engineering macOS/OS X
Stars: ✭ 452 (+175.61%)
Mutual labels:  mach-o
Rd route
Function hooking for macOS
Stars: ✭ 138 (-15.85%)
Mutual labels:  mach-o
Bingrep
like ~~grep~~ UBER, but for binaries
Stars: ✭ 1,395 (+750.61%)
Mutual labels:  mach-o
Macho Browser
Mac browser for Mach-O binaries (macOS, iOS, watchOS, and tvOS)
Stars: ✭ 77 (-53.05%)
Mutual labels:  mach-o

Bitcode Retriever

Retrieves Bitcode from Mach-O binaries

About

Bitcode stores as an xar archive inside of a Mach-O binary.

This tool extracts the archive and puts it near the binary, so it can be easily discovered using xar and llvm-dis

Build

Clone the repo and run make, built binary lays inside of build directory

$ git clone [email protected]:AlexDenisov/bitcode_retriever.git
$ cd bitcode_retriever
$ make

Usage

Note: currently is does not work with static libraries, there is an opened issue #1, if you need this feature please a comment there, it will bump prioity of this project at my personal todo-list.

To use bitcode_retriever simple feed him your binary and it'll produce archive with bitcode.

It accepts both fat and non-fat binaries. For fat binaries it produces separate archive for each slice, e.g.:

$ bitcode_retriever fat_app
i386.xar
x86_64.xar
arm64.xar

for non-fat binaries it produces just one archive with the bitcode:

$ bitcode_retriever non_fat_app
i386.xar

To skip the xar archive and obtain the bitcode immediately, pass the -e argument.

$ bitcode_retriever -e fat_app
i386.1.bc
i386.2.bc
x86_64.1.bc
x86_64.2.bc

The project provides a sample binaries, you can play a bit with them:

$ make subject
$ cd build
$ ./bitcode_retriever i386.o
# or
$ ./bitcode_retriever fat.o

The xar archive stores set of files with bitcode:

$ xar -xf i386.o
$ ls
i386.o 1 2

You can dump LLVM IR from each file (1, 2) using llvm-dis

$ llvm-dis 1
$ llvm-dis 2
$ ls
1 2 1.ll 2.ll

Bugs and issues

If you have any problems or found some bug - feel free to open an issue and/or send a pull request

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].