Kindle Jailbreak Cheat Sheet
Jailbreak
Tutorial Reference: https://kindlemodding.org/
Scripts Archive: https://scriptlets.notmarek.com/
Plugins/Tools Archive: https://www.mobileread.com/forums/showthread.php?t=225030
Tips
Expedite the process of cleaning filler files on macOS
-
Disable Spotlight on the Kindle
sudo mdutil -i off /Volumes/Kindle -
Expedite the cleaning process (should finish around 2 minutes)
rm -rf /Volumes/Kindle/.active_content_sandbox
Otherwise it may take over an hour to delete the recursive folders (around 5000)
Equivalent/Mapping Paths
Folder /mnt/us/ on Kindle (internally) is the same as /Volumes/Kindle/ (externally) on macOS
Package Management
Kindle Package Manager (KPM)
Installation
Included in WinterBreak / SpringBreak
Usage
The locations of kpm binary:
[root@kindle extensions]# find / -name "kpm" 2>/dev/null | grep -v "proc"
/mnt/base-us/kmc/kpm # Only .db file
/mnt/us/kmc/kpm # Only .db file
/var/tmp/chroot/mnt/us/kmc/kpm # Only .db file
/var/tmp/chroot/var/local/kmc/kindlehf/bin/kpm # Executable binary file
/var/tmp/chroot/var/local/kmc/kindlepw2/bin/kpm # Empty on Paperwhhite 5
/var/local/kmc/kindlehf/bin/kpm # Executable binary file
/var/local/kmc/kindlepw2/bin/kpm # Empty on Paperwhhite 5
or type commands in the search bar on Kindle
KindleForge
An AppStore-like GUI tool, but not designed to use alongside with new jailbreak stacks (WinterBreak / SpringBreak)
⚠️ Caution
KindleForge is under maintenance mode. It will need to be re-written using KPM in the backend. If you are using hdnext, an ABI error is expected and I am choosing not to fix it because it isn’t ideal for use alongside KPM/the new jailbreak stack anyway. There’s currently no real ETA.
Reference: https://github.com/KindleTweaks/KindleForge
KOReader
KOReader is a document viewer for E Ink devices. Supported fileformats include EPUB, PDF, DjVu, XPS, CBT, CBZ, FB2, PDB, TXT, HTML, RTF, CHM, DOC, MOBI and ZIP files. It’s available for Kindle, Kobo, PocketBook, Android and desktop Linux.
Installation
kpm install koreader
Usage
Check the reference
Reference: https://koreader.rocks/
SSH
UsbNetLite / UsbNetwork
Q: I wanna use USBNetwork for SSH. How do I get started?
A: You can download it here! https://www.mobileread.com/forums/showthread.php?t=225030
for kindles on firmware 5.16.3 or later please use USBNetlite https://github.com/notmarek/kindle-usbnetlite/releases/tag/1.0.M
To get started with USBNetwork/USBNetlite you can read the guide here: https://wiki.mobileread.com/wiki/USBNetwork
To find more detailed info about USBNetwork/Netlite you can go here (and go down a rabbit hole!) https://www.mobileread.com/forums/showthread.php?t=204942
Installation (of UsbNetLite):
- Download the update.bin file from Released
- Place it into the mrpackages folder on your kindle
- Run
;log mrpifrom the search bar- Profit! You should be able to control usbnetlite from KUAL
Configuration
-
The location of public keys
/mnt/us/usbnetlite/etc/dropbear/authorized_keys -
The location of configs
/mnt/us/usbnetlite/etc/config
Reference: https://www.answeroverflow.com/m/1397616071099289794
KOReader Built-in SSH
Installation (of KOReader)
kpm install koreader
Configuration
Using port 2222 by default
-
The location of public keys
/mnt/us/koreader/settings/SSH/authorized_keys
Terminal Emulator
Kterm
Installation
Download from https://github.com/bfabiszewski/kterm
You should use this package with Unified Applications Launcher (KAUL). First install the launcher then unzip my package to extensions folder. Then start launcher and choose kterm from menu.
scp -r ./kterm root@<KINDLE_IP_ADDRESS>:/mnt/us/extensions/
Usage Example
-
Check Battery Status
echo -n 'Charge: ' ; gasgauge-info -c ; echo -n 'Load: ' ; gasgauge-info -l
Reference: https://www.fabiszewski.net/kindle-terminal/
Disable Ads
Create a shell script file as below, and put it under folder /mnt/us/documents/, and you will be able to run the script by clicking the icon (displayed as a book) in the Kindle library.
#!/bin/sh
# Name: Disable ADs
# Author: Marek
# Icon:
echo "Removing adunits folder"
rm -rf /var/local/adunits
echo "Removing ad assets"
rm -rf /mnt/us/.assets
echo "Updating appreg.db"
sqlite3 /var/local/appreg.db 'update properties set value = "false" where name = "adunit.viewable";'
echo "Rebooting in 5 seconds :)"
sleep 5
reboot;
Reference: https://scriptlets.notmarek.com/
Alpine Linux on Kindle
Troubleshoot
If Chromium fails to launch after a crash, it can due to corrupted SUID permissions on the sandbox binary. The file mode needs to be reset to 4755.
chown root:root /usr/lib/chromium/chrome-sandbox
chmod 4755 /usr/lib/chromium/chrome-sandbox
Reference: https://github.com/schuhumi/alpine_kindle