Nook Python Host Package
host/nook-py provides the Python host SDK and CLI for Nook.
It exposes:
nook-clinook-gadget
Install
Install from source:
pip install .
Verify:
nook-cli --help
nook-gadget --help
Prerequisite
nook-cli has two runtime paths:
- default server mode: requires a running rooted
nook-server - explicit gadget mode: use
--gadgetto attach to a gadgetized APK inlistenmode
The Python package does not build or launch nook-server automatically. Download the matching nook-server release, then push and start it manually:
adb push .\nook-server /data/local/tmp/nook/nook-server
adb shell "su -c 'chmod 755 /data/local/tmp/nook/nook-server'"
adb shell "su -c '/data/local/tmp/nook/nook-server'"
Common Usage
Server attach:
nook-cli -U com.demo.target -l .\hook.js
Server spawn:
nook-cli -U -f com.demo.target -l .\hook.js
Gadget attach over the gadget listen socket:
nook-cli -U --gadget com.demo.target -l .\hook.js
List processes:
nook-cli ps
List applications:
nook-cli apps
Patch an APK with the gadget:
nook-gadget patchapk --source .\target.apk
nook-cli patchapk .\target.apk
Patch an APK and package a startup script that runs inside the app on launch:
nook-gadget patchapk --source .\target.apk --startup-script .\hook.js
nook-cli patchapk .\target.apk -s .\hook.js
Patch an APK in gadget listen mode and pause app startup until the host attaches:
nook-cli patchapk .\target.apk --on-load wait
Dump in-memory dex artifacts from a running target:
nook-cli dexdump com.demo.target -U
Spawn a target, wait, then scan for dex artifacts:
nook-cli dexdump --spawn com.demo.target -U --deep --sleep 3000
Install a patched APK:
nook-gadget install --apk .\target-nook.apk
Launch the target app:
nook-gadget launch --package com.demo.target --activity .MainActivity --stop-first --clear-logcat --wait 3
Notes
- Rooted Android device required
- Current primary target is
arm64-v8a --strict-zygote-controlremains experimentalnook-gadget patchapkandnook-cli patchapkcurrently expect a full Nook repo checkout because they reuse repo build/signing helpers--gadgetis explicit by design; without it,nook-cli -U ...still targetsnook-server- gadget packaged startup-script mode and host-attached
listenmode are both supported - See
docs/nook-gadget-usage.mdfor the practical gadget workflow - See
docs/nook-dexdump-usage.mdfor the practical dexdump workflow
Metadata
Release files for nook-cli 0.1.3
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 |
|---|---|---|---|---|
| nook_cli-0.1.3.tar.gz | 99.1 kB | Without provenance | Details for nook_cli-0.1.3.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| nook_cli-0.1.3-py3-none-any.whl | Python 3 | none | any | Details for nook_cli-0.1.3-py3-none-any.whl |
Total release size: 165.1 kB
Release files / nook_cli-0.1.3.tar.gz
| Download URL | nook_cli-0.1.3.tar.gz |
|---|---|
| Size | 99.1 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
eeb8d25bb924ede64f13a6b748e1d492caafcb5602054be28b852b03510e4b73
|
|
BLAKE2b-256 checksum How to use checksums |
2cb90da7f3c93c33433d6fb55819d03791d14a7747479caff4373360fd599b32
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.8.5
|
Release files / nook_cli-0.1.3-py3-none-any.whl
| Download URL | nook_cli-0.1.3-py3-none-any.whl |
|---|---|
| Size | 66.0 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
ed11c6722eb3106bc493558ba4ec436fc2f29c4459f9c247f26fc9c3ecc10881
|
|
BLAKE2b-256 checksum How to use checksums |
6ad4bb285ef0edfb4aee3895c0cf1a5cb1826b33ab3461aae58a1a836da570ec
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.8.5
|
Security for nook-cli 0.1.3
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.