Piotr: Pythonic IoT exploitation and Research
System dependencies
$ apt install qemu-system-arm
Introduction to Piotr
Piotr is an emulation helper for Qemu that provides a convenient way to create, share and run virtual IoT devices. It only supports the ARM Architecture at the moment.
Piotr is heavily inspired from @therealsaumil’s ARM-X framework and keeps the same approach: emulated devices run inside an emulated host that provides all the tools you may need and creates a fake environment for them. This approach allows remote debugging with gdbserver or fridaserver, provides a steady platform for vulnerability research, exploitation and training.
Moreover, Piotr is able to package any emulated device into a single file that may be shared and imported by other users, thus sharing its kernel, DTB file or even its host filesystem. This way, it is possible to create new emulated devices based upon existing ones, and to improve all of them by simply changing a single file (kernel, host filesystem, etc.).
How does Piotr work ?
Piotr stores everything it needs inside a specific user directory called .piotr, located in the user’s home directory. This directory stores all the kernels, dtb files, host filesystems and emulated devices.
Each emulated device is stored in a specific subdirectory of your .piotr/devices directory, and must contain at least:
a config.yaml file containing the device’s qemu configuration in a readable way
a root filesystem with correct permissions and groups and users
When Piotr is asked to emulate a specific device, it loads its config.yaml file, parses it and creates a Qemu emulated device with the corresponding specifications.
This emulated device can then be driven by Piotr’s helper tools in order to:
list or kill running processes
dynamically configure network interfaces
debug any process running on the emulated device
…
Documentation
Piotr complete documentation is available at https://piotr.readthedocs.io/en/latest/. If you want to start using Piotr as soon as possible, we recommend you to read our Quickstart guide !
License
Piotr is released under the MIT license, see LICENSE for more information.
Metadata
Release files for piotr 1.0.2
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 | Actions |
|---|---|---|---|---|
| piotr-1.0.2.tar.gz | 30.5 MB | Without provenance | Details for piotr-1.0.2.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| piotr-1.0.2-py3-none-any.whl | Python 3 | none | any | Details for piotr-1.0.2-py3-none-any.whl |
Total release size: 61.2 MB
Release files / piotr-1.0.2.tar.gz
| Download URL | piotr-1.0.2.tar.gz |
|---|---|
| Size | 30.5 MB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
25ebd43f0d2440c73fba19ae4f8f7c9e112ed0ba9987d5c245035ec34f9e9bce
|
|
BLAKE2b-256 checksum How to use checksums |
217912415189ed569f7845ad06e6ba724042324c2bfb2889b01e27b29148370e
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.4.1 importlib_metadata/3.10.1 pkginfo/1.7.0 requests/2.21.0 requests-toolbelt/0.9.1 tqdm/4.61.2 CPython/3.7.3
|
Release files / piotr-1.0.2-py3-none-any.whl
| Download URL | piotr-1.0.2-py3-none-any.whl |
|---|---|
| Size | 30.7 MB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
98e519d07c0cb7206b75a445848790a9fe7d2d5df82d55be02badcd68c3dce4d
|
|
BLAKE2b-256 checksum How to use checksums |
f7ebd93a59e811a2a2969a9158f80fe7e2d59d5e2fbf4eb79846d1995255fe49
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.4.1 importlib_metadata/3.10.1 pkginfo/1.7.0 requests/2.21.0 requests-toolbelt/0.9.1 tqdm/4.61.2 CPython/3.7.3
|
Security for piotr 1.0.2
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.