Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Readers > Kobo Reader > Kobo Developer's Corner

Notices

Reply
 
Thread Tools Search this Thread
Old Yesterday, 07:01 PM   #1
ratiz
Junior Member
ratiz began at the beginning.
 
ratiz's Avatar
 
Posts: 5
Karma: 10
Join Date: Sep 2026
Device: Kobo Clara Colour
Lightbulb A tool to flash eMMC and bypass secure boot on modern Kobos

This post documents my work on the boot process of modern Kobo e-readers based on the MediaTek MT8113 SoC.

I have developed two things that may be useful for anyone experimenting with custom firmware on these devices:
  • A modified version of mtkclient that allows direct reading from and writing to eMMC. This is particularly useful for recovering bricked devices.
  • A patch for Little Kernel (LK) that disables signature verification, making it possible to bypass the secure boot chain and run modified boot images.

The boot chain

The most recent Kobo devices use the MediaTek MT8113 SoC. The boot chain is roughly:

BROM → Little Kernel (LK) → U-Boot → Linux

There may be other components in the chain, such as TEE, but they were not relevant to this work.

U-Boot verifies the hash and signature of the Linux FIT image. Likewise, LK verifies the hash and signature of the U-Boot FIT image. However, BROM checks the integrity of LK but does not verify its signature.

As a result, a modified LK can load a modified U-Boot, which can in turn load a modified Linux image, breaking the chain of trust from LK onward.

Read/write to eMMC

In order to investigate the boot process, a way to recover devices from potential bricks was needed.

MediaTek SoCs can boot in two different modes:
  • The normal boot process
  • Download Agent (DA) mode

DA mode allows uploading a custom payload over USB. The back cover must be opened to access the Download and Reset pads required to enter DA mode. The protective coating covering the pads must also be scraped away.

Follow the instructions in the README of this modified version of mtkclient to enter DA mode and read from or write to the eMMC. The procedure involves shorting Download and briefly shorting Reset while keeping Download shorted, allowing mtkclient to upload its payload over USB.

This modified version of mtkclient adds write support and improves transfer speeds by using eMMC commands CMD18/READ_MULTIPLE_BLOCK and CMD25/WRITE_MULTIPLE_BLOCK. Writing the entire 16 GB User Data Area on the Clara Colour takes around three hours.

For a first test, I recommend starting with the second Boot Area Partition, as it is unused and zero-filled.

Bypass secure boot

Bypassing secure boot requires disabling signature verification in both LK and U-Boot. While the source code for Kobo's vendor versions of U-Boot and Linux is available in the Kobo-Reader repository, the source code for its vendor version of LK is not publicly available.

With the source available, disabling signature verification in U-Boot is straightforward. See how this is done in kos or Quill-OS.

For LK, the binary itself must be patched. After extensive reverse engineering and trial and error, I was able to load a modified LK. This required replacing the hash verified by BROM with the hash corresponding to the modified binary. Once this was achieved, patching the signature verification performed by LK was relatively easy. I wrote a Python script that automates the process by disabling both the integrity and signature checks (although only the latter is needed) and updating the hash verified by BROM. This is also the approach used by kos to bypass secure boot.

Credits
  • enthdegree for showing the way with this project and helping me to get started with the low-level eMMC stuff.

Tools
ratiz is online now   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Kobo Libra 2 (N418) stuck in SDP mode - looking for u-boot.imx / eMMC image nicoden81 Kobo Developer's Corner 2 06-01-2026 12:46 PM
KOA KOA 8th (2016) How to flash the kernel after clearing the EMMC uuer Kindle Developer's Corner 2 05-28-2025 11:19 AM
Kobo Libra Colour is using Secure Boot NiMa Kobo Developer's Corner 15 08-21-2024 07:59 AM
Source code for Secure Boot and Fastboot lockdown features katadelos Kindle Developer's Corner 9 01-18-2022 04:11 AM
Boot/flash Custom recovery ziamrziamr Onyx Boox 0 11-08-2014 04:32 AM


All times are GMT -4. The time now is 08:53 AM.


MobileRead.com is a privately owned, operated and funded community.