AIO Unpack Utility [ROMS][Windows] - Android General

***Abandoned*** Similar Stuff here
Hey Guys This is KP and After a Long Time, I am Releasing my another tool. This tool is specially compiled for Rom developers, as I have seen they need to do so much tidious work to successfully port a stable rom.
// All Downloads in Fourth Post
Since I can't make an auto-script for that, but still can make them happy in some other way.
So I am Presenting a Tool that can Easily Unpack ROMS, System.img or .dat, recovery, boot, APK, logo, Splash, TWRP backups and vice versa with some good editing tools for stuffs.
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
Requirements :
25 Mb space
.NET Framework 4.5.xx
Java JDK (here)
Windows PC (For Linux Use Wine Mono to use it)
Python (usually not needed, but still why to take risk )
Main Credits:
to osm0sis for his outstanding work
to Brut.all for his APKTool (Baksmali,Smali tool)
to ImgExtractor
to All Python or Linux Libraries I used
to Logo Builder Tool
to XDA Community
to benzyniarz for his Tool
to FFMEG a Great Tool
to Cygwin & Bluefirebird for his cecho
Sorry If i left Someone, tell me i will add here (all links in the original post)

Features​
~A Small Affordable Size Packaged
~Nice and Smooth GUI Interface
~PowerFull Logging System
~Perfect Output Capture on TextBox
~An Auto Skipable Processes (ASP)
~Unpack & Repack System.img and System.Dat Files
~Get Block Details of Raw System.img
~Convert Sparse to Ext4 System.img and vice-versa
~Convert System.Dat to System.img
~Unpack & Repack Recovery, Boot Img
~Display Img Info (kernel address, offset, pagesize,etc)
~Edit Logo.bin (Unpack & Repack , Replacing Tool, Get Image info like size, depth, dimensions,etc)
~Make a Flashable Logo.bin file
~Edit Splash.img (Unpack & Repack , Replacing Tool, Get Image info like size, depth, dimensions,etc)
~Convert Image (png,jpeg,bmp) to Splash.img
~Decompile & Recompile Apk Files
~Baksmali & Smali Classes.dex
~Unpack and Repack Android Backup Files, Make Them (.ab files gets from adb backup -all)
~Unpack Other Supportable Image Format (userdata, data, etc)
~Unpack TWRP Backups
~Unpack a Rom (with scc i.e if found some img or .dat file, then automatically decode them too)
~Sign a Rom or a Flashable Zip
~Create a Update.zip with auto META-INF Filling
~Rfs, EXT4 Unpacker Tool
~Build Prop Editor Tool
~Make a Flashable Build.prop File​
If you want some request feature to be added, contact me from the main tool thread. It will be my pleasure to do that

Beginners Guide to Use​
Its Basically very easy to do that, just click on any tab you want i.e suppose i want to unpack system.img just click on the browse button to do that then browse for outpath then Do Job. Also You can drag files onto the boxes and do stuff, inshort Tool has drag and drop feature supported. Also in between the process you can stop it by clicking on Stop button in bottom right (will be enabled automatically during processes).
System.img And System.Dat File​
Its Very Easy Just Drag and Drop or Browse for System.img File and Then Browse for their outpath by Double clicking second textbox and Click on Do JOB. Also you Can Convert Any System.img to Raw format or EXT4 Format by Clicking on Convert Button or You can get Blocks Details by Clicking Details Option. Same for System.Dat File. The Alert box checkbox is a function that will beep a sound whenever job is over and -i switch is for getting whole output from imgextractor.
Recovery and Boot.img​
To unpack or repack it is very easy same as we do for Above function, browse for recovery or boot img then for output path and then DO JOB. Also you can get Details of the img i.e Page size, Address, etc. You can also use drag and drop feature too.
Logo.bin and Splash IMG​
To unpack Logo.bin or do stuff on splash on image check on the respective radio button then right click on it and select a proper option. For logo.bin output images can be displayed on that page only, also you can double click on the image to see proper mods. Then you can replace the image, get details of it and do a lot of stuff. For Splash.img Output will be displayed on a new windows from where you can do stuff, also you can convert any png,jpeg,bmp images to Splash.img
Apk Manager (Apktool,baksmali,smali,ABE)​
Now if you have read above info then you can do it too.. Its very simple same thing drag and drop or browse then DO JOB. You can also baksmali any apk. Note the method used for baksmali is basic .locals only.If you want some more request a feature. ABE Tool below ApkTool is utility which will unpack android backup files i.e (.ab or .bak) Done from "adb backup -all"
and all.
Stuffs And Settings​
Here nothing to be tell read from buttons and you will get everything. ALso you can drag and drop some stuff on respective buttons, a tool tip will be displayed saying that drag and drop is supported on this button. From below settings you can change some Java Path and All Set java heap size i.e -Xm in java -jar. Howevery Python is not usable but JDK is must for APK Manager
So now I think you got the basic functionallity also there are many which I can not discussed here coz lack of time. So try to spend time with my tool and you will get all Stuff

***Abandoned*** Similar Stuff here
version 1.0 (16-5-2017)​~ Initial Release​
All Downloads HERE
Like my Work, Do Support me by Donating :laugh:
Want to Contact me or Request a Feature Contact me from the main website
EDIT : Sometimes your antivirus may detect it as a virus, but trust me its a false report. Because my file is not signed digitally by Microsoft and of course that needs money. So Remember to exclude folder from scanning:laugh:​

Hope to add repack tool
通过我的 1505-A02 上的 Tapatalk发言

andy19801210 said:
Hope to add repack tool
通过我的 1505-A02 上的 Tapatalk发言
Click to expand...
Click to collapse
Repack Tool is already there in the tool, just how to unpack files, you can repack it too just by change combo boxes or selecting repack radio buttion and stuffs

Ok, That's good.
通过我的 1505-A02 上的 Tapatalk发言

support 7.0?

Mr Hassan said:
support 7.0?
Click to expand...
Click to collapse
Yup

[email protected] said:
Yup
Click to expand...
Click to collapse
ok , how repack ext4 img? and avast detect it virus and deleted. and 2 days ago i refresh my window

Mr Hassan said:
ok , how repack ext4 img? and avast detect it virus and deleted. and 2 days ago i refresh my window
Click to expand...
Click to collapse
Its a false detect bro..my tool does not contain virus..the reason it detected it virus is because you are not using trusted anit virus and that too not pirated.... So.. let it be happen..its a false report ..in ur antivirus disable scan on this folder..

[email protected] said:
I)
Click to expand...
Click to collapse
ok, i add in excuse list, now 2nd thing, its not extracting ext4? and not repacking again ext4?
and i extract img, file, its taking long long and very long time, and still showing process

Mr Hassan said:
ok, i add in excuse list, now 2nd thing, its not extracting ext4? and not repacking again ext4?
and i extract img, file, its taking long long and very long time, and still showing process
Click to expand...
Click to collapse
Umm... I think..update is needed to my tool.. some tools should be updated.... For a being update the IMG_unpacker.exe in tools folder to the latest version..download it from Google

[email protected] said:
Umm... I think..update is needed to my tool.. some tools should be updated.... For a being update the IMG_unpacker.exe in tools folder to the latest version..download it from Google
Click to expand...
Click to collapse
yes time to update the tool, when you updated it so kindly qoute me,
and why you not some extra fetures ?

Mr Hassan said:
yes time to update the tool, when you updated it so kindly qoute me,
and why you not some extra fetures ?
Click to expand...
Click to collapse
Okay will add some extra features and ping you

Links broken

Android Oreo ??..Also link not working
Did it support android oreo??
and plz update the link

Shubhi singhal said:
Did it support android oreo??
and plz update the link
Click to expand...
Click to collapse
It should work fine for oreo

Jashane said:
Links broken
Click to expand...
Click to collapse
All link fixed!

[email protected] said:
All link fixed!
Click to expand...
Click to collapse
Java link?

Related

[Tool] Cwm nandbackup file Extractor ( .img/ .tar files )

CWM nandbackup files extractor ( .img/ .tar) ​
Here are the few things/ questions raised
The tool has been upgraded and you can get them here Utility tool
How do i extract the data.ext4.tar ?
How to combine all the *.ext4.tar *.ext4.tar.a , *.ext4.tar.b, *.ext4.tar.c ?
How to get my applications / data from the backup filesof CWM ?
Don't worry for the above question you are facing. This tool will help you out.
Requirements
Java JDK :good:
Need Patience :silly:
How to use
Extract the tool.zip and follow up the pics and your work is done
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
Hope this tool may help some one . and Don't Forget to hit thanks button. have fun
Download
You can also extract the data.img , system.img files on by placing the files to image files folder
Here is the download of the tool at bottom this post
Have fun
Perfect tool Thank you for your hard Word. Now everthing is very easy
The tool which I have been waiting for...works like charm!!
Thank for providing us this tool.
Gonna try to make GUI for this tool.
needed from ages
well first of all congrats for this wonderful tool it was much needed right from the beginning. plus i like your profile pic lol its my fav "KICK"...
will this work on twrp?
or it has different backup file type?
I just switched to twrp but not yet trying nandroid
Perfect tool!! This is really gonna help me with my custom rom instead of trying to copy the /system files one by one to my internal storage.
i'll be waiting for os x version as well (since i don't always run windows)
great tool btw
and congrats for making it to the portal
Error:'Tar' is not recognized as an internal or external command. And also 'cat'.
Where do these commands exist? are they exe files present somewhere in the java jdk folder?
Before you ask. Yes i have installed java jdk.
Do I have to setup the environment variables?
LastStandingDroid said:
i'll be waiting for os x version as well (since i don't always run windows)
great tool btw
and congrats for making it to the portal
Click to expand...
Click to collapse
sure i will do that when i am free..........
zamzameir said:
will this work on twrp?
or it has different backup file type?
I just switched to twrp but not yet trying nandroid
Click to expand...
Click to collapse
I haven't tested but there is nothing more difference between the files. hope it works
dattafilthyd said:
Error:'Tar' is not recognized as an internal or external command.
Before you ask. Yes i have installed java jdk.
Do I have to setup the environment variables?
Click to expand...
Click to collapse
the common softwares are 7z / winrar / winzip are minimum requirement ( i have not listed these because these are very commonly used by every user )
Only cwm or twrp too?
venkat kamesh said:
The common softwares are 7z / winrar / winzip are minimum requirement ( i have not listed these because these are very commonly used by every user )
Click to expand...
Click to collapse
All of them are installed bro. (i.e 7z winrar and winzip)
The bat file you've careated is unable to find 'tar' command. Is it necessary that i place it in a particular location like c drive as such.?
['tar' is not recognized as an internal or external command]
suggestions?
EDIT: I used the cygwin terminal to concatenate [cat] the tar files and i was able to open them combined file via 7z and winrar.
code: cat data.ext4.tar data.ext4.tar.a data.ext4.tar.b data.ext4.tar.c > datafull.tar
Thank you.
the_vanya1 said:
Only cwm or twrp too?
Click to expand...
Click to collapse
i havent tested but hope it works good
dattafilthyd said:
All of them are installed bro. (i.e 7z winrar and winzip)
The bat file you've careated is unable to find 'tar' command. Is it necessary that i place it in a particular location like c drive as such.?
['tar' is not recognized as an internal or external command]
suggestions?
Click to expand...
Click to collapse
there is no particular location to be place.... :good:
may be binaries get corrupted try to install this tool :- http://gnuwin32.sourceforge.net/packages/gtar.htm
it would help you out for using this tool
Error:'Tar' is not recognized as an internal or external command
venkat kamesh said:
You can also extract the data.img , system.img files on by placing the files to image files folder
Here is the download of the tool at bottom this post
Have fun
Click to expand...
Click to collapse
you know, this is an excellent utility, will come handy....what I always thought about is, converting andbackup files into flashable zip - say using your tool, you extracted, and then remove or add or made some changes on it, and then converting to flashable zip..., if you make an ultimate utility tool, imaging that you did nandroid backup of your stock ROM with custom recovery, having a tool to extract it (your utility), and then if you wish deodexed it, and then last step put all into CWM flashable zip....now if you combine all this steps, you will end up ultimate best utility tool ever... I f...king even pay or donate for it...
the_vanya1 said:
Error:'Tar' is not recognized as an internal or external command
Click to expand...
Click to collapse
you need to install 7zip/winzip ( any one of them ) read the previous post
please ready the posts so there you get a solution
jazzespresso said:
you know, this is an excellent utility, will come handy....what I always thought about is, converting andbackup files into flashable zip - say using your tool, you extracted, and then remove or add or made some changes on it, and then converting to flashable zip..., if you make an ultimate utility tool, imaging that you did nandroid backup of your stock ROM with custom recovery, having a tool to extract it (your utility), and then if you wish deodexed it, and then last step put all into CWM flashable zip....now if you combine all this steps, you will end up ultimate best utility tool ever... I f...king even pay or donate for it...
Click to expand...
Click to collapse
thank you for your great idea which is very worth
i had finally made that tool which has options like
1. extract data
2.extract system
3.deodex/ signed zip/zipalign
4.odexed /signed zip/zipalign
5.image file extraction
6. signer
7. odex/deodex invividual
the odex/deodex have different options like
if you extract the system file. it ask an option to odex/deodex . if you need to deodex that it will continue to deodex / zipalign/ signed which will be worked. and same as with odex..
if you dont have any imagefile extracted . there is an option that you can pull from the device and works as same above process
you can sign the zip/zipaline individually as per needed.
hopefully it works on all devices like ( sony, lg, samsung and almost all )
no specification of roms ( every rom is supported )
works for all version of android ( from 2.2 to 4.4.4)
thank you @jazzespresso for this idea
going to post as soon as possible
venkat kamesh said:
thank you for your great idea which is very worth
i had finally made that tool which has options like
1. extract data
2.extract system
3.deodex/ signed zip/zipalign
4.odexed /signed zip/zipalign
5.image file extraction
6. signer
7. odex/deodex invividual
the odex/deodex have different options like
if you extract the system file. it ask an option to odex/deodex . if you need to deodex that it will continue to deodex / zipalign/ signed which will be worked. and same as with odex..
if you dont have any imagefile extracted . there is an option that you can pull from the device and works as same above process
you can sign the zip/zipaline individually as per needed.
hopefully it works on all devices like ( sony, lg, samsung and almost all )
no specification of roms ( every rom is supported )
works for all version of android ( from 2.2 to 4.4.4)
thank you @jazzespresso for this idea
going to post as soon as possible
Click to expand...
Click to collapse
yeah making it work for all devices going to be quit challenging, there are, as you may know, too many odex/deodex tools here in XDA, but none are bug free. In fact, I always end up some kind of error during deodexing, so this part is always painful process no matter what devices you have, and you know people using Windows, Linux, Mac..etc, this puts more complexity to entire process.
but you have to start from somewhere, right?
hopefully, this process of yours grow into some nice utility that combines all other tools into one.:good:
Needless to say, good job and very much appreciated releasing it here in XDA community!
venkat kamesh said:
.....i had finally made that tool which has options........
......going to post as soon as possible.......
Click to expand...
Click to collapse
that's some spread - the menu :good: bring it on!
Already did it sir, and i use winrar
jazzespresso said:
yeah making it work for all devices going to be quit challenging, there are, as you may know, too many odex/deodex tools here in XDA, but none are bug free. In fact, I always end up some kind of error during deodexing, so this part is always painful process no matter what devices you have, and you know people using Windows, Linux, Mac..etc, this puts more complexity to entire process.
but you have to start from somewhere, right?
hopefully, this process of yours grow into some nice utility that combines all other tools into one.:good:
Needless to say, good job and very much appreciated releasing it here in XDA community!
Click to expand...
Click to collapse
m0han said:
that's some spread - the menu :good: bring it on!
Click to expand...
Click to collapse
thank you and here is a pic that i am testing all the things i found no errors and still testing
because it need to be perfect

[HOW TO] reverse engineer kernel

Hi,
So although companies of course are bound by law to release kernel sources, and most of them do, there are sometimes circumstances where you still would like to see the disassembly of the kernel code. For example sometimes an ASM deadlisting can be easier to understand than complicated C++ code. Or maybe you suspect that your kernel code is slightly different than the source code your manufacturer supplied, maybe due to a slightly different configuration. It happens.
Anyway, whatever reason you might have, this is a small tutorial on how to obtain that kernel code in a deadlisting.
1) First of all you need of course to dump the boot image. I normally do this via: cat /dev/block/mmcblk0p17 > /sdcard/boot.img. But it depends on which partition the boot image resides. Use a partition tool to find out.
2) Seperate the kernel image from the boot image. I use Android Image kitchen myself.
3) The kernel image is self extracting. This means that it is just the compressed kernel + the decompression code to decompress it. We want to use a regular decompression utility so we want to strip that decompression code off in order for a normal decompression utility to handle it. Now, on older kernels (up to 2013 I think) you could use a tool like this to decompress the kernel: http://forum.xda-developers.com/showthread.php?t=901152 It's based on the fact that the kernel is Gzip compressed. However newer kernels use LZO compression. Luckily it's quite easy to do it manually. First of all you need to cut off the part upto where the kernel image starts (the decompression code). You need to search for 0x89 0x4c 0x5A 0x4F. That's 0x89 followed by "LZO", which is the start of the compressed file header. Now in my case I needed the 2nd hit (in my case the 1st hit is followed by some text and then like 0x50 bytes later follows the second hit, I needed that one). So cut off the part upto that, rename the file as a .LZO file and then you can just decompress it with any LZO decompresser, for example "Universal Extractor".
4) So now we have a decompressed kernel image. You could load this up into IDA pro already but reverse engineering will be hard since all symbols are missing. So how to get the symbols ? We can dump them from your phones memory too ! However the linux kernel is since quite some versions already protected against doing that, for obvious reasons. If you're root though, you can disable that protection via issueing:
Code:
echo 0 > /proc/sys/kernel/kptr_restrict
Next you can simply dump the symbols like:
Code:
cat /proc/kallsyms >/sdcard/symbols.txt
5) You now have a file containing all the symbols. But how to convert this into an IDA pro script ? You could write a simple tool or script that does it. Luckily I already did that for you, see the attached file However the symbol file you just dumped from memory wont contain the windows carriage returns after each line, which my tool needs (sorry too lazy to fix it up, lol), so you need to add them first. I use 'edit pad lite'. In that you simply copy en paste the file and save it. Once you open it in notepad you will now see it's perfectly carriage return formatted. Now use my tool to open it and it will create an IDC script
6) ready to load it all up in IDA pro now ! Open the kernel in IDA pro, select ARM as processor (that is if you're on such a phone of course) and load the kernel to the right address. Usually it will be the first address of your IDC script. But also a tool like Android Image Kitchen will show you the correct address. Then if the kernel is opened and loaded at the correct address, simply open the IDC script and it will add all symbols.
And there you have it ! A perfect deadlisting of your android kernel, containing all symbols ! Happy reverse engineering !
very nice one. good job bro.
Sent from my GT-I8190 using XDA Forums Pro
Subscribed, amazing thread and amazing tool, thank you for the insight, any more reversing knowledge with olly or ida is greatly appreciated.
Decent introduction, but this is just the beginning... Good for comparison purposes as you mentioned, but what else? *shrug*
Sent via Tapatalk on my Xperia Z
core7x said:
very nice one. good job bro.
Click to expand...
Click to collapse
berryman13 said:
Subscribed, amazing thread and amazing tool, thank you for the insight, any more reversing knowledge with olly or ida is greatly appreciated.
Click to expand...
Click to collapse
Glad you liked it guys.
CosmicDan said:
Decent introduction, but this is just the beginning... Good for comparison purposes as you mentioned, but what else? *shrug*
Click to expand...
Click to collapse
Not sure what you mean, you want me to teach you how to read ASM and/or use IDA pro ? That's a bit beyond the purpose of this thread I'm afraid.
@gekkehenkie11 Does the kernel decompressing end eventually ???
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
Im trying to follow your guide and im ok so far, i got the symbols from my phone, im decompresing the kernel right now.. we will see about using your script and IDA pro later.
THANK YOU!
Edit: i have the decompressed kernel now, i used the symbols to create the ida script using your script, now... i have to learn how to use it in ida
pirej said:
Edit: i have the decompressed kernel now, i used the symbols to create the ida script using your script, now... i have to learn how to use it in ida
Click to expand...
Click to collapse
Select ARM as processor and 0Xc0008000 as the kernel loading address (verify with your symbols, should be the same address as your first symbol) ! Good luck.
When i load the symbol-script made with your tool in to ida.. i get this type of error messages, a lot of them
C0103568: can't rename byte as 'vfp_propagate_nan' because the name is already used in the program.
C0F96E58: can't rename byte as 'byte_mux_ops' because the name has a reserved prefix.
C0F242FC: can't rename byte as 'ten_thousand' because this byte can't have a name (it is a tail byte).
Click to expand...
Click to collapse
There really is "vfp_propagate_nan" twice in my symbols dumped from my phone, is this normal or i did something wrong?
And I assume this would allow us to, like, recreate a particular kernel's source code when the original sources to it are unavailable, using extant code from a similar repo, right?
blakegriplingph said:
And I assume this would allow us to, like, recreate a particular kernel's source code when the original sources to it are unavailable, using extant code from a similar repo, right?
Click to expand...
Click to collapse
Hai I am new one n forum make any sample video understand
Post any video tutorials
After achieving deadlist how do we do to get kernel source in conventional format (like they have on github)..
I'm not asking u to write a guide. I'm asking "where i can find tutorial"
I find in 4pda forum to use "snowman decompiler" plugin in ida to convert deadlist to c++
Should i use it??
Hi I m looking for Lenovo K5 Note A7020 kernel.
Can anyone guide me to right direction.
Hi,
I m looking for Lenovo K5 Note A7020a48 kernel source can anyone guide me to right direction.
Hello, first thank you for this precious guide !
I'm currently facing problems reverse engineering kernel-ranchu kernel provided to modern AVD. Tried both of your methods and I can't get a valid kernel img. Any idea why ?
flaccidattempts said:
There is no certified way to reverse source code from binary. The process in which it has been compiled has to be reversed.
Now if you want to analyze binary and cross-examine it with android from source files, then you can derive using basic lamba functions to infer missing pieces.
But..... binaries can be engineered in a way that the code becomes obvious ESPECIALLY if you have Android from Source.
Essentially, you can download android from source using google repo tool, repo the release edition, compare side by side, file for file, what is different.
I Use these linux command s
From there i use a custom python file that 'line for line' searches for the strings, if they match, it logs the match.
once done with that, it sends it over to sublime text, which for some reason, on rare occasions resolves the binaries immediately, especially when paired with the matching strings file.
For files that are obviously encrypted, i wait till the end and brute force popular hashes, map out links, use lambda functions and use general deduction to solve to source.
If you want to learn how to analyze binaries with linux watch "malware analysis" videos on youtube
Click to expand...
Click to collapse
OEM/Manufukturer has an open source policy but some of them don't publish the kernel source code. I found the helpful answer to reverse kernel and I'll put it in the right suitable place.
lol im sorry. this is what im working with
unless you are trying to get from img to bin? or trying to get bin to text? or bin to c?
blu will not post there source or email me back, so im going to reverse engineer it to piss them off. Decompilers for llvm and clang and such exist. blueline hasnt put to much effort into hiding the source. I found a json @ link file that simplified the process
flaccidattempts said:
lol im sorry. this is what im working withView attachment 5622895
unless you are trying to get from img to bin? or trying to get bin to text? or bin to c?
Click to expand...
Click to collapse
IMG_Extractor_3.0.0.zip
drive.google.com
I extracted boot.img with img extractor v3.0.0 and get a compressed kernel image. I'm not sure what format it is but I want to reverse it
download ghidra from github. start importing files to assembly code

[DEV][LINUX/OSX] IMG Patch Tools | sdat2img for OTA zips

{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
most part of Introduction from taken sdat2img thread
if you want extract non OTA zip i suggest to use sdat2img tool
FOR AB OTA ZIPS USE THIS SCRIPT AND PAYLOAD EXTRACTOR​
in this tools i made block_image_update() function from android recovery to a binary to run on PC and patch system.img with DAT files on OTA package to update system.img by OTA
also we have apply_patch() function for patching boot.img and other files like firmwares
Introduction
You probably know already that starting from Android 5.x (Lollipop) compiled roms (aosp,cm,stock) are not compressed anymore the way they used to be on previous android versions. On previous versions all content inside /system folder that has to be extracted within our device was either uncompressed (simple /system folder inside our flashable zip) or compressed in a system.img file, which it is a ext4 compressed file; both of these, anyway, were readable and we could see all system files (app,framework, etc).
The problem comes in >=5.0 versions, this method is not used anymore. Why? Because roms started to be always larger, so it is necessary to compress them even more.
What does new Android zips (full roms, but also OTAs) contain?
New Android flashable zips are made this way:
boot.img (kernel)
file_contexts (selinux related)
META-INF (folder containing scripts)
system.new.dat (compressed /system partition)
system.patch.dat (for OTAs)
system.transfer.list (see explanation below)
and other patch files (.p only on OTA zip)​
What does updater-script contains then?
The updater-script uses a brand new function: block_image_update(), this method basically decompresses necessary files inside the device. Let's study it.
From google git source code, if we go inside the new file /bootable/recovery/updater/blockimg.c, we find at the end of it the registration of the function block_image_update() as the method BlockImageUpdateFn() which starts at line 254. Here finally we find all information we need to know about the decompression of the .dat file(s). First file we analyze is system.transfer.list which Google tells us:
The transfer list is a text file containing commands to transfer data from one place to another on the target partition.
Click to expand...
Click to collapse
But what each line means?:
First line is the version number of the transfer list; 1 for android 5.0.x, 2 for android 5.1.x, 3 for android 6.0.x, 4 for android 7.x
Second line is the total number of blocks being written
Third line is how many stash entries are needed simultaneously (only on versions >= 2)
Fourth line is the maximum number of blocks that will be stashed simultaneously (only on versions >= 2)
Fifth line and subsequent lines are all individual transfer commands.
Click to expand...
Click to collapse
all transfer commands is :
bsdiff
*erase
free
imgdiff
move
*new
stash
*zero
BlockImageUpdate is reading system.transfer.list and executing all commands
But BlockImageVerify doesn’t execute * commands, which not to make changes on system.img just verifying update can happen
original sdat2img tool only support "new" command
Ok, but how to Patch the system.img with OTA files?
All instructions are below. binaries are involved. Please read carefully step by step.
You can use/modify these files and/or include them in your work as long as proper credits and a link to this thread are given.
If you have questions or problems
write here
Thanks
- @xpirt , for original sdat2img tool and useful thread
XDA:DevDB Information
IMG Patch Tools, sdat2img for OTA zips, Tool/Utility for all devices (see above for details)
Contributors
erfanoabdi
Source Code: https://github.com/erfanoabdi/imgpatchtools
Version Information
Status: Testing
Created 2017-07-21
Last Updated 2020-01-23
Usage
Code:
./BlockImageUpdate <system.img> <system.transfer.list> <system.new.dat> <system.patch.dat>
args:
<system.img> = block device (or file) to modify in-place
<system.transfer.list> = transfer list (blob) from OTA/rom zip
<system.new.dat> = new data stream from OTA/rom zip
<system.patch.dat> = patch stream from OTA/rom zip
Code:
./ApplyPatch <file> <target> <tgt_sha1> <size> <init_sha1(1)> <patch(1)> [init_sha1(2)] [patch(2)]...
args:
<file> = source file from rom zip
<target> = target file (use "-" to patch source file)
<tgt_sha1> = target SHA1 Sum after patching
<size> = file size
<init_sha1> = file SHA1 sum
<patch> = patch file (.p) from OTA zip
Code:
usage: ./scriptpatcher.sh <updater-script>
args:
<updater-script> = updater-script from OTA zip to patch recovery commands
Example
for example from updater-script of OTA we have:
Code:
block_image_update("/dev/block/bootdevice/by-name/system", package_extract_file("system.transfer.list"), "system.new.dat", "system.patch.dat")
apply_patch("EMMC:/dev/block/bootdevice/by-name/boot:33554432:f32a854298814c18b12d56412f6e3a31afc95e42:33554432:0041a4df844d4b14c0085921d84572f48cc79ff4",
"-", 0041a4df844d4b14c0085921d84572f48cc79ff4, 33554432,
f32a854298814c18b12d56412f6e3a31afc95e42,
package_extract_file("patch/boot.img.p"))
after getting system.img and boot.img from firmware This is equals of previous functions on PC with this tools:
Code:
~$ ./BlockImageUpdate system.img system.transfer.list system.new.dat system.patch.dat
~$ ./ApplyPatch boot.img - 0041a4df844d4b14c0085921d84572f48cc79ff4 33554432 f32a854298814c18b12d56412f6e3a31afc95e42
scriptpatcher.sh will generate all commands automatically from updater script so run it like:
Code:
~$ ./scriptpatcher.sh META-INF/com/google/android/updater-script > fullpatch.sh
check fullpatch.sh your self, you need to provide all images and files in correct name and patch as mentioned in mount and other commands of fullpatch.sh
Building Requirements
For Building this tool you need :
zlib
libbz2
openssl
It currently supports Linux x86/x64 & MacOS, Not tested on Windows.
Compile and Build command:
Code:
make
Youtube
Download links:
GitHub Release
Changelog:
GitHub Commits
Known Bugs/Issues:
Plz test and report
Nice work
Very nice
Sent from my LG-LS997 using Tapatalk
Wow, I tried to apply OTAs manually myself, but never got it to work. Getting the propper tools from you is awesome!
One tiny question though: Does applying/verifying a system update to system.img require a lot of temporary space or memory?
I am running Ubuntu x64 in a VM (VirtualBox) on Windows 10. Verifying a system update doesn't really do much, except keeping the CPU busy.
This is the output of "./BlockImageVerify system.img system.transfer.list system.new.dat system.patch.dat":
Code:
performing verification
creating cache dir cache
cache dir: cache
blockimg version is 3
maximum stash entries 236
creating stash cache/537ed49fb5f6c32dc3d205d78b6084fe54f70cd3/
The cache folder remains empty, there is no harddisk activity and only the CPU is working at 100 %. I interrupted BlockImageVerify after 30 minutes.
daniel_m said:
Wow, I tried to apply OTAs manually myself, but never got it to work. Getting the propper tools from you is awesome!
One tiny question though: Does applying/verifying a system update to system.img require a lot of temporary space or memory?
I am running Ubuntu x64 in a VM (VirtualBox) on Windows 10. Verifying a system update doesn't really do much, except keeping the CPU busy.
This is the output of "./BlockImageVerify system.img system.transfer.list system.new.dat system.patch.dat":
The cache folder remains empty, there is no harddisk activity and only the CPU is working at 100 %. I interrupted BlockImageVerify after 30 minutes.
Click to expand...
Click to collapse
Ah actually yes you need free space on RAM as much as both patch.dat and new.dat sizes
It's on my todo list to fix it, https://github.com/erfanoabdi/imgpatchtools/blob/master/blockimg/blockimg.cpp#L383
How to extract the file system.new.dat
evangelico793 said:
How to extract the file system.new.dat
Click to expand...
Click to collapse
You can find it in OTA zip
Motorola? See this : motorola.erfanabdi.ir
erfanoabdi said:
You can find it in OTA zip
Motorola? See this : motorola.erfanabdi.ir
Click to expand...
Click to collapse
No longer look at the picture
erfanoabdi said:
You can find it in OTA zip
Motorola? See this : motorola.erfanabdi.ir
Click to expand...
Click to collapse
Something Looks Wrong ReCheck inputs Or No Update Available
for moto g4 play 6.0.1
evangelico793 said:
No longer look at the picture
Click to expand...
Click to collapse
Please send picture again
404 not found
evangelico793 said:
Something Looks Wrong ReCheck inputs Or No Update Available
for moto g4 play 6.0.1
Click to expand...
Click to collapse
You are doing something wrong see thread for help and examples
@erfanoabdi
Thank you a ton for these tools!
They work like a charm :good:
I knew there must be a way to do this, but it's definitely above my paygrade.
@erfanoabdi
I've been trying scriptpatcher.sh on various updater-scripts and have noticed some bugs.
If you're interested in looking at the files, let me know and I'll post them.
Q9Nap said:
@erfanoabdi
I've been trying scriptpatcher.sh on various updater-scripts and have noticed some bugs.
If you're interested in looking at the files, let me know and I'll post them.
Click to expand...
Click to collapse
Yeah, there's lots of bugs in that script
I appreciate any kind of help
So far i know :
Only supporting /dev/block/boot.../by-name partitions
Can't mount ext4 in macOS
I disabled verify, but we can verify images
And i haven't tested it so much
If it gets more complicated Maybe we have to rewrite it on python.
erfanoabdi said:
Yeah, there's lots of bugs in that script
I appreciate any kind of help
So far i know :
Only supporting /dev/block/boot.../by-name partitions
Can't mount ext4 in macOS
I disabled verify, but we can verify images
And i haven't tested it so much
If it gets more complicated Maybe we have to rewrite it on python.
Click to expand...
Click to collapse
*removed*
@erfanoabdi
I noticed that there was an update to the source today to enable the bonus file argument.
I tried to create a recovery.img with a boot.img, recovery-from-boot.p, and recovery-resource.dat.
I tried patching to create a new recovery image and also tried patching the boot image in place.
It always returns "Unknown patch file format".
I am able to use these files to create recovery with the on-device applypatch binary, so not sure why it's throwing the "unknown patch file format" error.
Q9Nap said:
@erfanoabdi
I noticed that there was an update to the source today to enable the bonus file argument.
I tried to create a recovery.img with a boot.img, recovery-from-boot.p, and recovery-resource.dat.
I tried patching to create a new recovery image:
#Output:
creating cache dir cache
cache dir: cache
patch boot.img:
failed to stat "recovery.img": No such file or directory
Unknown patch file format
Done with error code : 1
and also tried patching the boot image in place:
#Output:
creating cache dir cache
cache dir: cache
patch boot.img:
Unknown patch file format
Done with error code : 1
I am able to use these files to create recovery with the on-device applypatch binary, so not sure why it's throwing the "unknown patch file format" error.
Any ideas? Is my syntax incorrect?
Click to expand...
Click to collapse
That was chainfire commit changes how can i say "no" to his PR
I didn't had time to check it
I'll check it out when I could
Q9Nap said:
@erfanoabdi
I noticed that there was an update to the source today to enable the bonus file argument.
I tried to create a recovery.img with a boot.img, recovery-from-boot.p, and recovery-resource.dat.
I tried patching to create a new recovery image:
#Output:
creating cache dir cache
cache dir: cache
patch boot.img:
failed to stat "recovery.img": No such file or directory
Unknown patch file format
Done with error code : 1
and also tried patching the boot image in place:
#Output:
creating cache dir cache
cache dir: cache
patch boot.img:
Unknown patch file format
Done with error code : 1
I am able to use these files to create recovery with the on-device applypatch binary, so not sure why it's throwing the "unknown patch file format" error.
Any ideas? Is my syntax incorrect?
Click to expand...
Click to collapse
I've tested recovery-from-boot by chainfire and i can confirm its working
Also i fixed no such file error
Try to compile new source
*edit*
Fixed!

[IDE] ROMS][Windows] Poison Kitchen IDE [Dev Preview 2][2.3-8.1]

Poison Kitchen IDE
Development preview
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
​
Description
A powerful IDE for android ROM development
Runs native on WINDOWS, MacOS themed.
Its powered by my XanderUI class library for the .net framework
Currently Development preview builds are only available, meaning things may be broken, behave incorrectly or other
Click to expand...
Click to collapse
Features
-Full GUI coded in C# for fast runtime
-XanderUI based controls(My C# class library)
-Based on .net 4.5
-Support for every single android version
-Unpack rom from (.zip, .tar, .md5, .img, aml_upgrade_package)
-Pull all required files from device(root needed to copy kernel block)
-Adb, fastboot and drivers installater
-ROM information
-Explorer
-Deodexing(4.4.4 and lower ATM)
-Unpacking the kernel
-Converting file_contexts.bin to standard text
-Kernel explorer
-Repacking kernel
-Logging
-Auto-generating updater-script
-Use generic symlinks if files detected
-Use generic file contets if the kernel does not contain file_contexts
-/data/app auto transition to new rom(somewhat working)
-Wipe data excluding /data/media(/sdcard path)
-Auto kernel block detection
-Auto mounting /system and /data
-Packing rom
-Signing rom
-Updater-script editor
-Extansion support
-Emulated exension scripts(applied via C#)
-Degapps extension
-Deknox extension
-Custom emoji extension
-Enable sony apps extension
Click to expand...
Click to collapse
Features not yet implemented
-root via magisk(systemless) and superSU(standard)
-init.d
-deodexing 5.0 and up
-adbd insecure
-init.d tweaks
-build.prop tweaks
-change display I.D
-add sysrw/ro binary
-logging needs tweaking
-loading rom information updated in the background
-Unpacking RUU as project(HTC)
-Unpacking TFT as project(SONY)
-Unpacking system.dat(sparse)
-Setting your actual device as the project and apply changes in realtime
-/data/app auto transition to new rom
-Kernel may not unpack
-Convert line endings in explorer context menu
-Inbuilt file editor(with EOL auto-detection)
-Boot animation player/changer
-Auto flash rom with ORS(TWRP)
-Bluestacks as rom
Click to expand...
Click to collapse
Settings
Load settings()
-Set default startup project or startup menu
-Enable/disable logging
-Stop logger from detecting files or folders added, deleted, changed or moved
Installation settings()
-Change romname
-Change installation type(autodetect on unpack, User generated, Tool generated)
-Change file contexts method(Auto, extracted from kernel, assumed)
-Enable/disable safewipe
-Enable/disable data/app auto transition
-Enable/disable autodetect ernel blockpath(add path below)
Pack settings()
-Change compression level
-Add signing method(pack into presigned, sign on zip, none)
-Change java heapsize
-Exclude files and folders from being packed/detected by IDE
Default program settings()
Change default program to open image files
Change default program to open video files
Change default program to open audio files
Change default program to open prop files
Change default program to open archive files
Change default program to open jar/apk files
Change default program to open other type files
Current version and updates()
Cleanup settings()
Click to expand...
Click to collapse
License
GNU GPL V3
Downloads
Downloads page
XDA:DevDB Information
Poison Kitchen IDE, Tool/Utility for the Android General
Contributors
Ricky Divjakovski
Version Information
Status: Testing
Created 2018-04-19
Last Updated 2018-04-19
Creating extensions and documentation
Code:
Description -
As extensions are a great adittion to the IDE, whats the use if you cant make your own for automated building?
Information you need to know -
The tool looks for the file "extension.info".
In the extension.info file you will specify the extension name, description and the poison shell script file(.psh).
Package the folder containing the extension as a zip archive
------------------------------------------------------------------
Entension index
------------------------------------------------------------------
Sample extension -
https://github.com/Ricky310711/Poison-Kitchen-Extension-Example
extension.info -
Lines will only be read if starting with "Name", "Description" or "Run"
-------------------- code exmpla
# this sets the extension name
Name:Fake optimizer
# this sets the extension description
Description:Do not apply this to rom, its a fake extension to show an example
# this is the poison script to run(must be in same directory)
Run:FakeOpt.psh
------------------------------------------------------------------
Scripting language(.psh file)
------------------------------------------------------------------
Information
-Must be linux EOL(\n)
-Anything but recognised 1st args are ignored
-Any errors will be ignore by the shell
-Use full paths asif you are in the root(/)
Extracting content to rom
---------- code example
EXTRACT|myFolder
1st arg states we are extracting(copying) a folder to the rom
2nd arg is the folder to extract(must be in same directory as extansion)
NOTE: This will extract the folder to the root of the rom
Changing a line in a file
---------- code example
CHANGE|START|/system/build.prop|ro.product.device=|THIS IS STARTS TEST
1st arg specifies we are changing a file
2nd arg specifies where on a line to search for the string(arg4)
3rd arg specifies the file to change
4th arg specifies the string to look for
5th arg is what you would like to replace the line with
The second arg can be START, CONTAINS or END
Appending a file
---------- code example
APPEND|TOP|/system/build.prop|# A TEST FOR APPENDING TOP
1st arg specifies we are appending a file
2nd arg specifies if we are appending at the TOP or BOTTOM
3rd are is the file to append
4th arg is the content to append
Remove a line from a file
---------- code example
REMOVE|/system/build.prop|# end fota properties
1st arg states we are removing a line from a file
2nd arg specifies the file
3rd arg is the string to look for in the line
Delete a file or folder
---------- code example
DELETE|/system/preinstall
Pretty straight forward, will delete a file or folder called "preinstall" from /system/
Create a file or folder
---------- code example
CREATE|DIRECTORY|/preinstall
arg 1 states we are creating something
arg 2 specifies if a FILE or FOLDER
arg 3 is the file or folder to create
Rename a file or folder
---------- code example
RENAME|/system/bin/am|amRenamed
1st arg specifies we are renaming a file or folder
2nd arg is the file or folder
3rd arg is the new name
Changelog
Development preview 2
-Added pull rom from device in setup
-Smoother nvigation
-XanderUI 1.6.0 integration
-Message boxes are now themed like the app
-Extensions now show progress upon running
-Deodexing up to Android 4.4.4 implemented
Development preview 1
-initial release
reserved3
supports all versions of android and all devices, no manual input needed.
dev preview 3 possibly tommorow
Yay now I can at least try to build my own g6 ROMs. Nice work.
development on hold until the 30th as im on holiday, i have been dedicating little time to this as internet here is extremely slow
Magisk and SU support added aswell as deodexing 5.x > 6.0
Also working on disabling signature verification, adding sysrw(as binary)
hi, im trying out the program, it never completes the extraction, and the progress icon starts at 53% do i need to do anything when trying to start the program.
i haVE TRIed running as administartor and without running as admin.
thanks
Twisted714 said:
hi, im trying out the program, it never completes the extraction, and the progress icon starts at 53% do i need to do anything when trying to start the program.
i haVE TRIed running as administartor and without running as admin.
thanks
Click to expand...
Click to collapse
A dialog will more then likely poppup requesting permission to run imgextractor.exe, be sure to accept that to complete the process
Ricky Divjakovski said:
A dialog will more then likely poppup requesting permission to run imgextractor.exe, be sure to accept that to complete the process
Click to expand...
Click to collapse
i am attaching some pics to what happens.
please advise. thanks
there are a couple more that are insignificant
Twisted714 said:
i am attaching some pics to what happens.
please advise. thanks
there are a couple more that are insignificant
Click to expand...
Click to collapse
Could you please PM me with pics of the firmware your selecting or even a link?
I've gone ahead and tried this. I pointed the app to my system.img (not the fastboot zip) and ended up with "error extracting". Tool looks promising. ROM is available for download here:
http://en.miui.com/download-333.html
I extracted it and used the images/system.img
oreo27 said:
I've gone ahead and tried this. I pointed the app to my system.img (not the fastboot zip) and ended up with "error extracting". Tool looks promising. ROM is available for download here:
http://en.miui.com/download-333.html
I extracted it and used the images/system.img
Click to expand...
Click to collapse
Im going to test now, if the firmware has system.transfer.list, and system.dat, it will not be able to be unpacked until i make a native library or extension to perform the operation as i think it would be extremely stupid for the need to have python installed to run.
The only reason i havent rebuilt smali/baksmali etc is 1. Would take me months, 2. we are modifying a system that relies on java to operate.
in future, hefty operations like unpacking etc, will be coded in ASM/C code for faster operation, Im planning on making the whole project open source to allow changes and fixes submitted by other developers, So if anyones interested let me know and ill upload the source code(Written in C# for the .net 4.5 framework)
Ricky Divjakovski said:
Im going to test now, if the firmware has system.transfer.list, and system.dat, it will not be able to be unpacked until i make a native library or extension to perform the operation as i think it would be extremely stupid for the need to have python installed to run.
The only reason i havent rebuilt smali/baksmali etc is 1. Would take me months, 2. we are modifying a system that relies on java to operate.
in future, hefty operations like unpacking etc, will be coded in ASM/C code for faster operation, Im planning on making the whole project open source to allow changes and fixes submitted by other developers, So if anyones interested let me know and ill upload the source code(Written in C# for the .net 4.5 framework)
Click to expand...
Click to collapse
Not sure if this helps but I've run Imgextractor directly on my system.img with this result:
Code:
Mi-A1-Repository>Imgextractor Mi-A1-Repository\Roms\Fastboot\tissot_images_V.9.5.10.0.ODHMIFA_8.0\images\system.img
ImgExtractor version 1.3.6 <Created by And_PDA (Based on sources ext4_unpacker)>
Extractor for images in EXT2\EXT3\EXT4\YAFFS2\CRAMFS filesystem formats
support SPARSE\SIN\MOTO structure formats
Open image file Mi-A1-Repository\Roms\Fastboot\tissot_images_V.9.5.10.0.ODHMIFA_8.0\images\system.img (size 3221225472 bytes) successfull...
Analize format of file. Please wait...
Found SPARSE FORMAT
Found EXT4 FORMAT
free space in image 188895232 bytes
Extract started. Please wait...
Extract 750 folders and 6306 files successfull
Found 386 symlink files
File stats (uid, gid, permission) save to Mi-A1-Repository\Roms\Fastboot\tissot_images_V.9.5.10.0.ODHMIFA_8.0\images\system__statfile.txt
Extract finish success
Press Enter to continue...
oreo27 said:
Not sure if this helps but I've run Imgextractor directly on my system.img with this result:
Code:
Mi-A1-Repository>Imgextractor Mi-A1-Repository\Roms\Fastboot\tissot_images_V.9.5.10.0.ODHMIFA_8.0\images\system.img
ImgExtractor version 1.3.6 <Created by And_PDA (Based on sources ext4_unpacker)>
Extractor for images in EXT2\EXT3\EXT4\YAFFS2\CRAMFS filesystem formats
support SPARSE\SIN\MOTO structure formats
Open image file Mi-A1-Repository\Roms\Fastboot\tissot_images_V.9.5.10.0.ODHMIFA_8.0\images\system.img (size 3221225472 bytes) successfull...
Analize format of file. Please wait...
Found SPARSE FORMAT
Found EXT4 FORMAT
free space in image 188895232 bytes
Extract started. Please wait...
Extract 750 folders and 6306 files successfull
Found 386 symlink files
File stats (uid, gid, permission) save to Mi-A1-Repository\Roms\Fastboot\tissot_images_V.9.5.10.0.ODHMIFA_8.0\images\system__statfile.txt
Extract finish success
Press Enter to continue...
Click to expand...
Click to collapse
Found the error, the img file is of a wierd format, as its named system.img, it actually contains files from the root, so within the system.img the the root of the image is actually the root of the device rather then the root of the system partition, its extremely odd but none the less extremely simple to fix
Issue is already fixed and will be included in dev preview 3, that is expected for public release in a day or so with much more additions
Ricky Divjakovski said:
Found the error, the img file is of a wierd format, as its named system.img, it actually contains files from the root, so within the system.img the the root of the image is actually the root of the device rather then the root of the system partition, its extremely odd but none the less extremely simple to fix
Issue is already fixed and will be included in dev preview 3, that is expected for public release in a day or so with much more additions
Click to expand...
Click to collapse
Yeah. I found it odd that the system.img had a /system directory in it. Awesome! Can't wait
Ricky Divjakovski said:
Could you please PM me with pics of the firmware your selecting or even a link?
Click to expand...
Click to collapse
its on mega.
https://mega.nz/#!dCA2mAYS!-GrKWuuTNODaYEbt3LWiw4LJzxkrz5wI3T94mQ4PU90
it is a android 6 to android 7 full update. its installed, but i am trying to learn cobble together a rom. this img is for a zoomtak upro, i have found today an image for the uplus/vplus. it has much more stuff in it.
thanks
Twisted714 said:
its on mega.
https://mega.nz/#!dCA2mAYS!-GrKWuuTNODaYEbt3LWiw4LJzxkrz5wI3T94mQ4PU90
it is a android 6 to android 7 full update. its installed, but i am trying to learn cobble together a rom. this img is for a zoomtak upro, i have found today an image for the uplus/vplus. it has much more stuff in it.
thanks
Click to expand...
Click to collapse
I will check it when i get home, if its an upgrade package, i cannot ad support for it..

[APK,IMG,DAT,BR] One click decompile/compile - Windows Shell Integration

This tool is a part of ADK software, thread can be found here (For summary read Introduction part below). Read Instructions at the end on how to install this.
Click to expand...
Click to collapse
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
Snapshot
Click to expand...
Click to collapse
Introduction
This Utility adds option to right click decompile, compile options for some extensions (like apk, img, dat, br, file_context.bin, payload.bin) so that you don't have to open any kind of kitchen again and again move files there and select options to unpack. See screenshots above you will get an idea about what is it..
Also it's not a separate tool it is a part of ADK. Read Installation and download instructions from below and check 2nd post for usage instructions.
And yes the main part since ADK kitchen is not completely free it works for only 7 days as a trial after that you will have to use demo version which has certain feature disabled. Not to worry this utility will work fine but there will be a pop-up notifying to buy license.
What is ADK?
Well if I've to say, ADK (Android Development Kit) is a complete Windows based GUI application which allows you to edit Android apk files, ROM zips, boot or recovery images, Android Firmware and also to create TWRP/CWM flashable recovery zips easily. It's like a complete Android Kitchen with lots of mods, patches, scripts, templates, rich text editor, etc. like an IDE. For more info visit official thread here.
Click to expand...
Click to collapse
Features
Well here you go,,,
Unpack/Repack APK (including smali), IMG, DAT, BR files.
Generate Java Source for APK.
View APK Info like App name, Package, permissions, icon, etc.
Import App as dependency for system apk.
Support Android 9.0 ROM.
Supported lists are: System, Vendor img, dat, br and Recovery or Boot images)
Suggest me what to add more.. :laugh:
Click to expand...
Click to collapse
Changelog and Known Issues
Changelog as per release 1.1.0.0 (17th January 2019)
*Added: Option to unpack Payload.bin
*Added: Option to convert file_contexts.bin to file_context
*Added: Support for Android 9.0 images.
*Updated: APK decompiling so as to create project for ADK.
Known Bugs
* Unpack option is not showing for .IMG file (on Win8.1 and lower).
Current Fix:- Open CMD and type "contexts d path-to-img" (without quotes).
Click to expand...
Click to collapse
Downloads & Instructions
To use these feature you must have ADK to be installed. So read steps below (noob friendly) in order to get it. If you want to know what is ADK read Introduction Part above.
Step 1: Install ADK
Grab a latest release of the software from above link.
Step 2: Extract the ZIP and install setup.exe as we normally do.
Do not install the software in C:\Program Files or Program Files (x86) folder.
Step 3: Launch ADK from desktop shortcut and go to Help > Plugins & Patches.
Keep your internet connection ON to do this steps.
Step 4: Search for ADK Context [Script] and install it.
First click on Download option then after click on Install it. Installation will be like normal setup file.
Step 5: Once installed you can close ADK and use the plugin.
Click to expand...
Click to collapse
Reserved
Nice tool keep up the good work!
Sent from my Redmi 4X using Tapatalk
can we then recompile say a vendor img after using this tool to unpack?
Xdevillived666 said:
can we then recompile say a vendor img after using this tool to unpack?
Click to expand...
Click to collapse
Yes why not! Just right click on the unpack folder created by the tool and select Encode APK,IMG,DAT,BR option from there
Tool has been updated. To download it open ADK it will notify you which plug-in needs to be updated!
[email protected] said:
Yes why not! Just right click on the unpack folder created by the tool and select Encode APK,IMG,DAT,BR option from there
Click to expand...
Click to collapse
Can't repack vendor either with ADK or shell.
ADK says cant find context for system/apps probabby its cant find selinux perms in file_contexts as its vendors its should not need that
And with Shell method can't say log are not getting create
Please looks and thanks for your work
Luffy.d said:
Can't repack vendor either with ADK or shell.
ADK says cant find context for system/apps probabby its cant find selinux perms in file_contexts as its vendors its should not need that
And with Shell method can't say log are not getting create
Please looks and thanks for your work
Click to expand...
Click to collapse
Vendor needs file_context especially plat_file_context it maybe missing something. I will look into it soon as currently I'm working on new project. So this might take a little while, but for sure I'll fix this.
[email protected] said:
Vendor needs file_context especially plat_file_context it maybe missing something. I will look into it soon as currently I'm working on new project. So this might take a little while, but for sure I'll fix this.
Click to expand...
Click to collapse
Thank you and no hurry
and here the exact error
error: build_directory_structure: cannot lookup security context for /system/app
Wow nice.
This can decompile framework-res.apk ans systemui.apk without errors anf uknown folders? Means java problem?
Good work, thank you.
Wysłane z mojego SM-G930F przy użyciu Tapatalka
Luffy.d said:
Thank you and no hurry
and here the exact error
error: build_directory_structure: cannot lookup security context for /system/app
Click to expand...
Click to collapse
I'll contact you once I will look up in this issue and fix it.
nalas said:
Wow nice.
This can decompile framework-res.apk ans systemui.apk without errors anf uknown folders? Means java problem?
Good work, thank you.
Wysłane z mojego SM-G930F przy użyciu Tapatalka
Click to expand...
Click to collapse
Yes it will unpack framework-res.apk and system ui. Just make sure when you want to decompile these system apps make sure to check the option 'import as dependencies' to not get any decompiling and compiling error further.
For Java problem I still get no response to issue with the latest Java problem. I think we still have to use lower Java version.
Android pie repacked system_ext.img can't boot.
Werewolf 99 said:
Android pie repacked system_ext.img can't boot.
Click to expand...
Click to collapse
Well I need some more info on this issue a logcat or something else. From your info I deduct following things like!
1. Your ROM might but using sparse image not ext if that's the case convert the image and then flash.(since sparse image omits some empty blocks)
2. I need to know the original image size and new compiled image size (if you have not made any changes then how much difference is present in their size).
Also let me know if you are flashing the new image using sp tool (for mtk devices).
futuretricks
thanks for this
Thanks for Your Share
EnerJon said:
Nice tool keep up the good work!
Sent from my Redmi 4X using Tapatalk
Click to expand...
Click to collapse
Thanks
cant use without a license, script download function is locked.. This must be under "paid software"not here.
guap said:
cant use without a license, script download function is locked.. This must be under "paid software"not here.
Click to expand...
Click to collapse
As discussed with the moderator this is part of ADK which is free to use even after trail period https://www.google.com/amp/s/forum....adk-android-reverse-engineering-t3803044/amp/
So if this is not working try original ADK which works after expiry date
I keep trying to download the script but the file is 0 kb and wont install. Any help?
Arden said:
I keep trying to download the script but the file is 0 kb and wont install. Any help?
Click to expand...
Click to collapse
Check your PM

Categories

Resources