yashsingh1/xdaforums huggingface dataset:
[SuperR Kitchen] fhem:
Thanks for your continued support and great work -- I just tried deodexing N6 mra58k. The results are here. I think most of the errors are due to smali/baksmali but I am more concerned about the apks it says are already deodexed eg. Chrome -- I don't believe they are. If I can do anything to help the effort just ask or pm. Thanks again this is a great project!!!!!
[SuperR Kitchen] DarkHeart Z:
some device filters for mmc devices :)

Here is some new device filters . Though 1 of them are not complete . I will send you updated filters of that specific device .
[SuperR Kitchen] Er. Aditya:
dear dev please add ability to extract csc as well

thats the only thing that i found missing in this amazingly awesome work

thankyou :)
[SuperR Kitchen] :
Having same issue myself. If I try and extract csc img first I get error no system folder and if I extract system img first I don't get the option to extract csc
[SuperR Kitchen] _that:
Is it cut off at some "round" (binary) value? Is it reproducible always at the same point? And what "adb output text"?
[SuperR Kitchen] SuperR.:
Here is a zip that contains boot_good.img and boot_bad.img.

boot_good was created using the following commands:

adb shell su -c "dd if=/dev/block/bootdevice/by-name/boot of=/sdcard/boot_good.img"
adb pull /sdcard/boot_good.img

boot_bad was created with the following command:

adb exec-out su -c "cat /dev/block/bootdevice/by-name/boot" > boot_bad.img

I also tried

adb exec-out su -c "dd if=/dev/block/bootdevice/by-name/boot" > boot_bad.img

and

adb exec-out su -c "dd if=/dev/block/bootdevice/by-name/boot | gzip -c" > boot_bad.gz

with the same result. In the case of piping to gzip, the archive was corrupted and could not be extracted.

I have tried adb versions 1.0.32 and 1.0.36 both 32 and 64-bit, with the same result. If you look at the files with a hex editor, you will see that boot_bad has extra data starting at offset 0x2000000 to the end of file. boot_good extracts without errors, boot_bad gives errors. Same with the system.img.

adb output text meaning the notification it is complete such as records in: records out: etc. I managed to eliminate the text being injected in the binary, but it still adds the extra data for some reason.

edit: forgot to mention I tried all of the above commands with and without "quotes". Same result.
[SuperR Kitchen] _that:
The extra data doesn't start at 0x2000000, the first difference is already at offset 0x2c - 0x0a is translated to 0x0d 0x0a. This is something that I'd expect with "adb shell" because of the pseudo tty end-of-line translation, but "adb exec-out" should not do that. Apparently you have some setup where exec-out doesn't work correctly, maybe the adbd on the device is too old. Good to know that it's not reliable with all devices.

That text comes from dd, not from adb.
[SuperR Kitchen] bigrammy:
[MENTION=4878287]_that[/MENTION]
[MENTION=5787964]SuperR.[/MENTION]

Just for info:

I have had some system.img's in the past that would not mount no matter what I did so I would flash them using in my case SPFlashTool (Mediatek) then dd the /system to sdcard and pull it to the PC then it would mount without issues and all without booting to system :eek:

Maybe those bad images are created using the

adb exec-out su -c "dd if=/dev/block/bootdevice/by-name/system" > system.img

example.

Very Strange :confused:
[SuperR Kitchen] Ale95:
[MENTION=5787964]SuperR.[/MENTION] Bro your kitchen can compile a system folder to do a flasheable zip in dat or img format?

I'm trying to create one but only show me a flasheable with system folder, etc

And if can do it, can explain me where i can found this option?
[SuperR Kitchen] SuperR.:
I don't think adbd is too old as it is Nexus 5X running Nougat. I hope it is not the opposite and it is too new?

Here is some adb text that gets added to the img "adb server is out of date. killing..." All kinds of interesting stuff in there.

Anyway, adb exec-out is a mystery. I may have figured out a way around this that should work on all devices that have base64 but it still needs a lot of testing.

edit: This works most of the time:

adb shell su -c "cat /dev/block/bootdevice/by-name/boot | base64" 2>/dev/null > boot64.img
base64 -d boot64.img > boot.img

When it does not work, base64 complains "base64: invalid input". I have not yet figured out why it does not always work with the same command, device, pc, and adb version.

Choose sparse_dat perm type for flashable dat zip, and choose raw_img perm type for flashable img zip. Then just build full rom zip from the build menu :)
[SuperR Kitchen] lonegolfs15:
hi, without any modifications, and still setup wizard force close, any ideas?
[SuperR Kitchen] obersteiner86:
hi

Hi my name is master861 on gitlap i donate 15 dollar is this working on samsung tab s sm-t800 wifi
[SuperR Kitchen] tomirodriguez:
Im trying to download the plugins but all the links end in a 404 error, "The page you're looking for could not be found."

Am i doing something wrong? Cause it seems that no one is having problems with this

Thanks !
[SuperR Kitchen] obersteiner86:
The plugins only works for the 2.1 kitchen not the 1.x version.

Try this link http://xdaforums.com/showthread.php?t=1461712
[SuperR Kitchen] brainvision:
hi guys,

I have issues while zipaligning my APKs after deidex: the process fails and it tells me to check the zip.log, but her there's no useful log about that; the last log I have is from deodex process.. what could I do? I choose Build custom zip, option 2, hope it could be someho useful..

thanks..

EDIT I'll repost my machine info because I'm sure no one remember, naturally :D

Debian AMD64

SuperRs 1.1.1.2

device Cube iWork 10 i15-TCL

working on extracted images obtained with dd

Android 5.1
[SuperR Kitchen] SuperR.:
I have no idea. As I said before, 7.1.1 is not fully supported yet. It will be at some point.

Added, thanks :) You will have to try it, but it will most likely work.

I am guessing you are having trouble zipping the rom rather than zipalign. Please send firmware link so I can have a look.
[SuperR Kitchen] obersteiner86:
Hi thx for adding me i donwload the orginal zip for my sm-t800 i make some modifications but now it runs only to the select language ther i cant press anything i send this from my windows pc
[SuperR Kitchen] brainvision:
not sure, because I'm able to zip a full zip flashable rom but not a zip with only framework, priv-app, app, priv-app and lib (as per option 2 from Custom zip).

Also I saw weird errors while deodexing, something like FileExplorer odex file not found (this kind of error in the terminal while processing) and others in the log about smali, oax and blah blah (I'm totally newbie at this). Last but not least, the produced update-script always brings to ERROR 255 because this tablet has a particular mounting place for system, which is /android_system. But this last issue I should be able to solve because I have similar update files from other guys.

Ok, I have the system partition image (sparse one) uploaded here: https://mega.nz/#!YBdw1bIT!GibOWLBNyXAhwEiEdXIV3JKKdMM9gXzLIYvppKn0Bgs - while boot, official recovery here: https://mega.nz/#!hZcCXJjL!9Tc9VknwOOf5AgqjDTNFwEjrvJGUvo_h2JYwaUV0Wdk

I'll let you the MD5 of the extracted images

1-bootloader.img	2f282b84e7e608d5852449ed940bfc51
2-android bootloader.img	e1006267570a3398f4b95bb7d7e75d80
3-boot.img	74d4a09ec3ababc4d3d3d97f8fe00c6e
4-recovery.img	def58fe78f3820da9baf6b12efdc085a
7-system.img	1812be775e55a25903cbf9541570b187

I'm a bit lost about set_perm stuff and a few other things, so I'll need to try all the Lollipop ones until I found one working :D

Do you suggest to use the modified boot.img and the TWRP custom recovery to deodex or should I use the stock original ones?

Thanks a lot for your kind help, very appreciated! :svetius:
[SuperR Kitchen] bcrichster:
Set_perms is archaic and won't function for SElinux stuff.

Sent from CM12.1 *N9515*
[SuperR Kitchen] SuperR.:
v2.1.2.3 (Donate version)

Changes:

Added option to choose temporary device storage path for adb pull img files, or enter the path manually.

Added the latest adb v1.0.36 for 64-bit Linux OS.

Fixed vendor.img not being extracted from device on N roms.

Updated L deodex algorithm to match M oat2dex.

Added option to choose oat2dex version when deodexing L roms.

Fixed custom zip failing when choosing to zipalign before building.

v1.1.1.3 (Standard version)

Changes:

Added option to choose temporary device storage path for adb pull img files, or enter the path manually.

Added the latest adb v1.0.36 for 64-bit Linux OS.

Fixed vendor.img not being extracted from device on N roms.

Updated L deodex algorithm to match M oat2dex.

Added option to choose oat2dex version when deodexing L roms.

Fixed custom zip failing when choosing to zipalign before building.

Please read post #4 for details of what I need to help you.

Weird deodexing errors fixed, but you will have some failures with the Lollipop firmware you provided. I tried with both official and latest commit oat2dex. You may need to try another tool for deodexing.

Custom zip is now working.

You don't need recovery.img for building a rom in most cases. It is up to you which boot.img you use. You are the rom dev :)

Use set_metadata. It is the most stable in my opinion.

Since your device is x86, you will need to find an update-binary for x86. The one included in the kitchen will not work in your device and is likely the cause of your flashing issues.

The kitchen can get your mmcblk devices from your recovery and it might fix the wrong partition in the updater-script issue. Delete your device directory from /kitchen/tools/devices. Then extract your images again. When it asks about partition info, choose get mmc from recovery.

I see you are using sparse_dat. Many people have issues with it. I suggest set_metadata. set_metadata does not require partition size so it will sort that issue out as well.
[SuperR Kitchen] brainvision:
thanks for your jelp and your precious hints!

Unfortunately I tried a bunch of others tools and no one worked with x86 and compressed odex files :crying:

So it seems I have to achieve that with SuperRs :D

I updated and deodexed with 0.86 oat2dex; at the end of the process it warned me about a few app/framework resources not deodexed

FileManager
LatinIME
framework.jar
services.jar
telephony.jar
GmsCore
Launcher2

I think I could solve the issues for the apps by installing the GApps (back in the time of my Gingerbread flashing gapps after the rom gives no error because it used directly the google keyboard so no crash for the missing Latin IME, but I could be wrong; FileManager, GmsCore and Launcher2 no problem at all)

What scares me are the jar files...

1- the framework.jar file is bigger when deodexed so it seems the process worked

2- services.jar is exactly the same BUT SuperRs deleted the odex file from the x86 folder

3 - telephony.jar does not exist, I only have a telephony-common.jar (seems correctly deodexed)

The strangest btw is that an xda user have this same tablet (there are just a few differences like name, and Type C instead of USB 3) and I told me using SuperRs to succefully deodex the rom and repack it! :(
[SuperR Kitchen] Pyr0ball:
The script I copied above was from my current (4th) attempt using alternate perm methods. I have been using set_metadata in all previous instances.

I did try pulling and building using only the recovery, however one of the issues I was running into with the mmc problem was the script hanging, then failing on detecting the partition size while booted into TWRP. Unfortunately nothing seems to be outputting to the log to indicate why though. Is there a verbose option I can enable perchance?

Also FYI, running the updater from within the script seems to not work for 1.1.1.3:

------------------------------------------------------
SuperR's Kitchen
by SuperR
------------------------------------------------------

SuperR's Kitchen has been updated

Press ENTER to continue

------------------------------------------------------
SuperR's Kitchen
by SuperR
------------------------------------------------------

CURRENT PROJECT: Alcatel_Pixi_7_9006w_Debloat
ANDROID VERSION: 5.0.2

Main Menu

1) Create new project
2) Choose a different project
3) Delete a project
4) Extract for new ROM
5) Check for updates (CURRENT: v1.1.1.2)
6) Misc Tools
7) Boot/Recovery Tools
8) ROM Tools Menu
q = Quit

Make your selection:

Edit: I just got developer status for Androidfilehost, so I'm gonna get my stuff uploaded there including the roms I built.

Here's the folder with everything. I'm still uploading stuff so check back if you don't find what you're after

I also tried importing the rom to Android-Kitchen and building a zip with that so I'll push that one up there too.
[SuperR Kitchen] deadlock9x:
Hi [MENTION=718594]SuperR[/MENTION], thank you for your great tool!

I'm try to use your tool to extract IMG firmware and boot.img in it. But I don't know why it can not unpack this boot.img, please help me to check them:

boot.img:

https://drive.google.com/file/d/0B-lxpOVHDxRibjFUSk91U0JaOWc/view?usp=sharing

build.prop:

https://drive.google.com/file/d/0B-lxpOVHDxRiZnNfWFZqdUdGUnc/view?usp=sharing

Thank you very much!
[SuperR Kitchen] SuperR.:
I wonder if the other user with the other device is running a different version of Android, because the firmware you provided will certainly have issues when you flash it. Errors on services.jar and framework.jar are not good.

You can clone the kitchen again to get the update. Did you modify any files in the kitchen besides the project directories? This is the second time I have heard about this so I will do some testing to see if I can figure out why some people have trouble updating.

If you send your recovery.img I will check to see why you are having trouble with the mmc detection from your recovery.img.

This boot.img does not seem to be a valid boot.img. There is no Android boot magic. If it is a valid boot.img, I have no idea how to unpack it. I tried with this kitchen, Android Image Kitchen, and Carliv Image Kitchen.

edit: I think this is just the kernel, not a boot.img
[SuperR Kitchen] brainvision:
nope, exactly same android version, mine is just with a kernel update 2 months later, that's the only difference!

I'm trying to reach him to see if he can tell me more about what he did, but last time I hear him he told he was really busy, so I don't expect too much :(

For sure he deodexed on May, do you think I could try with older versions of SuperRs or do you think it's useless?

don't know what to do grrrrrrr :rolleyes:
[SuperR Kitchen] deadlock9x:
Hi, this is boot.img file. I also try with more tool to unpack it but not success. I got it from this ROM:

https://mega.nz/#!Ulkw2SAZ!WleVN3NkOtBtghZc3nXijNC5hTRu-H5_kY7DuuxAoRI

After unpack this ROM, I have:

- boot.img

https://drive.google.com/file/d/0B1SrXp9MNAWvQ3lmdlI3ZEJPdEU/view?usp=sharing

- kernel.img

https://drive.google.com/file/d/0B1SrXp9MNAWvWjM5aTFrbGM5am8/view?usp=sharing

- misc.img

https://drive.google.com/file/d/0B1SrXp9MNAWvWDdrR2F5VFcwUkk/view?usp=sharing

- recovery.img

https://drive.google.com/file/d/0B1SrXp9MNAWvQUtaaVpzRW16Z1E/view?usp=sharing

- resource.img

https://drive.google.com/file/d/0B1SrXp9MNAWvNC1jcHJlX3E1TWc/view?usp=sharing

- system.img

https://drive.google.com/file/d/0B1SrXp9MNAWvVzZwR0lyUjhaWUU/view?usp=sharing

- trust.img

https://drive.google.com/file/d/0B1SrXp9MNAWvYVlIU1RkSUxMRHM/view?usp=sharing

- uboot.img

https://drive.google.com/file/d/0B1SrXp9MNAWvbldUcHRXbXZRdXc/view?usp=sharing
[SuperR Kitchen] bigrammy:
Hi,

PRFCreator uses by-uuid which may work for troublesome partition id's. It does it by running a small shell script. Open Source.
[SuperR Kitchen] Pyr0ball:
Derp, I forgot that I'd already made that change to the script for getting the images off my device. I'll bet git is having a merge conflict. I'll checkout master and see if that takes care of it.

All the files I've been working with are HERE including recoveries, stock images, nandroid, and a few other goodies
[SuperR Kitchen] obersteiner86:
How i can ad are custom recvory img file like twrp to my modet file
[SuperR Kitchen] SuperR.:
Here is a link to v.1.0.8.0 from June 12th. There were no deodex changes since the beginning of May so it should be the same as what he was using.

I don't understand the question.

I will take a look as soon as I get a chance :)

I don't understand the question.
[SuperR Kitchen] Pyr0ball:
Much appreciated! Very nice to see a dev as active and responsive as you've been. I'm off to donate :)

Edit: I'm trying to do another pull from CWM recovery instead of TWRP. We'll see if that yields any different results

Edit Edit: Apparently what I found and was labeled as CWM recovery for this device is simply the stock recovery with touch added. Off to learn about porting recoveries...
[SuperR Kitchen] bcrichster:
I think he wants to flash a recovery in/with the ROM zip..?? Kinda like how an ODIN.tar does when flashing the firmwares

Sent from CM12.1 *N9515*
[SuperR Kitchen] obersteiner86:
sorry i dont see your replay the site chrashed .

Yes like bcrichster says that is what i whant make.

To my bug:

My model:sm-t800 wifi

android:6.0.1

Kitchen:2.1.2.3

stock firmware used

set_metadata

I removed knox at super su and some apps with aroma.

My device boots up to the change language but ther i can change nothing if i press on the drop down list for the language nothing happens.
[SuperR Kitchen] Guizão BR:
Please, add my device ;)
[SuperR Kitchen] deadlock9x:
Hi, my mean that is my ROM, and I get boot.img from it, but when I'm using your tool to unpack, it can not and I don't know the reason?
[SuperR Kitchen] jaylence:
It's been a while since I visited this awesome thread.

Last night I received an OTA update containing SMR for the month of october.

After installing, I pulled out boot.img and system.img using adb.

Load them inside my new project directory (v.1.1.3).

When I reached the part "how to get partition info", choosing the first option (thru boot.img), i got this message.

..........................

Detecting by-name from boot.img

cpio: .subackup/0000_file_contexts: Cannot open: Permission denied

cpio: .subackup/0001_fstab.goldfish: Cannot open: Permission denied

cpio: .subackup/0002_fstab_ranchu: Cannot open: Permission denied

cpio: .subackup/0003_fstab_samsungexynos7420: Cannot open: Permission denied

cpio: .fstab_samsungexynos7420.fwup: Cannot open: Permission denied

cpio: .subackup/0005_init.environ.rc: Cannot open: Permission denied

cpio: .subackup/0006_init.rc: Cannot open: Permission denied

cpio: .subackup/0007_sepolicy: Cannot open: Permission denied

cpio: .subackup/index: Cannot open: Permission denied

20822 blocks

find: './.subackup': Permission denied

.....................

I was still able to build my ROM (Deodexed).

Installed and booted successful.

I'm having one trouble though, when I ran adb devices, it says "anuthorized".

I'm currently modding some of the system apps and using adb is a lot easier in rebooting to recovery mode than doing the usual 3 button-combo.

I didn't encounter any error while decompiling boot.img with option 7 (boot/recovery tools)
[SuperR Kitchen] SuperR.:
Thanks for the donation. Please send me your gitlab username so I can add you to the repo. Sometimes the email address you used to sign up for gitlab is also helpful. Feel free to PM :)

The kitchen does not support this so far. I am not sure (other than Sony devices) why you would want to do this. Seems dangerous to replace Android and recovery in one flash. If anything goes wrong you could have a brick on your hands.

I will get it added.

I still have no idea how to deal with that boot.img. I will not know unless someone tells me since I don't have your device and have never seen a boot.img like this.

No worries about the errors you show above. That step unpacks the boot.img just to get the by-name info. The boot.img is untouched at that point, just extracted. I will see about suppressing the error during that step so you don't see it since it is useless anyway.

I have no idea about the adb issue. If you are agreeing on your device to allow adb from your pc it should work. There is authentication for adb starting in Marshmallow I believe. Once you agree it will not ask again when using that pc.
[SuperR Kitchen] deadlock9x:
Thank you for your reply :) It's a Rockchip device and I'm still can not find any tool to unpack it. I see a topic here:

http://www.gizfun.com/content/unpack-and-pack-rockchip-bootimg-image-%EF%BC%88rk3066rk3188

But I'm not success in this step:

gunzip boot.img.gz

I don't know why, it talk that "gzip: boot.img.gz: not in gzip format"

Anyway, I will try more, thank you very much!
[SuperR Kitchen] brainvision:
it should be, if the file is correct and no other errors

gunzip -d boot.img.gz

from the man of gunzip in fact

-d --decompress --uncompress
Decompress.

EDIT: so, still stuck on those ******* 3 jarr that makes me mad: framework.jar, services.jar and telephony.jar! I'm trying now older version of superrs, 1.0.6.3 and .4 because I know a guy deodexed this ROM between April/May; do you think it could make any difference to have the donate version?

Also, what if I deodex and zipalign everything I can and leave the rest odexed? What are those jar files needed for? I was not able to find a lot of useful references, but maybe I don't know where to search for. But - for example - if in future I would like to change a few graphic stuff to this ROM, is the framework.jar needed or I will just need the framework.apk?

As always, a big thank you! ;)
[SuperR Kitchen] obersteiner86:
Hi same bug as before on my device in twrp after the zip installtion it tells me no os installed how i but the system.img into my custom rom are file called system_new.img is createt but it dont gets compressed into the zip.I know that i can put somthing into the zip ariche with out extract it
[SuperR Kitchen] SuperR.:
The donate version uses the same deodex method as the standard, so you will have the same errors in both versions. In fact, I deodexed your rom in the donate version and got the exact same errors. framework.jar and services.jar are part of the core OS and your rom will not function properly without them. The 2 odexed apk's on the other hand might work if the rest of the rom is deodexed.

Use raw_img perm type if you want to create a flashable zip that contains system.img. When you choose to build full rom.zip, the kitchen will take care of the rest.
[SuperR Kitchen] brainvision:
sorry, I did not explain it the right way: I mean, what if I deodex everything I could and leave those 3 jar just as they were? I would put the original odex file in the x86 folder..

Will I be able to make some basic mods on SysteUI and Settings then?
[SuperR Kitchen] SuperR.:
Updated apktools plugin:

Changes:

Use aapt instead of 7zip to compress apk files

Updated apktool.jar to 2.2.2-2a3d40-SNAPSHOT

It's possible. You would have to try it and see :)
[SuperR Kitchen] jaylence:
So I tried re-building my rom using the latest build containing security patch for the month of october.

Has anyone experienced usb debugging not working?

Can't perform any anything via adb 'coz of "device unauthozed" error.

Something is restricting adb to connect to my phone.

I used to received a popup message asking for authorization. But now, I don't see that option anymore.

Also in developer options, the "revoke usb authorization" menu is gone.

I compared my older builds with current one, and found 2 differences:

1. In system/priv-app there's a new app:

--- ASKSManager.apk

2. In build.prop

---- security.ASKS.policy_version=000000

Googled several times but can't find anything about this new app.

Phone Model: Galaxy S6 Edge (G925F)

Android version: 6.0.1 Marshmallow

Security Patch: October
[SuperR Kitchen] brainvision:
Try to use adb as root superuser via sudo or directly su. You could also try to edit your udev rules (google adb permissione udev) - if possibile prefer udev mod

Inviato dal mio LG-V400 utilizzando Tapatalk
[SuperR Kitchen] minz1:
Hey SuperR, you should add a feature to the debloater, where you have just a whitelist of apps to keep, and everything else gets removed.