-
Notifications
You must be signed in to change notification settings - Fork 33
Support for changes to AndroidManifest.xml #30
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
Hi @gradyl16, If I don’t use the --no-res option, the manifest seems to be modified automatically. Also, I was unable to find a way to decode and re-encode the AndroidManifest.xml when using the --no-res option — is there a method for this that I might be missing? |
I assume it works properly when not using the I haven't found any tools that can reliably retain the original encoding of the manifest file after manipulation. There are tools to decode/reencode the manifest like xml2axml. However, I've noticed that after reencoding the manifest and recompiling the apk that the installation fails due to some sort of alignment error:
Perhaps this is an artifact of the particular tool I'm using, though. If we could find exactly which tool iBotPeaches/Apktool#2514 Looks like handling split APKs is a known issue for |
Motivation
Some applications don't ship with any native libraries. In this case, the android manifest will have a line something like:
You may be able to patch the application properly in all other respects, but if this is retained, you will receive something like the following error on installation:
A simple fix would be to change the aforementioned flag to
true
. However, if you're having issues rebuilding resources, then you generally have to skip the resource decoding during compilation (i.e. with the--no-res
flag). This requires one to manually decode theAndroidManifest.xml
, make the change, reencode it, then recompile.Request
I'm hoping you can include a feature (perhaps another cmd line flag) that allows a user of
frida-gadget
to specify either just a yes/no for whether they would like to modify this part of the manifest, or just one that automatically checks the value of this attribute and modifies it accordingly (since you need it set to true to install the patched application regardless).The text was updated successfully, but these errors were encountered: