This tool was especially made for the new SIN v3 format used in Xperia Z3+/Z4 and Xperia Z4 Tablet (and more recent Xperia devices as well), as well as SIN v4 format introduced with Xperia XZ Premium and SIN v5 format introduced with Xperia XZ2 and Xperia XZ2 Compact.
This tool can unpack every SIN v3/v4/v5 file to its contained binary or EXT4 image file, the later can then be extracted with 7zip to its inner files.
Special credits to @Androxyde (of Flashtool) for original Java SIN code, @tal.aloni for Sparse decompression method and Dino Chiesa for TAR extraction method.
SUPPORTED SIN FORMATS:
SIN v3 = Custom format (utilizing LZ4 compression)
SIN v4 = gzip + tar + Android sparse format
SIN v5 = tar + Custom sparse format (utilizing LZ4 compression)
REQUIREMENTS:
Windows: 64-bit support only. No other requirements.
Linux: 64-bit support only. No other requirements
USAGE:
Just drag and drop a SIN file onto this EXE file, or write in Command Prompt "unsin system.sin" (or any other SIN image).
Make sure you have at least 6GB of free space on your hard drive, as the output EXT4 images are huge.
Note: super_*.img (extracted from super_*.sin) has to be further unpacked into individual partition images:
* Windows: Using 7zip, right-click the super_*.img, then use "Open Inside #" see all of the contained partitions (they will be labeled with the *.ext extension).
* Linux: Using "lpunpack super_*.img" (Google for a pre-compiled lpunpack binary)
COMMAND-LINE OPTIONS:
unsin --- Intro, version and usage instructions.
unsin <file path 1> [<file path 2> ... <file path n>] --- Unpack specified *.sin file(s)
unsin -d --- Unpack all *.sin files in the current directory (non-recursive)
unsin -d <dir path 1> [<dir path 2> ... <dir path n>] --- Unpack all *.sin files in the specified directories (non-recursive)
unsin -dr --- Unpack all *.sin files in the current directory (recursive)
unsin -dr <dir path 1> [<dir path 2> ... <dir path n>] --- Unpack all *.sin files in the specified directories (recursive)
NOTES:
* The order of the options has no significance. (i.e. -dr is the same as -rd)
* The options are case-insensitive. (i.e. -d is the same as -D)
CHANGELOG:
v1.13 [May 20, 2020]:
- Added support for super.sin images. (Note: those have to be further unpacked using lpunpack into individual partition images)
- Added exit status on success (code 0) and failure (code 1) for usage with automation scripts.
- Built using the latest .NET Core SDK 3.1.300.
v1.12 [October 1, 2019]:
- Added intro, version and usage instructions to binary (when executing without any arguments)
- .NET Core Windows x64 binary rebuilt with .NET Core 3.0 and file size reduced to ~1.8MB.
- .NET Core Linux x64 binary rebuilt with .NET Core 3.0 and file size reduced to ~2.1MB.
- The .NET Framework variant is discontinued, final version is v1.11.
v1.11 [August 12, 2019]:
- Added .NET Core native self-contained binaries: UnSIN 1.11 (Win x64).zip and UnSIN 1.11 (Linux x64).zip
v1.11 [May 31, 2019]:
- Fixed unsparsing of SINs containing non-EXT4 images that were split into multiple sparse parts. (mainly affecting recent modem.sin images)
v1.10 [June 12, 2018]:
- Fixed wrong implementation of FILL sparse chunk type that resulted in corrupted images in rare occasions.
v1.9 [April 9, 2018]:
- Workaround for certain SIN files that contain 2 unexpected 0x00 bytes, specifically on F5121 Oreo firmware's oem.sin files. Purpose of these bytes is unknown, probably reserved for future use, but can be safely skipped.
- Added command-line options by a user's request.
v1.8 [March 23, 2018]:
- Fixed a silly mistake that resulted in corrupted EXT4 images.
- Significantly optimized memory usage.
v1.7 [March 23, 2018]:
- Added support for SIN v5 (tar + Custom sparse format) files that were introduced in Xperia XZ2 and Xperia XZ2 Compact firmware.
v1.6 [June 29, 2017]:
- Removed some unnecessary stages, making the extraction a lot faster.
- Improved checking of available disk space, to accommodate for the removal of pre-assigned container file.
v1.5 [June 10, 2017]:
- Fixed extraction for SIN v4. Images can now be mounted properly.
v1.4 [June 6, 2017]:
- The extracted images are now identical to those extracted by Flashtool, and can be mounted properly.
- Fixed support for old SIN v3 formats that used a different partition information (i.e. Xperia C).
v1.3 [May 11, 2017]:
- Fixed SIN v4 support for non-sparse binaries.
v1.2 [May 10, 2017]:
- Added support for SIN v4 (gzip + tar + Android sparse format) files that were introduced in Xperia XZ Premium firmware. (NOTE: At least .NET Framework 4.0 is now required!)
v1.1 [December 1, 2016]:
- Algorithms were fixed to support large Nougat-based SIN files.
v1.0 [June 5, 2015]:
- Initial release.
Its very good
Thanks
Thanks Bro. great idea and amazing job
Sent from my Sony Xperia Z3 ™ Single D6643 - Sen liked my work or my help click thanks!
Toni Junior
Awesome work mate
Cool ??
Sent from my D5833 using XDA Free mobile app
Thanks Bro. great idea and amazing job
Great Job
Good work!
Also it unpacks old .sin files without problems
Rootk1t said:
Good work!
Also it unpacks old .sin files without problems
Click to expand...
Click to collapse
Yep, as long as they are v3.
IaguCool said:
Yep, as long as they are v3.
Click to expand...
Click to collapse
How can i determine version of .sin?
Rootk1t said:
How can i determine version of .sin?
Click to expand...
Click to collapse
Open the SIN file with a Hex Editor. The first byte should be 0x03. The next 3 bytes say "SIN" in ASCII.
Thank you @IaguCool and @Androxyde. You guys are indispensable.
najoor said:
Thank you @IaguCool and @Androxyde. You guys are indispensable.
Click to expand...
Click to collapse
Kind words, thank you.
Please can someone explain me how i can extract the media files from the xperia tablet z4 firmeware within the memorystick_red.sin file? i´ve tried several things, got an ext4 file but all tools get an error message or told me the file is not valid...
Thank you!
Fixed for Nougat.
It should also work much smoother and use far far less RAM and CPU while it's working.
Take note: it takes time, just be patient, and use it on an SSD if you have one to speed things up.
v1.2 [May 10, 2017]:
- Added support for SIN v4 (gzip+tar+Android sparse format) files that were introduced in Xperia XZ Premium firmware. (NOTE: At least .NET Framework 4.0 is now required!)
Great work. Extracting the system image now works.
Digging in modem files to see CA combinations supported...
IgorEisberg said:
v1.2 [May 10, 2017]:
- Added support for SIN v4 (gzip+tar+Android sparse format) files that were introduced in Xperia XZ Premium firmware. (NOTE: At least .NET Framework 4.0 is now required!)
Click to expand...
Click to collapse
Thank you for quick update!
v1.2 is working great for system.sin, but it fails to decompress image chunks if I try to unpack elabel or kernel.
It says other process is using 'LTALabel.000' and the process can't access.
AndroPlus said:
Thank you for quick update!
v1.2 is working great for system.sin, but it fails to decompress image chunks if I try to unpack elabel or kernel.
It says other process is using 'LTALabel.000' and the process can't access.
Click to expand...
Click to collapse
Hmm interesting, I'll see what I can do.
AndroPlus said:
Thank you for quick update!
v1.2 is working great for system.sin, but it fails to decompress image chunks if I try to unpack elabel or kernel.
It says other process is using 'LTALabel.000' and the process can't access.
Click to expand...
Click to collapse
v1.3 [May 11, 2017]:
- Fixed SIN v4 support for non-sparse binaries.
Note that the kernel and fotakernel have a new format. (the signature is ANDROID rather than ELF).
.
Related
Disclaimer:
Our tool was made for testing and educational purposes, ME is not responsible for what you have doing using our tool, you must agree that you using our tool on your own risk, I am not responsible for anything or anything else you doing/do with using our tool!
Hello! I have made universal tool which is able to extract any format of the Sony image. Also tool is able to dump and extract directly from block device. After 20.Jan.2017 we are able now to convert sin file on the fly and flash it directly to block device. Supported formats which tool is able to deal with:
1. sin v1
2. sin v2
3. sin v3
4. sin v4
5. sin v5
6. img
7. elf
How to use:
since this is a command line tool, you must run it trought an batch file or trought your command line, e.g:
sony_dump DESTINATIONFOLDER PATHTOTHEFILE
sony_dump out kernel.elf
sony_dump out boot.img
sony_dump out kernel.sin
sony_dump out /dev/block/platform/msm_sdcc.1/by-name/boot (android version only)
sony_dump out /dev/block/platform/msm_sdcc.1/by-name/FOTAKernel (android version only)
sony_dump out anysinfile.sin
for flashing sin file to block device e.g: sony_dump /dev/block/platform/msm_sdcc.1/by-name/system system.sin
Enjoy!
Changelog:
- 01.Jan.2017 -> implemented sin to elf converter, now kernel.sin can be extracted
- 01.Jan.2017 -> now any sin file can be converted to converted.file
- 02.Jan.2017 -> now sin version 3 with lz4 compressed data is supported
- 02.Jan.2017 -> improved non compresed sin files extraction
- 02.Jan.2017 -> some cleanups ; now arm version, arm version with pie and linux version
- 04.Jan.2017 -> fix large sin files extraction, curently I have removed arm and windows version of the program since I have no idea how to get LFS working on non 64bit platform, so last one is for Linux 64-bit platform only until I find a way to write files bigger than 2gb If you have working example tell me please!
- 05.Jan.2017 -> LFS fixed, now tool generates valid system.ext4 from uncompressed sin, suuport again for linux, for arm, for windows, tested only on linux and windows by now, tool support by now large files (LFS) and propertly generates output. If you find bugs please report. Tommorow hope fix for compressed big sin files
- 07.Jan.2017 -> finished. Now all types of the sin files can be extracted. Sin files decompression fail on 32 bit machines/devices if output file reach 0xffffffff bytes so everything after output of the 0xffffffff bytes is not a valid, I have no idea which toolchain have full 64 bit support on 32 bit platform so I am unable to make LFS (large files support) on 32 bit platfom. File output which is smaller than 0xffffffff bytes is valid on 32 bit platform. But on any 64 bit platform tool working flawless and you can extract any sin file so no problem with LFS and etc! I have tested on win10 64 bit and ubuntu 64 bit and can confirm that any sin files is extracted correctly. Tried on android 32 bit but file output which is smaller than 0xffffffff bytes is a valid but till after file reach size of the 0xffffffff bytes is no more valid! Have no idea why. Not tried on 64 bit android but I am pretty sure it will work the same like on 64 bit windows and 64 bit linux.
- 07.Jan.2017 -> while compared extracted sin with one of the flashtool I have noticed one or two blocks missing in my output file , it was since whileloop was wrong in one case, done some right small changes and now all case is ok, file is identic to one from flashtool
- 08.Jan.2017 -> Finally tool is abble to work on booth 32 bit and 64 bit linux, android and windows machine by fully supporting LFS
- 12.Jan.2017 -> sony_dump, detect file extensions in sin
- 12.Jan.2017 -> small tool for convert file_contexts.bin (binary) to file_contexts (textual)
- 15.Jan.2017 -> removed part of the old mechanism related to sin version and file size detection, in some case cache.sin was failed to extract since file size calculation was wrong, now definitelly any sin file can be extracted
- 20.Jan.2017 -> redesigned a way for extracting boot.sin files, now it extract elf instead of unpacking it fully, so if you need to unpack fully just rerun tool with elf file. Also now we can convert on the fly and flash any sin file directly to block device
- 01.May.2017 -> support for sin version 1 & 2, some improvements for ver 3
- 18.May.2017 -> compiled for mipsel 32bit & 64bit (litle endian), mips 32bit and mips 64bit (big endian), linux 32bit & 64bit, arm 32bit and arm 64bit, windows, all is static without dependencies
- 07.Jun.2017 -> support for sin version 4
- 24.12.2017 -> apple x86 and apple i386 support
- 12.06.2018 -> sin version 5 support
- 13.06.2018 -> self implemented custom sparse format (no more need libsparse) because had problem with out of memory extracting large sin files
- 17.06.2018 -> fully implemented sin v5, removed mips and mips64 big endian builds (because my tool not support that)
- 17.10.2019 -> some sin files produce wrong ext4 file, fixed now. Removed osx support right now, if you need it download source code from git and compile by self, I have no free time to mess with it
- 18.10.2019 -> another bug discovered, ext4 padding on some sin files was missing, fixed now
- 20.10.2019 -> some updates, osx binaries now included
- 03.11.2019 -> propertly unpack ext4 images, this include extra bytes at the end of ext4, it is realy need if you going to fully emulate sony gpt disk inside virtual machine ; inflate progress bar
Small tool for converting binary->plaintext plaintext->binary file_contexts:
- https://forum.xda-developers.com/showpost.php?p=70881172&postcount=1985
Credits:
- I must give credit to @Androxyde since I have looked into his java source code for understanding lz4a commpresed sin's, thanks for open source, I realy appreciate your hard work on flashtool!
Source code:
- https://github.com/munjeni/anyxperia_dumper
I don't have a Sony smartphone and probably won't use your tool but really thank you for that tool ?
Sent from my Redmi Note 3 using Tapatalk
Update: Now sin can be extracted!
Ahmad Tawfik said:
I don't have a Sony smartphone and probably won't use your tool but really thank you for that tool ?
Sent from my Redmi Note 3 using Tapatalk
Click to expand...
Click to collapse
You can extract boot.img with it!
munjeni said:
You can extract boot.img with it!
Click to expand...
Click to collapse
bro first thanks for your great tool.
you mean with this tool we can unpack kernel yes? ( with those command )
then how can repack it ( after do our change ) ?
sorry if this question is nooby
This is for unpacking only. You can read xda contain ton of tutorials related to how to pack boot image, just search please
Update:
now tool is able to extract any sin file and output it to converted.file
Sorry sin version 3 is not supported, I am working on it, only sin version 1 & 2 by now!
Now sin version 3 with lz4 compressed data is supported! Report bugs please if you get!
New version, improved non compressed sin files extraction, now for example 1.5 gb system.sin files can be extracted in just some secconds, amazing
Now versions for:
- Linux
- arm
- arm with pie
- Windows
. .
@munjeni thanks for this tool, great work. but
i'm trying your linux version and this tool not extract pagesize info and made broken boot.img, ie if i'm try extract kernel.sin your tool create boot.img (but it's a same sin file) and if i'm try extract .elf, tool create boot.img (but same elf)
You can't use folder out and boot.img from the same directory! Boot.img from ouy directory is nothing than temp file. In next version all temp files will ne deleted on app finish to prevent mess. Also next version will be working one for sin files, cutently I forgot to include spare data generation which cause non valid extracted big sin files e.g. system.sin, problem also is my compiler and can't fwrite bigger files that 2gb, tommorow I think I will finish all and finaly produce a valid tool.
munjeni said:
This is for unpacking only. You can read xda contain ton of tutorials related to how to pack boot image, just search please
Click to expand...
Click to collapse
To be fair many of them don't work, I've even installed Linux on an old laptop to try and learn how to repack but always get stuck with "android boot magic not found" and googling hasn't helped at all. An updated guide really wouldn't go a miss.
Sin of big size - extraction is now working under linux 64-bit, need some small changes to do to get it working correctly! I am sorry I have removed 32-bit version since I have no idea how to make LFS working under 32-bit platform but have tried almost everything, no way. Please let me know if you have a tested and working example of the LFS for 32-bit windows! And tell me please which compiler you used!
Finaly fixed everything, now tool generates valid system.ext4, suport again for linux, for arm, for windows, tested only on linux and windows by now, tool support by now large files (LFS) and propertly generates output. If you find bugs please report. Please try on android since I have not tested. :good:
Edit:
Uh, downloaded z5 premium rom, extracted system.sin and tool failed on v3 sin, seems I forgot something in curently huge source code, will check tommorow sorry On z1 uncompressed images working flawles, since I have now z5 rom on my disk I will fix bug sorry
Newer sin e.g. system.sin contains mixed data, compresed and uncompresed, holy s I must rewrite half of the my code to get thing propertly parsed... Damn
Does android support off64_t on 32 bit toolchain anybody know?
finished. Now all types of the sin files can be extracted. Sin files decompression fail on 32 bit machines/devices if output file reach 0xffffffff bytes (4 gb) so everything after output of the 0xffffffff bytes (4 gb) is not a valid, I have no idea which toolchain have full 64 bit support on 32 bit platform so I am unable to make LFS (large files support) on 32 bit platfom. File output which is smaller than 0xffffffff bytes (4 gb) is valid on 32 bit platform. But on any 64 bit platform tool working flawless and you can extract any sin file so no problem with LFS and etc! I have tested on win10 64 bit and ubuntu 64 bit and can confirm that any sin files is extracted correctly. Tried on android 32 bit but file output which is smaller than 0xffffffff bytes (4gb) is a valid but till after file reach size of the 0xffffffff bytes (4gb) is no more valid. 32 bit platform is limited and we can do nothing on that. Not tried on 64 bit android but I am pretty sure it will work ok the same like on 64 bit windows and 64 bit linux.
This tool is primary designed for extracting any sony boot image format from, you can extract any boot image using this tool on 32 bit platform or on 64 bit platform without any problem, without cares to LFS! But for seccondary thing you can use to extract any sin file, on 64 bit platform it will success for sure but on 32 bit platform it is limited because LFS in my case is not working corectly on 32 bit platform if output of the file is bigger than 4 GB
What's ziplign ?
Read,Android Developers site.https://developer.android.com/studio/command-line/zipalign
zipalign is an archive alignment tool that provides important optimization to Android application (APK) files. The purpose is to ensure that all uncompressed data starts with a particular alignment relative to the start of the file. Specifically, it causes all uncompressed data within the APK, such as images or raw files, to be aligned on 4-byte boundaries. This allows all portions to be accessed directly with mmap() even if they contain binary data with alignment restrictions. The benefit is a reduction in the amount of RAM consumed when running the application.
This tool should always be used to align your APK file before distributing it to end-users. The Android build tools can handle this for you. Android Studio automatically aligns your APK.
Click to expand...
Click to collapse
Why this tool is needed ?
There are a lot of APK modifications on XDA, most of which are done through APKTOOL (Thanks @iBotPeaches for this great tool)
But after apktool compilation, apks needs to be zipalign manually -> which is missing from some these Modded/Distributed Apks found in the forum.
So, I decided to go ahead and make simple tool for this task.
This tool will help end-users/devs in such cases.
How to Use ?
It's One-Click tool, As simple as it gets !
Download & Extract Zip file from attachment.
Put All apks in "Input" folder
Do not leave "SPACES" in file name of APKs For example, Use "AppName_v1.apk" instead of "AppName v171.apk"
Double Click the Batch file (.bat)
You can find zipaliged APKs in "Output" folder after it's done.
That's It !!
PS : (Devs only) Use this tool **AFTER** signing APKs
Users don't need to worry about this because APKs you have/download are already signed.
FAQs
# How to know whether APKs are zipaligned or not after using this tool ?
Check file size of APK Before & After (In Input & Output folders). You will see the differnce in file size on bytes level So, you need to open full property of file via right click.
If file size if exactly the same, means APK was already zipaligned
# How to know whether APKs i have are already zipaligned or not ?
As of now there's no method to my knowledge. So, you need to go through above process.
In general, APKs directly from PlayStore (you backup/apkmirror) are zipaligned so you don't need to zipalign them unless there's some modifications performed on it.
Change log
v1.0 Release 2017
Initial Release
Latest available zipalign binary
v2.0 Release 2022
Based on Android SDK Build-Tools 30.1.0 and should be compatible with latest Android versions (A9-A12+)
Tried this. Nothing in the output folder
Serpentinefire76 said:
Tried this. Nothing in the output folder
Click to expand...
Click to collapse
I'm not actively maintaining this tool due to personal commitments. Theoretically it should still work even with older binaries but if you are looking for specific support I suggest search for other/newer threads.
jineshpatel30 said:
I'm not actively maintaining this tool due to personal commitments. Theoretically it should still work even with older binaries but if you are looking for specific support I suggest search for other/newer threads.
Click to expand...
Click to collapse
I tried it again. It works like a charm. Awesome. Thank you!
Update after a long time.
v2 is based on Android SDK Build-Tools 30.1.0 and should be compatible with latest Android versions (A9-A12+)
Happy Modding!
i get this error a mod apk
Code:
Failure [INSTALL_PARSE_FAILED_NO_CERTIFICATES: Failed collecting certificates for /data/app/vmdl262490375.tmp/base.apk: Failed to collect certificates from /data/app/vmdl262490375.tmp/base.apk: META-INF/APKEASYT.SF indicates /data/app/vmdl262490375.tmp/base.apk is signed using APK Signature Scheme v2, but no such signature was found. Signature stripped?]
Command file current zipalign.bat:
for %%X in (.\Input\*.apk) do (
echo Zipaligning - %%~nX.apk
.\Tools\zipalign -cv 4 %%X
.\Tools\zipalign -fv 4 %%X .\Output\%%~nX.apk
)
Maybe it should be reversed like this:
for %%X in (.\Input\*.apk) do (
echo Zipaligning - %%~nX.apk
rem To align infile.apk and save it as outfile.apk
.\Tools\zipalign -fv 4 %%X .\Output\%%~nX.apk
rem check alignment outfile.apk only after having zipalign (does not modify file)
.\Tools\zipalign -cv 4 %%X
)
Disclaimer:
Our tool was made for testing and educational purposes, ME is not responsible for what you do on/with your device using our tool, you must agree that you using our tool on your own risk, I am not responsible if you brick your device or anything else!
What is this for:
This tool converts xperia sin file and directly create flashable.zip for use to flash your android device with recovery.
Changelog:
- version 1. (missing selinux label generator)
- version 2. (implemented selinux label generator tool. Missing static busybox)
- version 3.
- version 4. some small corections, added missing update-binary
- version 5. some improvements, new sin unpack tool
How to use:
Extract sin2zip.rar archive & simple run CONVERT.bat & chose system.sin image , tool will produce flashable.zip
What you need to check or probably modify in generated flashable.zip:
1. busybox I have used is 32bit, it will work on 64bit too (not busybox.exe !!), I not recommend to change busybox, but before you go for busybox replace make sure it is STATIC busybox and have working (chcon and chown) with -h parameter!
2. check updater-script e.g. first 3 lines and last 2 lines!
3. this -> https://forum.xda-developers.com/showpost.php?p=80593639&postcount=7
Source code:
modified ext4_read tool is in attachment. Original ext4_read is here, many thanks to author! I have notified Igor, hope we see selabels listing integration in 7z without need for hackish ext4_read
sony dump tool -> https://github.com/munjeni/anyxperia_dumper
munjeni said:
This tool converts xperia sin file and directly create flashable.zip for using with recovery. 75 percent is done. 25 percent of the things is missing, selinux related things. I need help for implement selinux to the 7z to list selinux labels from ext4! Here is work in proogress
Click to expand...
Click to collapse
Maybe @SuperR. of SuperR's Kitchen fame HERE could give you some pointers on this. :fingers-crossed:
Maybe you could work together to integrate some of your great Sony specific tools into the Kitchen
That kitchen do not have anything related to our tool. I have done some progress in extracting selabels from ext4 by searcing with inode number \0/
Right now tool is able to extract selabels by inode number pointing
So you are on the drawing board again! Cool... :highfive:
About what you wrote in the j4nn's thread (1. to make fota unpack tool), count on me if you need help, ok!
If I'm not mistaken, I sent you a ota update_package file from my x performance some time ago, but if I am, here it goes again.
Cheers.
serajr said:
So you are on the drawing board again! Cool... :highfive:
About what you wrote in the j4nn's thread (1. to make fota unpack tool), count on me if you need help, ok!
If I'm not mistaken, I sent you a ota update_package file from my x performance some time ago, but if I am, here it goes again.
Cheers.
Click to expand...
Click to collapse
Thanks! I will look into ota package till after I finish our tool
Almost done! New version v2 is out! Made small tool to read ext4 image and print selabels to updater-script, it look like this:
if regular file or folder:
Code:
run_program("/tmp/busybox", "chcon", "u:object_r:location_exec:s0", "/system/bin/xtwifi-inet-agent");
if symlink:
Code:
run_program("/tmp/busybox", "chcon", "-h", "u:object_r:vendor_file:s0", "/system/bin/xxd");
Tool is curently 95 percent done, not realy ready for flashig produced flashable.zip , need to implement 5 percent of the things. You can try but plese do not try to flash with recovery it will not work corectly!
Version 3 done! Before you flash flashable.zip please check updater-script first 3 lines and last 2 lines! Do in mind our tool didn't include the rest of firmware like kernel, vendor...etc, tool only convert one sin file to flashable.zip, if you need the rest of firmware run CONVERT.bat and chose another sin file, do merges in zip by hand and do merges-modification in updater-script by hand too. Not recommended for newbies! I can't tell you if produced flashable.zip is working I'm not tried to flash flashable.zip, but I think it going work. Important thing is initial tool is done and somebody need to test. Let me know Enjoy!
Version 4 done. Enjoy!
@serajr here is some info https://forum.xda-developers.com/showpost.php?p=80599561&postcount=1330 , your file is the same format as j4nn
Version 5 done.
Henry's unpacker - Unpack raw/sparse android image and repack them into a TWRP flashable rom
Instructions to using the tool:
1. Download and unzip
2. Place boot/system/vendor images to the directory where you extracted
3. Open a terminal and type in ./henry
4. Press 1 and press Enter. Make wanted changes inside system/vendor folders.
5. Type in terminal ./henry and press 2 and press enter.
6. You should have a rom.zip in the same directory which you can flash in TWRP.
If something goes wrong while unpacking make sure you have Python 3.6
Downloads:
V1.8 (beta): Click here (google drive)
V1.7 (beta): Click here (google drive)
V1.6 (beta): Click here (google drive)
V1.5 (beta): Click here (google drive)
V1.4 (beta): Click here (google drive)
V1.3 (beta): Click here (google drive)
V1.2 (beta): Click here (google drive)
V1.1 (beta): Click here (google drive)
V1 (beta): Click here (google drive)
This tool works on Linux or WSL2 (Windows 10 build 2004 and up)
Changelogs:
V1.8: Maybe fix some issues??
V1.7: update script
V1.6: V1.5 but better
V1.5: Bugfixes
V1.4: Android 11 support & a lot smaller code
V1.3: Fix a bug i accidentally added in V1.2
V1.2: Fix simg2img not working sometime
V1.1: Fix a rare bug with symlinks.
V1: Initial release
Report any issues in the comments and I'll try to help:good:
Enjoy!
XDA:DevDB Information
Henry's unpacker, Tool/Utility for all devices (see above for details)
Contributors
ORIGINALNAME123
Version Information
Status: Beta
Current Beta Version: V1.5
Beta Release Date: 2020-08-09
Created 2020-07-27
Last Updated 2020-10-10
Nice work mate
ORIGINALNAME123 said:
Henry's unpacker - Unpack raw/sparse android image and repack them into a rom
Instructions to using the tool:
1. Download and unzip
2. Place boot/system/vendor images to the directory where you extracted
3. Open a terminal and type in ./henry
4. Press 1 and press Enter. Make wanted changes inside system/vendor folders.
5. Type in terminal ./henry and press 2 and press enter.
6. You should have a rom.zip in the same directory which you can flash in TWRP.
Downloads:
V1 (beta): Click here
Report any issues in the comments and I'll try to help:good:
Enjoy!
Big thanks to https://github.com/cubinator (cubi) for creating https://github.com/cubinator/ext4 without it it wouldn't be possible
XDA:DevDB Information
Henry's unpacker, Tool/Utility for all devices (see above for details)
Contributors
ORIGINALNAME123, https://github.com/cubinator
Version Information
Status: Beta
Current Beta Version: V1
Beta Release Date: 2020-07-27
Created 2020-07-27
Last Updated 2020-07-27
Click to expand...
Click to collapse
xD
ORIGINALNAME123 said:
Henry's unpacker - Unpack raw/sparse android image and repack them into a rom
Instructions to using the tool:
1. Download and unzip
2. Place boot/system/vendor images to the directory where you extracted
3. Open a terminal and type in ./henry
4. Press 1 and press Enter. Make wanted changes inside system/vendor folders.
5. Type in terminal ./henry and press 2 and press enter.
6. You should have a rom.zip in the same directory which you can flash in TWRP.
If something goes wrong make sure you have Python 3.6
Downloads:
V1 (beta): Click here (google drive) or here (Mega)
Report any issues in the comments and I'll try to help:good:
Enjoy!
Big thanks to https://github.com/cubinator (cubi) for creating https://github.com/cubinator/ext4 without it it wouldn't be possible
XDA:DevDB Information
Henry's unpacker, Tool/Utility for all devices (see above for details)
Contributors
ORIGINALNAME123, https://github.com/cubinator
Version Information
Status: Beta
Current Beta Version: V1
Beta Release Date: 2020-07-27
Created 2020-07-27
Last Updated 2020-07-27
Click to expand...
Click to collapse
u chod
Nice
Nice Work
gg!
Oh nice
Traceback (most recent call last):
File "tools/henry", line 79, in <module>
os.system("sudo chown -R " f"{os.getlogin()}" ":" f"{os.getlogin()}" " " f"{name}")
FileNotFoundError: [Errno 2] No such file or directory
Thanks for the tools,but I am getting.this error when I unpack vendor,How do I resolve it?Thanks @ORIGINALNAME123
BTW,is that any chance I Can.repack it as img file,cosz I can't flash rom.zip.
almightysiman said:
Traceback (most recent call last):
File "tools/henry", line 79, in <module>
os.system("sudo chown -R " f"{os.getlogin()}" ":" f"{os.getlogin()}" " " f"{name}")
FileNotFoundError: [Errno 2] No such file or directory
Thanks for the tools,but I am getting.this error when I unpack vendor,How do I resolve it?Thanks @ORIGINALNAME123
Click to expand...
Click to collapse
I'm getting this too.how did you fix it?
Sent from my motorola one power using Tapatalk
ORIGINALNAME123 said:
Henry's unpacker - Unpack raw/sparse android image and repack them into a TWRP flashable rom
Instructions to using the tool:
1. Download and unzip
2. Place boot/system/vendor images to the directory where you extracted
3. Open a terminal and type in ./henry
4. Press 1 and press Enter. Make wanted changes inside system/vendor folders.
5. Type in terminal ./henry and press 2 and press enter.
6. You should have a rom.zip in the same directory which you can flash in TWRP.
If something goes wrong while unpacking make sure you have Python 3.6
Downloads:
V1.7 (beta): Click here (google drive)
V1.6 (beta): Click here (google drive)
V1.5 (beta): Click here (google drive)
V1.4 (beta): Click here (google drive)
V1.3 (beta): Click here (google drive)
V1.2 (beta): Click here (google drive)
V1.1 (beta): Click here (google drive)
V1 (beta): Click here (google drive)
This tool works on Linux or WSL2 (Windows 10 build 2004 and up)
Changelogs:
V1.7: update script
V1.6: V1.5 but better
V1.5: Bugfixes
V1.4: Android 11 support & a lot smaller code
V1.3: Fix a bug i accidentally added in V1.2
V1.2: Fix simg2img not working sometime
V1.1: Fix a rare bug with symlinks.
V1: Initial release
Report any issues in the comments and I'll try to help:good:
Enjoy!
XDA:DevDB Information
Henry's unpacker, Tool/Utility for all devices (see above for details)
Contributors
ORIGINALNAME123
Version Information
Status: Beta
Current Beta Version: V1.5
Beta Release Date: 2020-08-09
Created 2020-07-27
Last Updated 2020-08-10
Click to expand...
Click to collapse
Mounting raw vendor.img
mount: /home/ubuntubro/2 kitchenV1.7/kitchen-master/vendor: wrong fs type, bad option, bad superblock on /dev/loop8, missing codepage or helper program, or other error.
so this the exaact error i am getting.. can you please at least tell me what is the problem??? and how to fix this issue???
Sent from my motorola one power using Tapatalk
samrattt said:
I'm getting this too.how did you fix it?
Sent from my motorola one power using Tapatalk
Click to expand...
Click to collapse
try 1.8 now updated.
ORIGINALNAME123 said:
try 1.8 now updated.
Click to expand...
Click to collapse
Thank you so much..but can you please add option to repack it as img? repacking it to img is what most people needed..or can you suggest me how to do that?thanks for the awesome tool again.. really appreciate your hard work..
Not working in windows 10
I am unable to access the kitchen using ./henry command. This is the error that i keep running into:
Traceback (most recent call last):
File "D:\Cygwin\home\T\kitchen\tools\henry", line 5, in <module>
import os, pwd, grp
ModuleNotFoundError: No module named 'pwd'
Info: Process exited with code 1
Any solution? @ORIGINALNAME123
Good work! xD
Thanks!
Good stuff. Complements my self promotion quite nicely.
Jokes aside this is VERY useful for nerds like me who want to poke around the Android ROMs. Thanks!
just wondering if anyone had any luck in unpacking android 11 product.new.dat.br/system.new.dat.br images?
Hello sir and friends,
Thank you for your great works.
I am looking for a tool to unpack boot.img from GSI ROMs. Can this tool help doing this?
And I am using Windows 7 x64. Can this tool work on my PC?
If possible please make it like CRB Tool, this way it seems difficult
Multi Image Kitchen - Repack Android partitions from Windows
Possibilities:
Unpacking and packing partitions: System, Vendor, Product, ODM, SOCKO, ELABLE (RAW, SPARSE)
Unpacking and packing partitions with extension: * .img; * .fex; * .Partition; * .new.dat; * .new.dat.br; * .lz4; * .exT4; * .tar; * .md5
Unpacking and packaging logo partition: logo.img, logo.partition
Unpacking and Packaging: _aml_dtb.partition (Single, Multi, Multi / Gzipped)
Extract from the PAYLOAD.BIN file sections file
Removing from the Super.img file partitions
Unpacking and packaging of resource partition: resource.img
Unpacking and packaging SOC Amlogic firmware, Rockchip and Allwinner
Unpacking and assembling Service Package: * .zip (Update.zip)
Decompiling and compile applications (* .apk)
Github: https://github.com/CryptoNickSoft/MIK
Reserved
Reserved 2
Download link not working for me
Scramble said:
Download link not working for me
Click to expand...
Click to collapse
Update
Mine's in Russian
Edit: Nevermind, I've managed to change the language
RichardHer said:
Mine's in Russian
Edit: Nevermind, I've managed to change the language
Click to expand...
Click to collapse
So do something wrong.
omg, thanks you,this tool is useful!
@CryptoNick
Amazing, I was finally able to extract the system.fex. Originally I have a super.fex, which contained 3 other files: product.fex, system.fex and vendor.fex
Out of the 3 fex-files only 2 were automatically extracted after the initial split: system.fex and vendor.fex. The 3rd file product.fex could be manually extracted with your tool.
System.fex etc. can be created after modification, but how do I re-pack the 3 sub-files into the single super.fex again?
Packaging in super.fex has not yet been implemented. If there is a desire, help the project is financially and I will have more motivation to develop it.
Scramble said:
Download link not working for me
Click to expand...
Click to collapse
yes , not working
Zhao li said:
yes , not working
Click to expand...
Click to collapse
Everything is excellent friend
下载链接对我缠绕
just a readme
GitHub - CryptoNickSoft/MIK: Repack Android partitions from Windows
Repack Android partitions from Windows. Contribute to CryptoNickSoft/MIK development by creating an account on GitHub.
github.com
GitHub - CryptoNickSoft/MIK: Repack Android partitions from Windows
Repack Android partitions from Windows. Contribute to CryptoNickSoft/MIK development by creating an account on GitHub.
github.com
thanks
CryptoNick said:
GitHub - CryptoNickSoft/MIK: Repack Android partitions from Windows
Repack Android partitions from Windows. Contribute to CryptoNickSoft/MIK development by creating an account on GitHub.
github.com
Click to expand...
Click to collapse
CryptoNick said:
GitHub - CryptoNickSoft/MIK: Repack Android partitions from Windows
Repack Android partitions from Windows. Contribute to CryptoNickSoft/MIK development by creating an account on GitHub.
github.com
Click to expand...
Click to collapse
Thanks
Halo sir,can this tool solve Samsung devices that fail to flash with odin in the system.img section, after editing system.img with the other tool ?
Droid Maps said:
Halo sir,can this tool solve Samsung devices that fail to flash with odin in the system.img section, after editing system.img with the other tool ?
Click to expand...
Click to collapse
Hey! Try. I did not test, since this functionality is not interesting to me.
After hours and hours of googling I finally found something that can unlock logo.img files on Windows. However, it doesn't seem to work for me. I got the following error:
[7920] Failed to execute script 'imgextractor' due to unhandled exception!
Traceback (most recent call last):
File "imgextractor.py", line 374, in <module>
File "imgextractor.py", line 368, in main
File "imgextractor.py", line 261, in __ext4extractor
File "ext4.py", line 484, in __init__
ext4.MagicError: Invalid magic value in superblock: 0x0000 (expected 0xEF53)
I would really appreciate help as I'm really desperate by now.