Metadata-Version: 2.4
Name: ofrak
Version: 3.3.0rc14
Summary: A binary analysis and modification platform
Home-page: https://ofrak.com/
Download-URL: https://github.com/redballoonsecurity/ofrak
Author: Red Balloon Security
Author-email: ofrak@redballoonsecurity.com
License: Proprietary
Project-URL: Documentation, https://ofrak.com/docs/
Project-URL: Community License, https://github.com/redballoonsecurity/ofrak/blob/master/LICENSE
Project-URL: Commercial Licensing Information, https://ofrak.com/license/
Classifier: Programming Language :: Python :: 3
Classifier: Operating System :: OS Independent
Classifier: License :: Other/Proprietary License
Classifier: License :: Free To Use But Restricted
Classifier: License :: Free For Home Use
Classifier: Topic :: Security
Classifier: Typing :: Typed
Requires-Python: >=3.7
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: aiohttp>=3.12.14
Requires-Dist: aiohttp-cors~=0.7.0
Requires-Dist: beartype~=0.20.0
Requires-Dist: bincopy>=20.0.0
Requires-Dist: black>=23.3.0
Requires-Dist: cryptography>=44.0.3
Requires-Dist: fdt>=0.3.3
Requires-Dist: GitPython>=3.1.41
Requires-Dist: importlib-metadata>=4.13
Requires-Dist: intervaltree>=3.1.0
Requires-Dist: keystone-engine>=0.9.2
Requires-Dist: jefferson>=0.4.5; python_version >= "3.8"
Requires-Dist: lief>=0.16.1
Requires-Dist: ofrak_io==1.*,>=1.0
Requires-Dist: ofrak_type==2.*,>=2.2.0rc0
Requires-Dist: ofrak_patch_maker==4.*,>=4.1.0rc0
Requires-Dist: orjson>=3.10.16
Requires-Dist: pefile>=2023.2.7
Requires-Dist: pycdlib>=1.12.0
Requires-Dist: python-magic>=0.4.27; platform_system != "Windows"
Requires-Dist: python-magic-bin>=0.4.14; platform_system == "Windows"
Requires-Dist: reedsolo>=1.7.0
Requires-Dist: sortedcontainers>=2.2.2
Requires-Dist: synthol~=0.1.1
Requires-Dist: tempfile312~=1.0.1
Requires-Dist: typeguard~=2.13.3
Requires-Dist: ubi-reader>=0.8.12
Requires-Dist: xattr>=0.10.1; platform_system != "Windows"
Dynamic: author
Dynamic: author-email
Dynamic: classifier
Dynamic: description
Dynamic: description-content-type
Dynamic: download-url
Dynamic: home-page
Dynamic: license
Dynamic: license-file
Dynamic: project-url
Dynamic: requires-dist
Dynamic: requires-python
Dynamic: summary

# OFRAK
OFRAK (Open Firmware Reverse Analysis Konsole) is a binary analysis and modification platform that combines the ability unpack, analyze, modify, and repack binaries.

OFRAK combines the ability to:

- **Identify** and **Unpack** many binary formats
- **Analyze** unpacked binaries with field-tested reverse engineering tools
- **Modify** and **Repack** binaries with powerful patching strategies

OFRAK supports a range of embedded firmware file formats beyond userspace executables, including:

- Compressed filesystems
- Compressed & checksummed firmware
- Bootloaders
- RTOS/OS kernels

OFRAK equips users with:
- A **Graphical User Interface (GUI)** for interactive exploration and visualization of binaries
- A **Python API** for readable and reproducible scripts that can be applied to entire classes of binaries, rather than just one specific binary
- Recursive **identification, unpacking, and repacking** of many file formats, from ELF executables, to filesystem archives, to compressed and checksummed firmware formats
- Built-in, extensible **integration with powerful analysis backends** (angr, Binary Ninja, Ghidra, IDA Pro)
- **Extensibility by design** via a common interface to easily write additional OFRAK components and add support for a new file format or binary patching operation

See [ofrak.com](https://ofrak.com) for more details.

# Package: ofrak

```
OFRAK
└───ofrak  <-- //YOU ARE HERE//
│   └───component   // Definitions for abstract Component classes (e.g. Analyzer)
│   └───core        // Definitions for standard OFRAK components (plus related tags, views, etc.)
│   └───model       // Definitions for core OFRAK data structures
│   └───service     // Definitions for core OFRAK services
│   
└───ofrak_type
└───ofrak_io
└───ofrak_patch_maker
└───ofrak_tutorial
```

This is the package containing the core of the OFRAK framework. Install this first to get started with OFRAK!

What is included:

- Definitions for core OFRAK data structures and services, such as `Resource`, `OFRAKContext`, and `DataService`.
- Components to handle unpacking, modifying, and repacking common executable file formats:
  - ELF
  - PE Files
- Definitions for common software and reverse engineering abstractions like `Instruction`, `File`, and `BasicBlock`
- Unpackers & Packers for a number of file types, including:
  - APK
  - bzip2
  - CPIO
  - gip
  - ISO 9660
  - LZMA/XZ
  - LZO
  - 7z
  - squashfs
  - tar
  - UImage
  - zip
  - zlib
- Miscellaneous helpful components:
  - `MagicAnalyzer` and two Identifier components which uses `python-libmagic` to automatically tag OFRAK `Resource`s
  - Basic modifiers like `StringFindReplaceModifier` and `BinaryInjectorModifier`
  - Basic useful analyzers like `Sha256Analyzer` and `MD5Analyzer` which calculate the respective checksums of OFRAK `Resource`s
  - An unpacker for Linux device tree blobs (DTB)
  - Analyzers wrapping `strings` and `binwalk`
  - An analyzer to calculate Shannon entropy of binary data

This is only a representative sampling of the features in the core OFRAK. Consult the code reference [docs](https://ofrak.com/docs) for a complete manifest.

What is *not* included:
- The OFRAK PatchMaker
- Components which integrate the disassembler backends (Ghidra, BinaryNinja, Angr, Capstone)

## Testing
This package maintains 100% test coverage of functions.

## License
The code in this repository comes with an [OFRAK Community License](https://github.com/redballoonsecurity/ofrak/blob/master/LICENSE), which is intended for educational uses, personal development, or just having fun.

Users interested in using OFRAK for commercial purposes can request the Pro or Enterprise License. See [OFRAK Licensing](https://ofrak.com/license/) for more information.

## Documentation
OFRAK has general documentation and API documentation, which can be viewed at <https://ofrak.com/docs>.
