yashsingh1/xdaforums huggingface dataset:
[Android Software Development] bovirus:
@ laura almeida

I follow your instruction but didn't work for me.

I'm using latest version of JDK (1..7.0.80)

The error is always teh same (gradle script didn't find a subfolder).

Could please make a zip of your apktool folder and upload it on some host?

I will make some test!
[Android Software Development] headsauce:
Huawei Ascend g526 framework-res cannot b installed by apktool 2.0.2?

Im using Huawei Ascend G526 JB4.1.2

api lvl 16, xhpdi 540x960 MSM8930 chip SOC dual core 1.2 Ghz

And this one I install my framework-res.apk to decompile framework-res.apk itself? Using apktool 2.0.2... anyway i have used. apktool 1.5.2, 2.0.0b7, 2.0.1 same result...

This is the error it gaved me... What do i have to do?

I have read apktool builds are different than the one huawei qualifiers is using...

How cud i get those qualifiers and what to use..., what shud i do so that i cud have the apktool 2.0.2 to install framework-res and decompile it? plz help..

Exception in thread "main" brut.androlib.AndrolibException: java.io.FileNotFound

Exception: framwork-res.apk (The system cannot find the file specified)

at brut.androlib.res.AndrolibResources.installFramework(AndrolibResource

s.java:619)

at brut.androlib.res.AndrolibResources.installFramework(AndrolibResource

s.java:581)

at brut.androlib.Androlib.installFramework(Androlib.java:676)

at brut.apktool.Main.cmdInstallFramework(Main.java:240)

at brut.apktool.Main.main(Main.java:87)

Caused by: java.io.FileNotFoundException: framwork-res.apk (The system cannot fi

nd the file specified)

at java.util.zip.ZipFile.open(Native Method)

at java.util.zip.ZipFile.<init>(Unknown Source)

at java.util.zip.ZipFile.<init>(Unknown Source)

at java.util.zip.ZipFile.<init>(Unknown Source)

at brut.androlib.res.AndrolibResources.installFramework(AndrolibResource

s.java:589)

... 4 more

I decompile and my make mods to my apk's just using another device framework-res i found inside xda-developer but now i need my own framework-res to b decompiled to make my mod... Here is my framework-res and framework-res-hwext... and the framework that im using just to decompile other apks
[Android Software Development] exodius48:
I don't know why, but apktool can't fully decompile this app: eProxy

I got many errors, also smali & baksmali can't fully decompile it too.

Anyone can explain me?
[Android Software Development] laura almeida:
You should know by now, reporting "error" doesn't mean a thing unless you provide its log !!!
[Android Software Development] exodius48:
Yes i know about it, but CMD on windows can't read all logs, there are too many error logs on it.

Some of them : http://pastebin.com/npjFnc2i

I use command 'apktool d eProxy.apk'

Try it yourself if you want, here is the apk file : http://rghost.net/7NqcDYfJH
[Android Software Development] Kiray1982:
You Candy increase the amount of lines shown in cmd. Right Click the window Header and change in settings.
[Android Software Development] exodius48:
I think error code is same

Error occurred while disassembling class Lorg.jasypt.util.a; - skipping class
org.jf.util.ExceptionWithContext: The last instruction in the method is truncate
d
[Android Software Development] superdragonpt:
Yeap ^^ This

I know im late (better late than never...)

ontopic:

You guys need a special apktool to properly decompile MIUI (and some Flyme releases)

Btw: Be safe if your using MIUI ... Just saying ...

cheers
[Android Software Development] TrafalgarD:
special apktool ?????
[Android Software Development] zelendel:
Yes you need an apktool that is built to work with the changes that they pointlessly make for miui. Don't ask why they do it. You will get many answers and almost all of them are guesses
[Android Software Development] xdadroidabc:
Sir I am unable to install framework with latest 2.0.2 on Marshamallow

apktool if framework-res.apk gives following error

Exception in thread "main" brut.androlib.AndrolibException: Could not decode ars
c file
at brut.androlib.res.decoder.ARSCDecoder.decode(ARSCDecoder.java:52)
at brut.androlib.res.decoder.ARSCDecoder.decode(ARSCDecoder.java:39)
at brut.androlib.res.AndrolibResources.installFramework(AndrolibResource
s.java:599)
at brut.androlib.res.AndrolibResources.installFramework(AndrolibResource
s.java:581)
at brut.androlib.Androlib.installFramework(Androlib.java:676)
at brut.apktool.Main.cmdInstallFramework(Main.java:240)
at brut.apktool.Main.main(Main.java:87)
Caused by: java.io.IOException: Expected: 0x00000008, got: 0x00000000
at brut.util.ExtDataInput.skipCheckShort(ExtDataInput.java:56)
at brut.androlib.res.decoder.ARSCDecoder.readValue(ARSCDecoder.java:254)

at brut.androlib.res.decoder.ARSCDecoder.readEntry(ARSCDecoder.java:203)

at brut.androlib.res.decoder.ARSCDecoder.readConfig(ARSCDecoder.java:191
)
at brut.androlib.res.decoder.ARSCDecoder.readType(ARSCDecoder.java:159)
at brut.androlib.res.decoder.ARSCDecoder.readPackage(ARSCDecoder.java:11
6)
at brut.androlib.res.decoder.ARSCDecoder.readTable(ARSCDecoder.java:78)
at brut.androlib.res.decoder.ARSCDecoder.decode(ARSCDecoder.java:47)
... 6 more

java version is latest - java version "1.8.0_66"
[Android Software Development] Russell.Eclair:
Framework-res.apk error eventhough nothing changes made (Sony Xperia)

Okay, here we go... I have successfully edit systemUI.apk without any single problem but different story when editting framework-res.apk.

Before I decompile "framework-res.apk" I install "SEMCGeneric.apk" as 1.apk and "framework-res.apk" as 2.apk.

When I decompile "framework-res.apk", I got no problem at all. At first I am trying to change XML inside it, then decompile it and signing it. I follow the procedure as I did with "systemUI.apk". But my phone got bootloop. Then after my phone recover from bootloop, I try to edit nothing, just decompile and recompile, signing the apk. My phone got another bootloop.

The only warning I got is, when I try to recompile "framework-res.apk", APKTool show something like "could not find sources" and "string 'day_of_week_long_tuesday' has no default translation in ..." then it continues to build the apk.

So what is wrong?

- My phone: Sony Xperia T2 Ultra Dual (D5322)

- ROM: Stock ROM Android Lollipop 5.1.1
[Android Software Development] djdarkknight96:
Do not sign system files. Use apktool b -c xxx.apk to keep stock manifest and signature...then place it on system....

Or

This is what I do without ever having an issue...I didn't cause....Lol

Use the build folder to place only the files you edited to an untouched apk...Use 7zip to drag and drop to open apk. Then just place it to system or flash.

Hope that helps!

DJ
[Android Software Development] :
I had exactly the same issue but switching back to apktool 2.00 worked fine
[Android Software Development] TrafalgarD:
when I dc my systemui, apktool say brut -_- but dc any app working fine
[Android Software Development] Er. Aditya:
this is not going to help !!
[Android Software Development] TrafalgarD:
yeah I know
[Android Software Development] Russell.Eclair:
apktool b -c xxx.apk ==> WORKING, I think what cause bootloop isn't the error / warning it shows while recompiling.

And about the error,

After invastigate it myself for days, since google doesn't give a clue. I figure (assume) that the problem produced by language which is written in the string . The error "has no translation" or such is pointing to a string which has "%" in it's string

One of several warning while rebuild the apk

...

warning: string 'abbrev_month' has no default translation

...

Then I search the string from files /res/ using notepad++

from strings.xml

Line 2006: <string name="abbrev_month">%b.</string>

from public.xml

Line 5633: <public type="string" name="abbrev_month" id="0x010407f8" />

I guess that, the machine COULD NOT recompile strings with percent or non-english language

Please fix. Thank you
[Android Software Development] djdarkknight96:
No no those are warnings not errors, I see them in a ton of apps on build even Google apps. Nothing to do with Apktool.
[Android Software Development] Russell.Eclair:
Okay bro, I think soo, btw, "java -jar apktool.jar b -c framework-res.apk" is working like miracle for one who occur bootloop.

Maybe it is out of the topic I am changing the value of XML (for multiuser support in GUI), I see from google docs that I just need to change the value multiuser configuration in bools.xml and intergers.xml but it is not working. However that command above is working to fix bootloop, thank you brow. Big thanks to your post
[Android Software Development] Tulsadiver:
I'm a noob at this. I'm trying to deodex the new Nexus 5x Marshmallow oat systemui.odex file. I'm using the baksmali 2.1.0 and smali 2.1.0 which is supposed to support this.

java -jar baksmali.jar -a 23 -x SystemUI.odex -d framework -o SystemUI

I am getting the error

Exception in thread "main" org.jf.dexlib2.dexbacked.Oatfile$invalidOatFileException: Oat file has no symbol table

at org.jf.dexlib2.debacked.Oatfile.get symbol table(oatfile.java.286)

at org.jf.dexlib.debacked.Oatfile.<init>(Oatfile.java:76)

at org.jf.dexlib2.debacked.Oatfile.fromInputStream(oatfile. java124)

at org.jf.dexlib2.DexfileFactory.loadDexfile(DexFileFactory.java 140)

at org.jf.dexlib2DexfileFactory.loadDexFile(DexFileFactory.java:78)

at org.jf.baksmali.main.main(main.java:266)

I'm a real noob but I've been decompiling and recompiling using apktool for quite some time now with no problems. I'd really like to get this Nexus deodexed so I can get to those smali files. Any help would be appreciated, especially if in layman terms so I can understand.
[Android Software Development] Pain-N-Panic:
I tried to do the same thing you are doing when lollipop first launched. I made countless threads and posts asking and no one could really give me the answer. Just never got it to work. Bump for mere curiosity.
[Android Software Development] iBotPeaches:
This error means you have a 64bit OAT file, which in 2.1.0 isn't supported. JesusFreke patched this (https://github.com/JesusFreke/smali/commit/b8e255f3896b39f649178923ada7523782c62bcd) but that won't be available until 2.1.1. Or you can build your own smali binary and use that.
[Android Software Development] Tulsadiver:
Thank you.
[Android Software Development] ROBERT CM:
Great Work

Thanks for this important tool :D
[Android Software Development] - shifu -:
9 patch files corrupted (lollipop)

hi all,

i need to make some mods in framework-res.apk (lollipop 5.1.1 note 3 neo). i've decompiled with NO ERRORS in log and modded a single xml (bool.xml) but when i try to recompile i give errors with almost all 9 patch files (malformed). Generally just fix the first one and all should be fine, but this is not the case. Looking into the res folders i've noticied that almost all .9.png files are REALLY malformed and corrupted. I've searched alot in the forum and tried with different version of apktool with no result.

The tool works perfectly with KK version.

Any idea?

here is a screenshot
[Android Software Development] xonich:
decompile error

Hello,

In order to use the LBE_Security app which is in Chinese,

I decompile and recompile in order to translate it into french.

Until yesterday, there was no problem.

But with the last version, it fails with this error message:

I: Using Apktool 2.0.2 on LBE_Security_Rel_6.1.2215_A1.apk

I: Loading resource table...

Exception in thread "main" brut.androlib.AndrolibException: Multiple res specs: attr/?

at brut.androlib.res.data.ResType.addResSpec(ResType.java:62)

at brut.androlib.res.decoder.ARSCDecoder.readEntry(ARSCDecoder.java:219)

at brut.androlib.res.decoder.ARSCDecoder.readConfig(ARSCDecoder.java:191)

at brut.androlib.res.decoder.ARSCDecoder.readType(ARSCDecoder.java:159)

at brut.androlib.res.decoder.ARSCDecoder.readPackage(ARSCDecoder.java:116)

at brut.androlib.res.decoder.ARSCDecoder.readTable(ARSCDecoder.java:78)

at brut.androlib.res.decoder.ARSCDecoder.decode(ARSCDecoder.java:47)

at brut.androlib.res.AndrolibResources.getResPackagesFromApk(AndrolibResources.java:544)

at brut.androlib.res.AndrolibResources.loadMainPkg(AndrolibResources.java:63)

at brut.androlib.res.AndrolibResources.getResTable(AndrolibResources.java:55)

at brut.androlib.Androlib.getResTable(Androlib.java:65)

at brut.androlib.ApkDecoder.setTargetSdkVersion(ApkDecoder.java:197)

at brut.androlib.ApkDecoder.decode(ApkDecoder.java:96)

at brut.apktool.Main.cmdDecode(Main.java:165)

at brut.apktool.Main.main(Main.java:81)

Can someone help me find a solution to this problem?

The app download link:

h t t p : / / go.lbesec.com/r2?id=home_sec

or

h t t p : / / cdn1.lbesec.com/products/release/201512/LBESecV6_App-A1-release-v6.1.2215.apk

Thanks
[Android Software Development] iBotPeaches:
Yes it seems 9patch had some changes. Need to create a decoder that works with old/new 9 patches. Commit of interest - https://github.com/iBotPeaches/plat...mmit/6381dd4ff212a95be30d2b445d40ff419ab076b4

Yes another known bug here - https://github.com/iBotPeaches/Apktool/issues/894
[Android Software Development] bdorr1105:
So there I went, took hours to get this damn computer to stop throwing every error in the book at compiling this into the latest dirty jar, however, after the .git folder not existing, cloning the git being a pain, file destinations being too large, missing Java even tho it was installed and fixing the variables, I managed to compile.

I tried to decompile a cm 13 6.0.1 Rom to no avail....See the code below

Decompiling "SystemUI.apk",
in workarea "_WorkArea1", using "apktool_2.0.2-dirty2.jar"
With Debug Info Disabled

With Tickle My Android 12.0.0.
(tinyurl.com\ticklemyandroid)

----------------

I: Using Apktool 2.0.3-0649d5-SNAPSHOT on SystemUI.apk
I: Loading resource table...
I: Decoding AndroidManifest.xml with resources...
I: Loading resource table from file: C:\Users\150CPT_Admin\apktool\framework\1.apk
I: Regular manifest package...
I: Decoding file-resources...
W: Could not decode attr value, using undecoded value instead: ns=android, name=background, value=0x01080753
W: Could not decode attr value, using undecoded value instead: ns=android, name=background, value=0x01080753
I: Decoding values */* XMLs...
Exception in thread "main" brut.androlib.err.UndefinedResObject: resource spec: 0x01080753
at brut.androlib.res.data.ResPackage.getResSpec(ResPackage.java:59)
at brut.androlib.res.data.ResTable.getResSpec(ResTable.java:65)
at brut.androlib.res.data.ResTable.getResSpec(ResTable.java:61)
at brut.androlib.res.data.value.ResReferenceValue.getReferent(ResReferenceValue.java:57)
at brut.androlib.res.data.value.ResReferenceValue.encodeAsResXml(ResReferenceValue.java:47)
at brut.androlib.res.data.value.ResScalarValue.encodeAsResXmlAttr(ResScalarValue.java:46)
at brut.androlib.res.decoder.ResAttrDecoder.decode(ResAttrDecoder.java:47)
at brut.androlib.res.decoder.AXmlResourceParser.getAttributeValue(AXmlResourceParser.java:369)
at org.xmlpull.v1.wrapper.classic.XmlPullParserDelegate.getAttributeValue(XmlPullParserDelegate.java:69)
at org.xmlpull.v1.wrapper.classic.StaticXmlSerializerWrapper.writeStartTag(StaticXmlSerializerWrapper.java:267)
at org.xmlpull.v1.wrapper.classic.StaticXmlSerializerWrapper.event(StaticXmlSerializerWrapper.java:211)
at brut.androlib.res.decoder.XmlPullStreamDecoder$1.event(XmlPullStreamDecoder.java:83)
at brut.androlib.res.decoder.XmlPullStreamDecoder.decode(XmlPullStreamDecoder.java:141)
at brut.androlib.res.decoder.ResStreamDecoderContainer.decode(ResStreamDecoderContainer.java:33)
at brut.androlib.res.decoder.ResFileDecoder.decode(ResFileDecoder.java:120)
at brut.androlib.res.decoder.ResFileDecoder.decode(ResFileDecoder.java:105)
at brut.androlib.res.AndrolibResources.decode(AndrolibResources.java:247)
at brut.androlib.Androlib.decodeResourcesFull(Androlib.java:136)
at brut.androlib.ApkDecoder.decode(ApkDecoder.java:102)
at brut.apktool.Main.cmdDecode(Main.java:165)
at brut.apktool.Main.main(Main.java:81)

----------------

Decompile Not Successful!
[Android Software Development] TheRoyalSeeker:
I have Resurrection remix 5.5.9 rom for falcon but whenever i try to decompile or install its framework-res.apk i get this error...

Please help [MENTION=3924617]iBotPeaches[/MENTION]!!!

I have windows 10 64bit and android 5.1.1.
[Android Software Development] jabr1G:
Same problem with me,,why when i install frame work and decompile systemUI from RR,,have error brut,,but sukses with apk from cm 12.1,,i use apktool v 2.0.2,,
[Android Software Development] - shifu -:
ok thanks..

I really need to enable native 3dot menu due to some app compatibility... is there a way to modify "bool.xml" only, in "value" folder, without get into this issue?
[Android Software Development] Sun Shower:
I have a trouble like this : when I compile settings. apk , and decompile it again , the string with " " in arry.xml has changed , apktool2.0.jar 2.0.1 2.0.2 are in the same problem ,is there any suggestions?
[Android Software Development] mdiaz33685:
yep, having this issue for about a week, can't fix framework-res.apk

recompiling array.xml with framework-res.apk having all the same issues as above,, waiting for fix..
[Android Software Development] areyouanand:
I have downloaded the apktool4.4_armhf data and 5.2 apktool and latest apktool.Jar

I have replaced the jar with the downloaded one, and given root permission to the app and selected data folder, imported framework results. Apk

But can't decompile anything getting error w: could not find xxxxxxx and xxxxxxx and xxxxxxx like that, how to make it work?

I'm using s5 running 5.1.1
[Android Software Development] sdeft:
Same here. Workaround is to use apktool v2.0.1. You will still get some warnings but it works.
[Android Software Development] mdiaz33685:
I tried a few older versions also, it doesn't work for me. Just waiting for a fix.

edit: also tried in win7 pro x64 and win10 enterprise x64

how is everyone else getting it to work, tried apktools v200 v201 v202 using java 7 update 51 this all started with this new update on the tmobile note 4 ver 5.1.1..

is it a 5.1.1 issue..
[Android Software Development] mdiaz33685:
[MENTION=3924617]iBotPeaches[/MENTION] or anyone that has solved this issue, I see other developers fixing framework-res.apk

I tried switching to a lower java just in case.. and new versions.. tried apktool.jar all versions.. no issues prior to android 5.1.1

java version "1.7.0_45"

same thing, tried new java also jdk-8u66

I decompile the file framework-res.apk and didn't do any changes at all, just to see what will happen, I get the same errors when I recompile..

tried forcing command, no dice...

N910TUVU2DOK2_N910TTMB2DOK2_TMB-v5.1.1

Note 4 Tmobile variant N910T

B:\Apktool-N910TUVU2DOK2>apktool b --force-all framework-res

I: Using Apktool 2.0.2

W: Could not find sources

I: Building resources...

B:\Apktool-N910TUVU2DOK2\framework-res\res\drawable-sw360dp-xxxhdpi-v13\ic_knox_badge.PNG: error: File is case-insensitive equivalent to: B:\Apktool-N910TUVU2DOK2\framework-res\res\drawable-xxxhdpi-v4\ic_knox_badge.png

Exception in thread "main" brut.androlib.AndrolibException: brut.androlib.AndrolibException: brut.common.BrutException: could not exec command: [C:\Users\MD\AppData\Local\Temp\brut_util_Jar_4281142965058200576.tmp, p, --forced-package-id, 1, --min-sdk-version, 22, --target-sdk-version, 22, --version-code, 22, --version-name, 5.1.1-N910TUVU2DOK2, -F, C:\Users\MD\AppData\Local\Temp\APKTOOL3737258491788173898.tmp, -x, -0, arsc, -S, B:\Apktool-N910TUVU2DOK2\framework-res\res, -M, B:\Apktool-N910TUVU2DOK2\framework-res\AndroidManifest.xml]

at brut.androlib.Androlib.buildResourcesFull(Androlib.java:465)

at brut.androlib.Androlib.buildResources(Androlib.java:403)

at brut.androlib.Androlib.build(Androlib.java:291)

at brut.androlib.Androlib.build(Androlib.java:261)

at brut.apktool.Main.cmdBuild(Main.java:225)

at brut.apktool.Main.main(Main.java:84)

Caused by: brut.androlib.AndrolibException: brut.common.BrutException: could not exec command: [C:\Users\MD\AppData\Local\Temp\brut_util_Jar_4281142965058200576.tmp, p, --forced-package-id, 1, --min-sdk-version, 22, --target-sdk-version, 22, --version-code, 22, --version-name, 5.1.1-N910TUVU2DOK2, -F, C:\Users\MD\AppData\Local\Temp\APKTOOL3737258491788173898.tmp, -x, -0, arsc, -S, B:\Apktool-N910TUVU2DOK2\framework-res\res, -M, B:\Apktool-N910TUVU2DOK2\framework-res\AndroidManifest.xml]

at brut.androlib.res.AndrolibResources.aaptPackage(AndrolibResources.java:425)

at brut.androlib.Androlib.buildResourcesFull(Androlib.java:451)

... 5 more

Caused by: brut.common.BrutException: could not exec command: [C:\Users\MD\AppData\Local\Temp\brut_util_Jar_4281142965058200576.tmp, p, --forced-package-id, 1, --min-sdk-version, 22, --target-sdk-version, 22, --version-code, 22, --version-name, 5.1.1-N910TUVU2DOK2, -F, C:\Users\MD\AppData\Local\Temp\APKTOOL3737258491788173898.tmp, -x, -0, arsc, -S, B:\Apktool-N910TUVU2DOK2\framework-res\res, -M, B:\Apktool-N910TUVU2DOK2\framework-res\AndroidManifest.xml]

at brut.util.OS.exec(OS.java:89)

at brut.androlib.res.AndrolibResources.aaptPackage(AndrolibResources.java:419)

... 6 more

any advise from someone how got this thing working, or is it just a bug... ?

or is it just a Microsoft Windows issue... ?
[Android Software Development] :
I noticed the knox badge pgn. When I decompiled 5.1.1 framework res it decomplied knox badge as PGN changing the PGN to pgn fixed it
[Android Software Development] iBotPeaches:
Don't be afraid to read the stacktrace. As you can see from the above error. There are two files

ic_knox_badge.PNG

ic_knox_badge.png

There are case insensitive equivalent files. Removing one should make it work. The question now remains did the original apk have two images or did the decode of the application produce two files? Not sure
[Android Software Development] edzamber:
You can remove the twice, no issue to recompil ;)

Original have theses twice files.

They are security to block recompilation. Remove theses solve issue. Needs to remove theses twice values in public.xml too (the full twice ids correspondant lines) ;)
[Android Software Development] mdiaz33685:
thank you all guys, worked in a heartbeat... in a few seconds it was recompiled.

---------- Post added at 01:54 PM ---------- Previous post was at 01:48 PM ----------

Thank you all, have been trying for over 2 weeks, and kept seeing knox error, but wasn't sure what to do...

Hope you had a Merry Christmas

and have a Happy New Year...
[Android Software Development] iBotPeaches:
A new version has been released!

v2.0.3 (Released December 31, 2015)

On my immediate radar is now

APKs with multiple key names

APKs with custom namespaces (res/auto) that breaks locally referenced custom attributes

APKs that have crazy UTF8 chars (Dexguard) for rebuilding

Adding support for aapt path customization

Removal of SmaliDebugging

Download: https://bitbucket.org/iBotPeaches/apktool/downloads/apktool_2.0.3.jar

Details of Release: http://connortumbleson.com/2015/12/31/apktool-v2-0-3-released/
[Android Software Development] bdorr1105:
You are the man, thanks bro
[Android Software Development] starbucks2010:
@iBotPeaches

Thank you for your wonderful work and I wish you a Happy New Year.

For the next version, can you please try find a fix tw-framework (Android 5.1.1)? It decompiles fine with any version of apktool but recompilation is not successful with v2.0.2 nor v2.0.3. The only apktool that succeed to recompile tw-framework.apk is 2.0.0.B9.Error log attached.

Best regards.