I have an idea to write a new Morphing tool that will work with any apk on your phone. (except ones moved to sd using froyo's a2sd. don't know how to get the apk from there)
Features: (Please let me know if you have better/more ideas)
1) Target apks with wildcards. (Since Froyo apks have -1, -2, -3... appended to the name.) If more than one file is found the user can choose which file to morph.
2) Backup the old apk and provide an option to restore the backup. If the morph is cancelled or fails restore the backup.
3) On-phone signing so non-system apks can be morphed too.
i.e. The old apk is uninstalled and the morphed+signed apk is installed if its a non-system app. For system apks the old apk is simply overwritten.
4) Simple property style text configuration file that maps morph folders (in the morph zip) to apks.
example: launcher-files=launcher2*.apk
5) Search /data/app for the target apk first, next search /system/app
6) Pick up keys to use from a specified sdcard folder, if not found use the standard test key.
7) Option to download a morph .zip from the web via a url (using wget).
i.e. you send a URL to your phone using chrome/*-to-phone and then paste the URL in.
8) zipalign the morphed+signed apk.
System requirements (so far):
root/su
busybox
signapk installed
wget binary for android installed.
If someone is already working on something similar, let me know. Dont want to duplicate effort. This will be an open source app though.
britoso said:
3) On-phone signing so non-system apks can be morphed too.
i.e. The old apk is uninstalled and the morphed+signed apk is installed if its a non-system app. For system apks the old apk is simply overwritten.
Click to expand...
Click to collapse
Isn't this going to break updating those apps tho? For example if I was to morph/resign angry birds, when angry birds gets a market update it's going to fail to install due to signing mismatch.
gIMpSTa said:
Isn't this going to break updating those apps tho? For example if I was to morph/resign angry birds, when angry birds gets a market update it's going to fail to install due to signing mismatch.
Click to expand...
Click to collapse
correct, but you will know when there is a market update and can uninstall the morphed version. Its the price for the morphability.
britoso said:
correct, but you will know when there is a market update and can uninstall the morphed version. Its the price for the morphability.
Click to expand...
Click to collapse
Got ya. Figured you had already thought of that but wanted to point it out just in case. I assumed uninstall/update would be the suggested course for said apps, but again just wanted to make sure you had thought of that issue!
gIMpSTa said:
Got ya. Figured you had already thought of that but wanted to point it out just in case. I assumed uninstall/update would be the suggested course for said apps, but again just wanted to make sure you had thought of that issue!
Click to expand...
Click to collapse
yeah, you could restore the backed up apk and then update, or uninstall manually and install again.
Related
Hello,
I did some searching before posting this and have come up with little results that are working for me. I have been able to change my stock icon apps using the method on androidcentral (sorry, can not post links yet). However, trying the same thing with Free Market Apps, I have been unsuccessful.
I am able to get the com.*.*.apk file off of my phone, and can extract the res folder, but after editing and pushing the file back onto the phone, the application is "uninstalled." I believe that I have to sign the apk file again, which I've tried doing with no success.
What I do not understand, is the app Bettercut has the ability to change these Market App Icons, so I thought we should be able to do so as well. If anyone has any knowledge of how to do this, I would greatly appreciate it.
Thanks
Hey you
Change your graphics. Uninstall the app from your phone, put the edited .apk on your sd card and install it with astro (or another app that installs apk files). If you update from market you'll lose customizations.
Hiya.
Yeah, I tried that, but I keep getting unable to install. I do have non-market apps checked, but still no luck. I'm basically just editing the graphic from the com.*.*.apk file, opeing the com.*.*.apk file with 7zip, placing the new graphic in the res/drawable folder, closing 7zip, then I put the com.*.*.apk file onto my SD card (after uninstalling original app) then use astro to install. Doing this is not working. I thought I might have to sign the apk file, rename it or something. Not really sure at this point.
ccapasso said:
Hiya.
Yeah, I tried that, but I keep getting unable to install. I do have non-market apps checked, but still no luck. I'm basically just editing the graphic from the com.*.*.apk file, opeing the com.*.*.apk file with 7zip, placing the new graphic in the res/drawable folder, closing 7zip, then I put the com.*.*.apk file onto my SD card (after uninstalling original app) then use astro to install. Doing this is not working. I thought I might have to sign the apk file, rename it or something. Not really sure at this point.
Click to expand...
Click to collapse
I got it to work by pushing the .apks back through adb and not using a File Manager. I changed a bunch of my Market icons without any problem. No fc's or install failures.
So say for example you were to change the Market Icon for Spare Parts. I assume you did the following:
Pulled com.androidapps.spare_parts.apk from /data/app
Edited the app_icon.png file within the res/drawable folder
Uninstalled Spare Parts
Pushed com.androidapps.spare_parts.apk back to /data/app
Or did you do it differently?
Thanks again for all the help on this. Not sure exactly what is going wrong on my end.
I never uninstalled the apk. I just drug a copy of the .apk to my computer, edited the image, and then pushed it back over the original one. Im in no way any kind of expert, but it worked when I did it.
Hmm. So are you going into /data/app and pulling the com.androidapps.spare_parts.apk (for example), editing, then pushing back w/ out signing or anything? I assume you are pushing back the same file, name exactly the same and everything.
So for example you would have pulled com.androidapps.spare_parts.apk from /data/app, edited the png within the apk file, then pushed com.androidapps.spare_parts.apk back to /data/app and it worked?
No rebooting, signing or anything?
I'm using Fresh 1.1 with MCK and again, do not have SD card partitioned for apps2sd yet.
Thanks again.
Yep, that's what I did. No updating, signing, nothin. I did reboot after I was all done. And I dont mess around with that apps2sd business either. So it should be the same.
gomorrah said:
I never uninstalled the apk. I just drug a copy of the .apk to my computer, edited the image, and then pushed it back over the original one. Im in no way any kind of expert, but it worked when I did it.
Click to expand...
Click to collapse
Wow that worked pretty nicely! I was trying to change the little slide bar that moves as you change screens. I kept upzipping the file and modifying it, then rezipping and trying to reinstall. 7zip lets you modify the .apk with out opening it up...glad this subject came up and you answered this!
Ok. Step by step here is what I did just now:
1. adb pull /data/app/com.androidapps.spare_parts.apk C:\Users\Chris\Desktop
2. Used 7zip to open the apk file.
3. Moved my app_icon.png file into the res/drawable folder and overwrote the current one
4. adb push C:\Users\Chris\Desktop\com.androidapps.spare_parts.apk /data/app/
5. adb shell
6. reboot
Doing this did not work. It only made the icon on my home screen for Spare Parts go away, and the app is no longer listed as being installed. I can still see the file in my /data/app/ directory, but it is not installed or showing up anywhere.
Any ideas?
ccapasso said:
Ok. Step by step here is what I did just now:
1. adb pull /data/app/com.androidapps.spare_parts.apk C:\Users\Chris\Desktop
2. Used 7zip to open the apk file.
3. Moved my app_icon.png file into the res/drawable folder and overwrote the current one
4. adb push C:\Users\Chris\Desktop\com.androidapps.spare_parts.apk /data/app/
5. adb shell
6. reboot
Doing this did not work. It only made the icon on my home screen for Spare Parts go away, and the app is no longer listed as being installed. I can still see the file in my /data/app/ directory, but it is not installed or showing up anywhere.
Any ideas?
Click to expand...
Click to collapse
Try pulling the original icon and editing it. Just make it a solid black square. Then put it back in and push to the phone. Sounds like your new icon changes the filesize enough that it needs resigned.
Hoping someone can give me a hand here... I feel like I am missing something obvious.
I wanted to learn how to make changes to system APKs, more educational than anything else... figured I'd do something simple like edit mms_config.xml for a slightly larger width/height in Mms.apk
I downloaded APK Manager and followed the steps (I thought). I decomplied the APK, made the adjustment, and recompiled the APK... choosing 'y' when it asked if it was a system file. The new APK was created (called unsignedMms.apk, which I figured was correct since it said never to sign system apps).
I renamed the file to Mms.apk and used root explorer to copy it over to /system/app. However, upon reboot the app doesn't install, as if the file is not there (but it is there and has the proper permissions).
Anyway... feel like I am missing something obvious, but I'd appreciate some enlightenment.
Thanks in advance.
Well, the info seemed confusing so I tried signing it anyway... and then after pushing the signed APK and rebooting the app was installed. I thought finally it was fixed.... but no, lol.
The app FC'd instantly upon opening, even if data was wiped and permissions fixed. I restored the original so I'm fine... but I wish I knew what I was being stupid about, lol.
Never re sign a system app, don't push it either. Flash it in cwm, and if it boots and force closes run adb logcat to see what your exact error is.
Sent from my Nexus S 4G using Tapatalk
dreamsforgotten said:
Never re sign a system app, don't push it either. Flash it in cwm, and if it boots and force closes run adb logcat to see what your exact error is.
Sent from my Nexus S 4G using Tapatalk
Click to expand...
Click to collapse
Hrm... no dice. I took the unsigned APK I created and flashed it instead of pushing it and it acts as if it's not installed (the apk is in the right place with the right name and permissions).
I must be missing some fundamental step in the creation process.
Edit: This is the APK if that is useful in identifying my ignorance, lol.
Hi. I just found out that apk files are kept in the device after installation of the app.
I just recently downloaded a file explorer app and I found out that the apk files of the free games which I downloaded and installed from android market are kept in this folder:
/mnt/asec (I'm using Samsung Galaxy Ace)
There are individual folders for each game, and in each folder are a lib folder and the apk file. For example:
Fruit Ninja folder (which is found in mnt/asec folder) contains a lib folder and an apk file.
Fruit Slice folder (which is also found in mnt/asec folder) contains a lib folder and an apk file.
My question is, is it ok to delete these apk files? Will the games still work?
Also, can I send these apk files to someone else via bluetooth so they may download the apps without having to visit android market?
yeah you can delete the apk file after installing any app for it to still function, I do it all the time. Yes you can send the apk file to your friend so they can install it. If you're still cautious, try doing a trial run with one apk file...send it to your friend first, then delete, see if it works.
The .apk files are like setup files for windows. Once installed, you don't need the apk, especially if you are backing up with Titanium or similar backup program.
follow up question
Hi. Thanks guys.
Is everything from the android market ".apk"? Is it possible that some have a different extension? I downloaded a dictionary app, I can't be sure but I think it's a .zip file.
Thank you.
pakattack
I tried to delete the apk file. It cannot be deleted.
However, I copied it to my sd card, uninstalled the app, re-installed it using the one already in my sdcard, and it installed just fine.
I still want to be able to delete the apk file that is in the system though (/mnt/asec).
Any ideas or do I just have to deal with it?
sending .apk signed with another device
PakAttack1994 said:
yeah you can delete the apk file after installing any app for it to still function, I do it all the time. Yes you can send the apk file to your friend so they can install it. If you're still cautious, try doing a trial run with one apk file...send it to your friend first, then delete, see if it works.
Click to expand...
Click to collapse
I agree with deleting it won't be a problem but sending to a friend?
sometimes I think there would be a message stating that its not sign
correctly.. correct me if I'm wrong Thank You
WillShaka, like I said, I tried to delete it. I can't. Not allowed.
I don't know why. I'm using ES File explorer
not sure if this works but have you tried unmounting the sd and delete?
WillShaka said:
I agree with deleting it won't be a problem but sending to a friend?
sometimes I think there would be a message stating that its not sign
correctly.. correct me if I'm wrong Thank You
Click to expand...
Click to collapse
Also, and I don't mean to veer out of topic (this question is often ignored in Q&A forum), if I use Odin to upgrade my stock firmware instead of using Kies, will it erase all my data? I have a feeling it will...
WillShaka said:
not sure if this works but have you tried unmounting the sd and delete?
Click to expand...
Click to collapse
Just tried it. Doesn't work, but thanks for suggesting. =)
Yes, you can delete the APK after installation. But the APKs in /system/app/ need to stay where they are to function appropriately
MarlonKaye said:
Also, and I don't mean to veer out of topic (this question is often ignored in Q&A forum), if I use Odin to upgrade my stock firmware instead of using Kies, will it erase all my data? I have a feeling it will...
Click to expand...
Click to collapse
MarlonKaye said:
Just tried it. Doesn't work, but thanks for suggesting. =)
Click to expand...
Click to collapse
yes odin your phone would wipe out all the user and data status.
your welcome sorry I couldn't help
All-In-One Toolbox App
MarlonKaye said:
WillShaka, like I said, I tried to delete it. I can't. Not allowed.
I don't know why. I'm using ES File explorer
Click to expand...
Click to collapse
I use the All-In-One Toolbox app to automatically find and delete all .apk files. It also has an automatic backup and restore function for apps.
So my daragon city and messenger are in the apk files I don't know if its backed by another zip folder my tablet is the amazon fire so if I deleted the apk files that is downloaded for an android would my appe still work the same
Greetings everyone:
Yesterday, I updated to the latest Chrome on the RAZR HD MAXX with whatever the last Verizon software version is and then I used Titanium Backup to integrate into ROM so it replaced /system/app/ChromeSystemBrowser.apk with the new one, however when I open Chrome, I get the following message before Chrome just closes unexpectly:
"critical functionality required to run chrome is missing either your chrome installation is incomplete or not compatible with this version of android"
Replacing ChromeSystemBrowser.apk with either my previous version or even the one from the thread below still has the same exact error:
http://forum.xda-developers.com/showpost.php?p=33546113&postcount=10
Does anyone know how to fix this? As I already tried clearing data.
Have you tried moving Chrome back to a user app? I think I saw this on another device and had to move it back to a user app for it to work.
dbeedle said:
Have you tried moving Chrome back to a user app? I think I saw this on another device and had to move it back to a user app for it to work.
Click to expand...
Click to collapse
Already tried that but no luck, the ChromeSystemBrowser.apk in the other thread is supposed to be the stock on in /system/app although I don't know for sure if it's the right one for the latest Verizon Wireless software version of ICS or not which may be the problem. Seems like some apps will only work as a user app with the original stock/shipping version in system.
Almighty2 said:
Already tried that but no luck, the ChromeSystemBrowser.apk in the other thread is supposed to be the stock on in /system/app although I don't know for sure if it's the right one for the latest Verizon Wireless software version of ICS or not which may be the problem. Seems like some apps will only work as a user app with the original stock/shipping version in system.
Click to expand...
Click to collapse
Can someone who has the newer chrome installed in /data/app but the original Chrome that came with the ICS 4.0.4 upload their /system/app/ChromeSystemBrowser.apk file? Thanks!
Almighty2 said:
Can someone who has the newer chrome installed in /data/app but the original Chrome that came with the ICS 4.0.4 upload their /system/app/ChromeSystemBrowser.apk file? Thanks!
Click to expand...
Click to collapse
This is the one that came with Rogers ICS 4.04... might be the same. ^.^
http://dl.dropbox.com/u/38382953/ChromeSystemBrowser.apk
EdwardN said:
This is the one that came with Rogers ICS 4.04... might be the same. ^.^
http://dl.dropbox.com/u/38382953/ChromeSystemBrowser.apk
Click to expand...
Click to collapse
Thanks, the problem is not the apk as I tried your apk with the same problem so what I did was did a uninstall and then reinstalled it from Google Play so first it worked fine in /data/app before I moved it to /system/app to make sure it works again before renaming the file. So it appears for whatever reason, even after a clear data, a lot of things were missing in the /data/data/com.android.chrome folder which were needed. Strange the apk didn't install them until a uninstall/reinstall.
Chrome in system vs app folder
Almighty2 said:
Thanks, the problem is not the apk as I tried your apk with the same problem so what I did was did a uninstall and then reinstalled it from Google Play so first it worked fine in /data/app before I moved it to /system/app to make sure it works again before renaming the file. So it appears for whatever reason, even after a clear data, a lot of things were missing in the /data/data/com.android.chrome folder which were needed. Strange the apk didn't install them until a uninstall/reinstall.
Click to expand...
Click to collapse
Ok, so I'm probably a little dense - so please excuse that.
I'm having the same problem with Chrome; runs fine in the data/app folder ... but refuses to open when in the system/app folder. Tried it as a odex'd file ... as well as the apk. Did the full uninstall, reboot, reinstall thing - as well as using two separate cache deleting programs ... and it still crashes on me when in the system/app folder (but continues to run perfectly if it resides in the data/app folder).
HELP! (thanks, in advance, for your assistance)
{And while I know I could leave it in the data/app folder, I'm looking forward to the JB update from VZW, and figure it'll crash if all the right apk's aren't where they're supposed to be}
Think I found my own answer
drtrask said:
Ok, so I'm probably a little dense - so please excuse that.
I'm having the same problem with Chrome; runs fine in the data/app folder ... but refuses to open when in the system/app folder. Tried it as a odex'd file ... as well as the apk. Did the full uninstall, reboot, reinstall thing - as well as using two separate cache deleting programs ... and it still crashes on me when in the system/app folder (but continues to run perfectly if it resides in the data/app folder).
HELP! (thanks, in advance, for your assistance)
{And while I know I could leave it in the data/app folder, I'm looking forward to the JB update from VZW, and figure it'll crash if all the right apk's aren't where they're supposed to be}
Click to expand...
Click to collapse
I think I discovered a solution - that may help others. It appears that, in the system/app folder, a number of programs have BOTH an APK and an ODEX file present. I dropped the 4.0.4 Google Chrome apk into system/app, then installed the app from there. Then I moved the data/app installed version of Chrome to the system/app folder as an ODEX file (thus there's the Chrome apk AND odex file in the system/app folder). With both files present, the updated Chrome application runs as an updated system app.
odex
drtrask said:
I think I discovered a solution - that may help others. It appears that, in the system/app folder, a number of programs have BOTH an APK and an ODEX file present. I dropped the 4.0.4 Google Chrome apk into system/app, then installed the app from there. Then I moved the data/app installed version of Chrome to the system/app folder as an ODEX file (thus there's the Chrome apk AND odex file in the system/app folder). With both files present, the updated Chrome application runs as an updated system app.
Click to expand...
Click to collapse
Where did you get the two files from? the Odex and the APK i am running into an issue trying to do the update and believe this is the source of my issue? ( I uninstalled the stock chrome browser)
thank you
drtrask said:
I think I discovered a solution - that may help others. It appears that, in the system/app folder, a number of programs have BOTH an APK and an ODEX file present. I dropped the 4.0.4 Google Chrome apk into system/app, then installed the app from there. Then I moved the data/app installed version of Chrome to the system/app folder as an ODEX file (thus there's the Chrome apk AND odex file in the system/app folder). With both files present, the updated Chrome application runs as an updated system app.
Click to expand...
Click to collapse
You may be correct but what is the name of the ODEX version of the file in /system/app since I was thinking about that before but never found an odex file since I did noticed the apk's people provided as stock is less than 8MB while the Google Play version is like closer to 20MB.
Help, i would like to try and install an app from my government id, so maybe I can go to more places without both wallet and cellphone. Knowing it's a government app, I'm 100% sure it will never make it to a smartwatch...
When I tried to pull the APK from the cellphone, i saw that on the path it had the base.apk and done others, like config_xx.apk, another .apk and one like arm64.apk...
If I shall try and install it to the watch, should I do it on each one of the apks? Adb install-multiple?
Uninstall all apks on phone, isolate the necessary apk & find it's dependencies
miravision said:
Uninstall all apks on phone, isolate the necessary apk & find it's dependencies
Click to expand...
Click to collapse
So I pulled all apk files from the app to my PC and used this program from here, called SAP (Split Apk Packer).
I was able to get it all into 1 apk, but when trying to install on the watch I get an error. If I don't sign the recompiled .apk with this SAP program I get the "failure collecting certificates". If I check the Sign apk on the program, then I get another error "failed to extract native libraries", as the photo attached.
I'm not an expert at all, I just try my stuff... so if anyone has any idea if it's at all possible, I would really appreciate the help.
EDIT: apparently, this error could mean that the device is not supported, from what I read. Don't know if that's really it though