Bug 31151 - apktool fails to decode apk
Summary: apktool fails to decode apk
Status: RESOLVED INVALID
Alias: None
Product: Android
Classification: Xamarin
Component: General ()
Version: 5.1
Hardware: PC Windows
: Normal normal
Target Milestone: ---
Assignee: Jonathan Pryor
URL:
Depends on:
Blocks:
 
Reported: 2015-06-16 09:38 UTC by Grigory (Playtika)
Modified: 2015-06-17 23:27 UTC (History)
2 users (show)

Tags:
Is this bug a regression?: ---
Last known good build:

Notice (2018-05-24): bugzilla.xamarin.com is now in read-only mode.

Please join us on Visual Studio Developer Community and in the Xamarin and Mono organizations on GitHub to continue tracking issues. Bugzilla will remain available for reference in read-only mode. We will continue to work on open Bugzilla bugs, copy them to the new locations as needed for follow-up, and add the new items under Related Links.

Our sincere thanks to everyone who has contributed on this bug tracker over the years. Thanks also for your understanding as we make these adjustments and improvements for the future.


Please create a new report on Developer Community or GitHub with your current version information, steps to reproduce, and relevant error messages or log files if you are hitting an issue that looks similar to this resolved bug and you do not yet see a matching new report.

Related Links:
Status:
RESOLVED INVALID

Description Grigory (Playtika) 2015-06-16 09:38:03 UTC
Playtika-build-server-0: mobile_build_system$ java -jar /Users/Shared/Jenkins/scripts/java/apktool.jar decode /Users/Shared/Jenkins/scripts/test/Slotomania.1280x720.82.x86.Release.apk /test1
I: Baksmaling...
I: Loading resource table...
Exception in thread "main" brut.androlib.AndrolibException: Could not decode arsc file
        at brut.androlib.res.decoder.ARSCDecoder.decode(ARSCDecoder.java:56)
        at brut.androlib.res.AndrolibResources.getResPackagesFromApk(AndrolibResources.java:390)
        at brut.androlib.res.AndrolibResources.loadMainPkg(AndrolibResources.java:56)
        at brut.androlib.res.AndrolibResources.getResTable(AndrolibResources.java:48)
        at brut.androlib.Androlib.getResTable(Androlib.java:48)
        at brut.androlib.ApkDecoder.getResTable(ApkDecoder.java:166)
        at brut.androlib.ApkDecoder.decode(ApkDecoder.java:99)
        at brut.apktool.Main.cmdDecode(Main.java:131)
        at brut.apktool.Main.main(Main.java:68)
Caused by: java.io.IOException: Expected: 0x001c0001, got: 0x00000000
        at brut.util.ExtDataInput.skipCheckInt(ExtDataInput.java:48)
        at brut.androlib.res.decoder.StringBlock.read(StringBlock.java:44)
        at brut.androlib.res.decoder.ARSCDecoder.readPackage(ARSCDecoder.java:98)
        at brut.androlib.res.decoder.ARSCDecoder.readTable(ARSCDecoder.java:83)
        at brut.androlib.res.decoder.ARSCDecoder.decode(ARSCDecoder.java:49)
        ... 8 more
Comment 1 Jonathan Pryor 2015-06-16 09:42:19 UTC
That's probably an apktool bug. Which apktool version are you using? Is it the latest?
Comment 2 Grigory (Playtika) 2015-06-17 23:27:20 UTC
U're absolutely right. 1.5.2 doesn't work with Xamarin build, but perfectly worked with our native Android app. That lead me to wrong conclusion.

Marking bug as invalid.
Comment 3 Grigory (Playtika) 2015-06-17 23:27:54 UTC
ApkTool 2.0 works like a charm.