What steps will reproduce the problem?
1. Decompile an apk whichs AndroidManifest.xml includes a line like this:
<meta-data android:name="com.facebook.sdk.ApplicationId" android:value="141304042684635" />
2. Do your changes (in my case instrument it for automated testing)
3. Recompile the apk
4. Decompile the result again and have a look at that value in
AndroidManifest.xml
What is the expected output? What do you see instead?
The AndroidManifest.xml should include the original meta data as shown above in
(1). Instead I see a line like this:
<meta-data android:name="com.facebook.sdk.ApplicationId"
android:value="-381353765" />
What version of the product are you using? On what operating system?
apktool 2.0.0RC4, Win7Pro and Win8Pro
Please provide any additional information below.
Workaround: Change the value mentioned under (1) to a string of the same length
(e.g. "xxxxxxxxxxxxxxx") and compile it. After that you will find that string
in the resulting apks compiled AndroidManifest.xml. Just replace it (in the
apks binary) with the original string and go ahead with the apk (sign, align)
and it'll work fine.
I guess the value of the original line (1) is interpreted as a number what
seems giving an overflow which leads to a wrong result in the binary. Instead
the XML compiler should interpret the original value (1) as string (what it is
intended to be).
Original issue reported on code.google.com by TheHar...@googlemail.com on 13 Mar 2015 at 6:03
Original issue reported on code.google.com by
TheHar...@googlemail.com
on 13 Mar 2015 at 6:03