Related
Hello,
I'm trying to hack an apk.
My first step was to use apk multi tool, and to just decompile and recompile it.
This is what i've done:
decompiling
recompiling (without any mod)
signing
No error appears during those steps.
But this new apk won't install on my phone !
If I check difference between the two apk:
all xml files are differents
.RSA and .SF have not the same name
classes.dex, resources.arsc and manifest.mf are differents
I don't understand those difference. can somebody help me to understand that and how to recomile a proper version ?
PS: This app is a french app that shows speed cameras on the road. However this app is now only showing a big zone and not the exact location for france. But it stills show precise location for other countries, so obfuscation is done at the apk level, and I already found where it is in the code, so i'd like to bypass it and recompile a "special' version
Thanx
Just a few quick questions. Is you phone set to install from sources than Droid market? You do know the newly compiled and signed project will be located in the "place_package _here_ for_Modding" folder and is named "Signed(yourappnamehere).apk?
Sent from my SAMSUNG-SGH-I727 using xda premium
Hi,
yes, i took the newly compiled apk in this directory, and yes my phone is set accept unknown sources.
When i install the apk, i first have the
- liste of phones serviesc that will be used
- then the install progress bar
- then the message "application not installed"
I guess there is some kind of protection in the sources...
I also noticed that the two apk - original, and resigned one - don't have same size.
The only difference is actually in the META-INF directory : the .RSA and the .SF files.
In the original application they are:
- IFOX_.RSA
- IFOX_.SF
But when recompiling, those files are:
- CERT.RSA
- CERT.SF
I'm shure the problem comes from here, but i'm too noob to analyse that...
So my proble can be sum-up by:
Why the recompilation doesn not give me the same RSA and SF file ??
Beware there are some modifications that you cant do on decs, expecially the packagename.
also beware to disable the "non-market" tag on the phone.
Yes, but for the moment i didn't make any modification:
Just decompiling, recompiling and resigning.
Maybe you want to tell that the apk name must stay the same ? (sorry my english is not perfect )
GOT IT WORKED !!!
You must first uninstall the previous application !
I was trying to install my new one over the old one, but the signatures are not the same !!!
Thanx everybody, and hope this will help somebody !
APK edit error 103
Ok im having a similar issue.
I know the file size is mismatched but ive never had this issue
as a test i only modded 1 thing but 4 files
changed a link in an html / changed an image and its name and the html included the link to the new name
when this failed i changed the manifest and the .sf to match the change i made with name but not the sha :"no clue here"
Tried...
APK multi tool ... and 7zip to make the mods
Tried... Bothsigned and unsigned.
Tried copying the sig from old apk to new with names corrected "notsha" fail still
Tried....
Origional APK installs no issue
Uninstall orig apk rebooted
Allow out side apps yes and no.both
using file manager explorer and root browser and es file manager
Copying directly to /system/app fail
copying to data/data/app/copy fail " yes it wont even copy to there"
Tried.. Multiple phones
I then tried a hex editor on the apk. And after changes install still fail.
I modded several other apk's even my framework but this is the first app that ha given me so many issues
This is an app to help elderly users access internet and the devs are AWOL and the project abandoned
Code:
https drive google com/folderview?id=0B5PggxVy7c8meDhrcjNJOGs5cFk&usp=sharing
Code:
www eldy eu/en/software/eldy-tablet/
"edited for posting "
The goal here is to make it more U.S. friendly its English base is geared to English UK and this does not help my family as we are in the U.S.
All i can get from logcat is error 103
Logcat shows package it.vegans.eldy has no certificate at entry AndroidManifest.xml ignoring
Knstallation error code 103
I tried apk multitool certify thing
i tried copying the certs from old to new apk
i tried modding the cert to correct names
So maybe im mentally challenged but i just cant figure this one out
---
Edit .
I attached a zip with original and modified apk's
All i want to do is simple html edits xml link edits and img changes since mostly the app is a series of pages.
Does anyone know how to make gapps?
???
Gapps are already made, just flash it.
If you want to declude apps, unzip it, delete files from /system/app and data/app and re-zip
Greets!
I'm not a fake.
I prefer people to reply to me and give feedback instead of thanking me!
But thanking me does show if you apreciate my works.
I understand the question I think... as I have a similar one. How can one make their own gapps package? Or is that even necessary?
I am tempting to build an AOSP rom and would need gapps to be flashed with it. Do I just include the latest from cm, or, can I package my own in order to be the owner of them?
Sent from my Evo using xda premium
When i build a aosp rom, the zip file doesn't contains with google apps so i want to make a own google apps. How do i get the apk and how to re-package the apk to zip (using dsixda?)
echo_rc said:
When i build a aosp rom, the zip file doesn't contains with google apps so i want to make a own google apps. How do i get the apk and how to re-package the apk to zip (using dsixda?)
Click to expand...
Click to collapse
To include in your zip, just paste inside the WORKING_FOLDER.
You can grab the GAPPS from Android development and hacking > Themes and Apps, from CM web-page, and lots of more.
Just google it!
Greets!
I'm not a fake.
I prefer people to reply to me and give feedback instead of thanking me!
But thanking me does show if you apreciate my works.
I am pretty sure this thread is pertaining to the question, How did someone create gapps before you could just download them. That is easy.
There are applications that are google proprietary software that is bundled with roms. Rather it be sense, blur, touchwiz or AOSP. These google prop bits are there.
The easiest way to "create your own gapps" is to:
1) Look inside an existing gapps package and see what they used. Then use those same packages.
2) Grab all the google related jars, apks that are not available on the market, and are not included after compiling your own aosp rom. The extra apps for the most part are used for googles prop bits.
If there is a need for more detail. Please let me know.
To my understanding, you cannot include gapps in the rom for various general public license rules, hence you have to flash with cm
Sent from my Evo using xda premium
Ok thanks guys i will try grab from Android development and hacking > Themes and Apps, from CM web-page, and lots of more
Sorry guys but this is the only forum that is talking about this and i would really like to be able to do this. Does anyone know how to make gapps from an official rom update. And is there a program that will allow to make my own gapps to flash.
serranom said:
Sorry guys but this is the only forum that is talking about this and i would really like to be able to do this. Does anyone know how to make gapps from an official rom update. And is there a program that will allow to make my own gapps to flash.
Click to expand...
Click to collapse
I already explained it, and no.
mDroidd said:
???
Gapps are already made, just flash it.
If you want to declude apps, unzip it, delete files from /system/app and data/app and re-zip
Greets!
I'm not a fake.
I prefer people to reply to me and give feedback instead of thanking me!
But thanking me does show if you apreciate my works.
Click to expand...
Click to collapse
Very informative and much appreciated.
mDroidd said:
???
Gapps are already made, just flash it.
If you want to declude apps, unzip it, delete files from /system/app and data/app and re-zip
Click to expand...
Click to collapse
So I took Micro Modular Package, purged all .apk from \system\app and \system\priv-app, except GoogleLoginService.apk, GoogleServiceFramework, Phonesky.apk (which are, AFAIK, required minimum for GooglePlay) - but got en error during flashing: "file_getprop: failed to stat "/tmp/gapps.prop": No such file or directory"
The unaltered package is installing fine through, but that is not what I need
Samsung YP-G70EB, CM11 ROM.
XAN_ said:
So I took Micro Modular Package, purged all .apk from \system\app and \system\priv-app, except GoogleLoginService.apk, GoogleServiceFramework, Phonesky.apk (which are, AFAIK, required minimum for GooglePlay) - but got en error during flashing: "file_getprop: failed to stat "/tmp/gapps.prop": No such file or directory"
The unaltered package is installing fine through, but that is not what I need
Samsung YP-G70EB, CM11 ROM.
Click to expand...
Click to collapse
Silly me. While repacking, I failed to add delete-list.txt, gapps-list.txt, install-prep.sh files to resulting archive :laugh:
So I only added 2 folders, which apparently, isn't enough for correct installation
I was curious about this also.
I was looking to just update an existing gapps. My goal was to add a few extra apks not included in the standard gapps I'm using and delete a few to replace with black versions. Like youtube, google+ calender ect. Can I just add extra apps or do I need to update a file somewhere.
I noticed one file updater-script. But thats about it.
chopt51 said:
I was curious about this also.
I was looking to just update an existing gapps. My goal was to add a few extra apks not included in the standard gapps I'm using and delete a few to replace with black versions. Like youtube, google+ calender ect. Can I just add extra apps or do I need to update a file somewhere.
I noticed one file updater-script. But thats about it.
Click to expand...
Click to collapse
Yes you add it like you can see below it just extract the system directory in the gapps zip file and set it to the right permissions.
package_extract_dir("system", "/system");
set_perm(0, 0, 0755,
XAN_ said:
So I took Micro Modular Package, purged all .apk from \system\app and \system\priv-app, except GoogleLoginService.apk, GoogleServiceFramework, Phonesky.apk (which are, AFAIK, required minimum for GooglePlay) - but got en error during flashing: "file_getprop: failed to stat "/tmp/gapps.prop": No such file or directory"
The unaltered package is installing fine through, but that is not what I need
Samsung YP-G70EB, CM11 ROM.
Click to expand...
Click to collapse
I want to do this also. I want to install needed files (apk and needed libs maybe) so i can add my google account and log in to the account (so i can use Blogger official app). Simple apk extraction and installation didnt work (i did extract and install GoogleLoginService.apk but still couldn't add any google account). So should i modify gapps zip and delete all apks but GoogleLoginService.apk?
salmanfarisy said:
I want to do this also. I want to install needed files (apk and needed libs maybe) so i can add my google account and log in to the account (so i can use Blogger official app). Simple apk extraction and installation didnt work (i did extract and install GoogleLoginService.apk but still couldn't add any google account). So should i modify gapps zip and delete all apks but GoogleLoginService.apk?
Click to expand...
Click to collapse
Nope, GoogleLoginService.apk isn't enough you also need GoogleServiceFramework.apk, Phonesky.apk and some other .apk, but I forgot which one. The entire Micropackage isn't needed, though, it contains some extra .apk, which isn't needed for goggle login.
And yes, you need to flash gapps, just installing them won't do.
XAN_ said:
Nope, GoogleLoginService.apk isn't enough you also need GoogleServiceFramework.apk, Phonesky.apk and some other .apk, but I forgot which one. The entire Micropackage isn't needed, though, it contains some extra .apk, which isn't needed for goggle login.
And yes, you need to flash gapps, just installing them won't do.
Click to expand...
Click to collapse
you are right.
other apk needed is GmcCore.apk
Help with building gapps?
With TKruzzle shutting down his PA gapps packages and thread.
Just wondering how to get/build/use updated gapps as no one else is building them that I can see?
How can we get new gapps packages from google and compile them or whatever is needed.
Just wondering what would have to be done, and if I can do it.
Also liked the idea of flashing google login info into the gapps package as that would be pretty handy but not sure how to do it. Thanks.
L0X0R said:
With TKruzzle shutting down his PA gapps packages and thread.
Just wondering how to get/build/use updated gapps as no one else is building them that I can see?
How can we get new gapps packages from google and compile them or whatever is needed.
Just wondering what would have to be done, and if I can do it.
Click to expand...
Click to collapse
Almost everybody has a flashable gapps package somewhere. Download an official Nexus image for your Android architecture and version, and just replace the appropriate files in the zip.
There are sites that explain how to extract a system.img.
OK so i modified the framework-res.apk of a rom i recompiled it without signing. The problem is that i want to replace the old framework-res.apk in the zip file before flashing the rom.
When i do this either with 7 zip or winrar i get stuck in bootloop BUT if i flash only the framework-res.apk with an update.zip after i install the rom it works perfectly .
I searched all over and from what i read this should work... do i need to sign the apk if i replace it in the zip before flashing?
And if i need to sign it how i do that, i just sign it with apkmanager?
I haven't this problem, but try to sign it. They are many tools and apps for Android (also Linux) and Windows.
fd1999 said:
I haven't this problem, but try to sign it. They are many tools and apps for Android (also Linux) and Windows.
Click to expand...
Click to collapse
So you just open the .zip file replace the apk and it works?? Can you sugest some tool for signing? cause i signed it with apk manager and it din't work i got stuck at boot animation only this time it stops completly it doesn't loop...
Also i have the same issue with Settings.apk , this one if i put it in the zip before flashing it doesn't open even if i sign it or not ... what the hell am i doing wrong???
If i flash them individualy with .zip update after i flash the rom, everything works fine . But i want to modify the rom before flashing... to have only one zip ...
gafaysto said:
OK so i modified the framework-res.apk of a rom i recompiled it without signing. The problem is that i want to replace the old framework-res.apk in the zip file before flashing the rom.
When i do this either with 7 zip or winrar i get stuck in bootloop BUT if i flash only the framework-res.apk with an update.zip after i install the rom it works perfectly .
I searched all over and from what i read this should work... do i need to sign the apk if i replace it in the zip before flashing?
And if i need to sign it how i do that, i just sign it with apkmanager?
Click to expand...
Click to collapse
what actually happens is when u decompile apk with apktool and then recompile it, signature gets mismatched so it gets stuck on bootloop. To solve this use apkmanager and decompile it as system app, perform changes and then recompile by following instructions therein
fundoozzz said:
decompile it as system app, perform changes and then recompile by following instructions therein
Click to expand...
Click to collapse
Is that the option to decompile apk <with dependencies> cause i don't find any other option to decompile , or i have to switch decompile mode ???
gafaysto said:
Is that the option to decompile apk <with dependencies> cause i don't find any other option to decompile , or i have to switch decompile mode ???
Click to expand...
Click to collapse
yup decompile with dependencies
fundoozzz said:
yup decompile with dependencies
Click to expand...
Click to collapse
Ok i got it working , the problem was that i skipped a step when building the apk , when it offered to copy any additional files in order to ensure
least number of errors it seems that is an very important step ...
gafaysto said:
Ok i got it working , the problem was that i skipped a step when building the apk , when it offered to copy any additional files in order to ensure
least number of errors it seems that is an very important step ...
Click to expand...
Click to collapse
fundoozzz said:
perform changes and then recompile by following instructions therein
Click to expand...
Click to collapse
Thats what I said
Hi
Can I use winrar to extract a rom intended for CWM installation, modify it with basic changes such as:
1. Replace an application in system./app with a newer version making sure I rename the new file save as the original?
2. Merge a compatible mod into the rom, by coping the files from the mod.zip to the rom.zip in the corresponding locations (system/app and system/media)? Do I also need to update any inf file with the new changes?
For example, I want to modify the RR2.7 rom by upgrading the apex launcher to latest version 1.3.1 (it comes with 1.2.5) and also merge the TouchWiz clock into it. The Apex apk is located in RR/Apex/com.anddoes.launcher-1.apk. Can I rename the new Apex to com.anddoes.launcher-1.apk and replace the original? (The apex launcher can be selected during installation by Aroma). Can you merge any compatible mods and create a new "slipstreamed" rom installer?
Is this safe to do? Will it work? When I re-zip it, can I use any compression method (highest?).
Many thanks
EB10000 said:
Hi
Can I use winrar to extract a rom intended for CWM installation, modify it with basic changes such as:
1. Replace an application in system./app with a newer version making sure I rename the new file save as the original?
2. Merge a compatible mod into the rom, by coping the files from the mod.zip to the rom.zip in the corresponding locations (system/app and system/media)? Do I also need to update any inf file with the new changes?
For example, I want to modify the RR2.7 rom by upgrading the apex launcher to latest version 1.3.1 (it comes with 1.2.5) and also merge the TouchWiz clock into it. The Apex apk is located in RR/Apex/com.anddoes.launcher-1.apk. Can I rename the new Apex to com.anddoes.launcher-1.apk and replace the original? (The apex launcher can be selected during installation by Aroma). Can you merge any compatible mods and create a new "slipstreamed" rom installer?
Is this safe to do? Will it work? When I re-zip it, can I use any compression method (highest?).
Many thanks
Click to expand...
Click to collapse
Bump
Anyone??
Do not unpack ROM zip, just replace files with WinRAR.
Compression method must be set to normal.
And yes, it's safe, but you need to do it carefully.
EB10000 said:
Hi
Can I use winrar to extract a rom intended for CWM installation, modify it with basic changes such as:
1. Replace an application in system./app with a newer version making sure I rename the new file save as the original?
2. Merge a compatible mod into the rom, by coping the files from the mod.zip to the rom.zip in the corresponding locations (system/app and system/media)? Do I also need to update any inf file with the new changes?
For example, I want to modify the RR2.7 rom by upgrading the apex launcher to latest version 1.3.1 (it comes with 1.2.5) and also merge the TouchWiz clock into it. The Apex apk is located in RR/Apex/com.anddoes.launcher-1.apk. Can I rename the new Apex to com.anddoes.launcher-1.apk and replace the original? (The apex launcher can be selected during installation by Aroma). Can you merge any compatible mods and create a new "slipstreamed" rom installer?
Is this safe to do? Will it work? When I re-zip it, can I use any compression method (highest?).
Many thanks
Click to expand...
Click to collapse
Yes, you can do it i.e replace apps in the ROM before flashing, but you need a little understanding about how to do it.
I will also advise you to flash any mod over the ROM, instead of replacing the files in the rom because i think you don't have much understanding about this.
przemcio510 said:
Do not unpack ROM zip, just replace files with WinRAR.
Compression method must be set to normal.
And yes, it's safe, but you need to do it carefully.
Click to expand...
Click to collapse
Thank you for the help. Just to be on the safe side. If I merge files from a compatible mod, I do not need to overwrite the Meta-Inf directory right? I just edit the zip file within winrar and add/overwrite the Media and app folders inside the system folder? Is that correct?
Thanks
Yes.
META-INF folder contains binaries and script used by CWM, so there is no need to edit updater-script.
Hi guys,
my father recently bought a so-called China phone (Doogee X5max) that comes with several malwares right out of the box.
Most of the are quite easy to remove, two of them give me the creeps.
I am no pro when it comes to Android and so I stumbled across several problems.
First of all I managed to remove the malware from Settings.apk and SystemUI.apk by decompiling, editing and odexing the files and compiling them again. Easy going...
So far so good.
Now for the hard part.
How to get those files back into the ROM? Since those files need to be resigned with the same certificate that was used signing all the other system files I am kind of stuck here. Resigning the files with Zipsigner (using all possible types, "platform", etc.) did not work which leads me to the conclusion that Doogee did not use the AOSP certificates to sign their ROM. Am I right?
The only possible solution seems to be creating a custom ROM out of the Doogee X5max stock ROM. Is this correct?
I googled a lot but have not found up-to-date or understandable manuals/instructions on how to do this.
Can someone please help me or give me a hint at least?
Thanks in andvance
deomaki
deomaki said:
Hi guys,
my father recently bought a so-called China phone (Doogee X5max) that comes with several malwares right out of the box.
Most of the are quite easy to remove, two of them give me the creeps.
I am no pro when it comes to Android and so I stumbled across several problems.
First of all I managed to remove the malware from Settings.apk and SystemUI.apk by decompiling, editing and odexing the files and compiling them again. Easy going...
So far so good.
Now for the hard part.
How to get those files back into the ROM? Since those files need to be resigned with the same certificate that was used signing all the other system files I am kind of stuck here. Resigning the files with Zipsigner (using all possible types, "platform", etc.) did not work which leads me to the conclusion that Doogee did not use the AOSP certificates to sign their ROM. Am I right?
The only possible solution seems to be creating a custom ROM out of the Doogee X5max stock ROM. Is this correct?
I googled a lot but have not found up-to-date or understandable manuals/instructions on how to do this.
Can someone please help me or give me a hint at least?
Thanks in andvance
deomaki
Click to expand...
Click to collapse
After recompiling your modded apk, unzip it and the original apk, replace everything in the original apk with what is in your modded apk except meta-inf and Android manifest. Zip back up, change it from .zip to .apk. That is what you use to replace your system apk. That only goes for system apks. You sign the others.
Tulsadiver said:
After recompiling your modded apk, unzip it and the original apk, replace everything in the original apk with what is in your modded apk except meta-inf and Android manifest. Zip back up, change it from .zip to .apk. That is what you use to replace your system apk. That only goes for system apks. You sign the others.
Click to expand...
Click to collapse
Hi,
Thanks for your reply.
Before giving this a chance, just one question: By "Android manifest" I suppose you mean manifest.ms?
Kind regards
deomaki
deomaki said:
Hi,
Thanks for your reply.
Before giving this a chance, just one question: By "Android manifest" I suppose you mean manifest.ms?
Kind regards
deomaki
Click to expand...
Click to collapse
I have never seen a manifest.ms but I suppose so if that is what is in yours.
Tulsadiver said:
I have never seen a manifest.ms but I suppose so if that is what is in yours.
Click to expand...
Click to collapse
The manifest.ms resides inside the META-INF folder...
Trying to installl the so manipulated original apk via adb results in [INSTALL_PARSE_FAILED_NO_CERTIFICATES].
Am I supposed to uninstall the original settings.apk from the device first (which I did) or just replace the original apk on the device with the newly created one and delete the odex in oat/arm?
Thanks in advance
deomaki
deomaki said:
The manifest.ms resides inside the META-INF folder...
Trying to installl the so manipulated original apk via adb results in [INSTALL_PARSE_FAILED_NO_CERTIFICATES].
Am I supposed to uninstall the original settings.apk from the device first (which I did) or just replace the original apk on the device with the newly created one and delete the odex in oat/arm?
Thanks in advance
deomaki
Click to expand...
Click to collapse
You leave the original meta-inf like I said. You use the original apk replacing everything in it with the modded stuff, res, resource.arsc if any and any classes.dexs. Don't worry about any oat folders.
Tulsadiver said:
You leave the original meta-inf like I said. You use the original apk replacing everything in it with the modded stuff, res, resource.arsc if any and any classes.dexs. Don't worry about any oat folders.
Click to expand...
Click to collapse
Hi Tulsadiver,
I followed your advice and replaced everything except the menta-inf folder from the original apk. Then I copied over my modded apk and restarted the device (just to be sure).
After rebooting the Settings icon was gone from my homescreen and the app drawer, leaving me unable to start the settings.
Tapping the seetings.apk using a file browser left me with the error, that there was an error while parsing...
Regards
deomaki
deomaki said:
Hi Tulsadiver,
I followed your advice and replaced everything except the menta-inf folder from the original apk. Then I copied over my modded apk and restarted the device (just to be sure).
After rebooting the Settings icon was gone from my homescreen and the app drawer, leaving me unable to start the settings.
Tapping the seetings.apk using a file browser left me with the error, that there was an error while parsing...
Regards
deomaki
Click to expand...
Click to collapse
I actually said, everything but the original meta-inf folder and original Android manifest....
Steps
Decompile apk.
Edit your apk
Recompile apk.
Unzip both modded and original apk
Delete everything in the original apk except meta-inf and Android manifest.
Copy everything from modded apk over to original apk except for the meta-inf and Android manifest.
Zip it back up, change it from .zip to .apk.
Copy this apk to the root of your phone.
Change permission to 0644
Copy/Move to replace the existing apk.
Reboot
Tulsadiver said:
I actually said, everything but the original meta-inf folder and original Android manifest....
Steps
Decompile apk.
Edit your apk
Recompile apk.
Unzip both modded and original apk
Delete everything in the original apk except meta-inf and Android manifest.
Copy everything from modded apk over to original apk except for the meta-inf and Android manifest.
Zip it back up, change it from .zip to .apk.
Copy this apk to the root of your phone.
Change permission to 0644
Copy/Move to replace the existing apk.
Reboot
Click to expand...
Click to collapse
Hi again,
thanks for your efforts by the way
That's exactly what I did except taking the original androidmanifest.xml since I had to change some things in it...
Will the whole process be not applicable then?
Regards
deomaki
deomaki said:
Hi again,
thanks for your efforts by the way
That's exactly what I did except taking the original androidmanifest.xml since I had to change some things in it...
Will the whole process be not applicable then?
Regards
deomaki
Click to expand...
Click to collapse
Unclear. I've seen some doogee posts on here. Maybe try one of those?
Tulsadiver said:
Unclear. I've seen some doogee posts on here. Maybe try one of those?
Click to expand...
Click to collapse
mmmh, maybe if will have to find out all system apks that use the same certificate framework-res.apk does and resign them with a new cert including the modded system.apk.
I was trying to find a way around that, but maybe I have to go the hard way...
I think that should solve my problem, what do you think?
Regards
deomaki