MachO/ObjC Analysis + Editing toolkit.
Installation
# Installing
pip3 install k2l
# Updating
pip3 install --upgrade k2l
Usage
ktool is both a convenient CLI toolkit and a library that can be used in other tools.
CLI Usage
> $ ktool
Usage: ktool <global flags> [command] <flags> [filename]
Commands:
GUI (Still in active development) ---
ktool open [filename] - Open the ktool command line GUI and browse a file
MachO Analysis ---
dump - Tools to reconstruct certain files (headers, .tbds) from compiled MachOs
json - Dump image metadata as json
cs - Codesigning info
kcache - Kernel cache specific tools
list - Print various lists (ObjC Classes, etc.)
symbols - Print various tables (Symbols, imports, exports)
info - Print misc info about the target mach-o
MachO Editing ---
insert - Utils for inserting load commands into MachO Binaries
edit - Utils for editing MachO Binaries
lipo - Utilities for combining/separating slices in fat MachO files.
Misc Utilities ---
file - Print very basic info about the MachO
img4 - IMG4 Utilities
Run `ktool [command]` for info/examples on using that command
Global Flags:
-f - Force Load (ignores malformations in the MachO and tries to load whatever it can)
-v [-1 through 5] - Log verbosiy. -1 completely silences logging.
-V - Print version string (`ktool -V | cat`) to disable the animation
Library
Library documentation is located here
written in pure, 100% python for the sake of platform independence when operating on static binaries and libraries. this should run on any and all implementations of python3.
Tested on:
- Windows/Windows on ARM64
- MacOS x86/arm64
- Linux/Linux ARM64
- iOS (iSH, ssh)
- Android (Termux)
- WebAssembly
- Brython
Special thanks to
JLevin and *OS Internals for existing
arandomdev for guidance + code
Blacktop for their amazing ipsw project: https://github.com/blacktop/ipsw
Artists behind the images used in this project's logo: https://github.com/0cyn/ktool/tree/master/EXTERNAL_LICENSES#image-notes
Metadata
Release files for k2l 2.0.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| k2l-2.0.0.tar.gz | 97.6 kB | Without provenance | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| k2l-2.0.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 205.8 kB
Release files / k2l-2.0.0.tar.gz
| Download URL | k2l-2.0.0.tar.gz |
|---|---|
| Size | 97.6 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
eba4058f1badb24eda1eae0b341fa2134b73b2e9e140192c6a427762fb07d758
|
|
BLAKE2b-256 checksum How to use checksums |
8035fb6db12c0fae6cbdce5832ceb6ae1238e6b20aa4d6b7108ce61ad9e110c5
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.7.1 CPython/3.11.6 Darwin/23.1.0
|
Release files / k2l-2.0.0-py3-none-any.whl
| Download URL | k2l-2.0.0-py3-none-any.whl |
|---|---|
| Size | 108.1 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
029dc75e1715f0ce0f0893adf413cbaf834dca3234d8658cf47100c19342a063
|
|
BLAKE2b-256 checksum How to use checksums |
19da0ef5204e17a16fa177d65b47749730c59397fc46ba52181a48288c4fbea8
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.7.1 CPython/3.11.6 Darwin/23.1.0
|
Security for k2l 2.0.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.