[Logo]
  [Search] Search   [Recent Topics] Recent Topics   [Hottest Topics] Hottest Topics   [Members]  Member Listing   [Groups] Back to home page 
Forum rules     [Register] Register / 
[Login] Login 
        Now, by registering on our forum you get a chance to receive giveaway offers, valuable discounts and other great deals! There is no obligation to buy anything - just register and contribute to the forum to take advantage of this great opportunity.
Decrypting firmware  XML
Forum Index » Other
Author Message
alexdupre



Joined: 11/23/2009 11:27:57
Messages: 52
Offline

For the reference, I'm posting instructions about decrypting the jetBook firmware.

1) Decompress the firmware file (unzip it or execute it, depending on the file format). You should now have Data, firmware and reflash_nor directories.
2) All you need is reflash_nor/mtd2, that is a squeezed file system, and firmware/*.bin, that is the encrypted firmware.
3) You also need a linux box, with aespipe and squashfs-tools packages.
4) Unsqueeze the mtd2 fs:

5) You now have the squashfs-root/etc/.passwd file, that is the AES key used to encrypt the firmware
6) Decrypt the firmware:

7) Untar the firmware:

8) Untar the jetBook root filesystem:

9) Now you have in jetbook-rootfs all the software installed in the jetBook
[ICQ]
alexdupre



Joined: 11/23/2009 11:27:57
Messages: 52
Offline

Particularly interesting is the gsl directory, where you can find most of the custom applications. For example, there is gsl/apps/ebook/main.exe that is the main jetBook application, gsl/apps/fbreader/FBReader that is the well-known GPL'ed ebook reader software, gsl/apps/picture/pictureviewer, gsl/apps/settings/settings, etc..

Then, there is gsl/sys/lib/gsl/libgslpdf.so, that contains the FoxIt library for handling PDF files, and lib/libereader_cwapper.so, that should be the library for PDB files.
[ICQ]
adreamer



Joined: 12/23/2009 01:24:39
Messages: 9
Offline

Cool. Is there anyway we can recreate the whole firmware again? Particularly, I'm more interested in adding fonts. I see the fonts are available in "<Rootfs>/usr/X11R6/lib/X11/fonts/misc" directory. I can add it there. But when I decompressed, I got lot of "Cannot mknod" errors

tar: dev/ptyp7: Cannot mknod: Operation not permitted
tar: dev/ipsec: Cannot mknod: Operation not permitted
tar: dev/ptya3: Cannot mknod: Operation not permitted
...

So, I'm not sure whether re-compressing it will create the correct archive. Anyway to solve this?
[Email]
alexdupre



Joined: 11/23/2009 11:27:57
Messages: 52
Offline

You have to be root for mknod. You can recreate the firmware by reverting all the steps.

Just be sure to update jetbook-rootfs/data/.file_count before tarring the rootfs and recalculate the md5 in firmware/md5sum/md5sum before tarring the firmware.

I don't know if it's enough and I've not tested it, but should work. Said so, adding the fonts in such directory could be not enough, depending on what you are trying to reach.
[ICQ]
BlairH



Joined: 01/05/2010 00:32:34
Messages: 15
Offline

Alex, so many thanks for taking the time for your detailed post!!!

Wouldn't it be wonderful if ECTACO provided a SDK for the device so that users could write extensions and patches to solve some problems and add abilities?
[Email]
 
Forum Index » Other
Go to: