Modding APK & .XML - Sprint HTC EVO 4G LTE

i would like to learn how to mod apk's. is there a noob guide? what i want to do is be able to open a particular app from samsung with the htc album. i have tried installing the secgallery.apk and the phone doesnt see it once it is in system/app with the correct permissions.
thanks in advance!

found my answer
http://forum.xda-developers.com/showthread.php?t=1758928

Related

[Q] Signing Help ..

Hey all, Well i know we could not wait for a Honeycomb theme, i know i cannot, but heres my conundrum.
I have made a honeycomb keyboard, but cannot get it to install for the life of me, ive used the testkeys, shared, platform, etc (all using Signapktic from Stericson. Does anyone have any clue as to why it will not install?
A few questions that i know you might ask, answered ...
No, there is no other keyboard, other than swype, and samsung keypad..
I made it off of the GB keyboard...
Yes, I have made many of themes, many of changes to Frameworks, and have had sucess installing, and running my custom roms....
My question basically is this, IF POSSIBLE, CAN ANYONE SIGN THE FILES I HAVE TO MAKE THIS WORK? PM ME AND I SHALL SEND THE FILES. CREDIT WILL BE GIVIN, I AM ON THE OTHER HAND GOING TO NEED SOME SORT OF PROOF YOU KNOW WHAT YOUR DOING, I WORKED REAL HARD ON THIS, SO FOR RIGHT NOW ITS PRIVATE, HENSE THE PM.
THANKS AGAIN IN ADVANCE. REMEMBER .. LETS GET THIS HONEYTCOMB GOING
I know that most of the keyboards dont work simply by installing but rather need to be pushed to the data\app or data\app_s folder depending on which rom you are running. You can accomplish this using adb or using a file explorer like RootExplorer.
Thanks
Thank you man, this helps a whole lot. Now do i need to re-sign each apk inside the rom folder? or can i just re-sign the .zip?
georgegreco86 said:
Thank you man, this helps a whole lot. Now do i need to re-sign each apk inside the rom folder? or can i just re-sign the .zip?
Click to expand...
Click to collapse
I'm not sure what .zip you're refering to other than a CWM recovery flashable .zip for you keyboard. If this is what you mean, then use the same signiture (key) you'd find in any of the flashable .zips on the forums. In other words, just copy over the META-INF folder from some other .zip to yours. Of course, you'll want to make sure the update-script in this folder is pointing at the proper directories for installation.
For your apk, you should only need to sign it if you changed the AndroidManifest.xml. Otherwise, just keep the META-INF folder from them original apk.

noob who wants to learn

I want to learn how to theme. I've read this guide http://forum.xda-developers.com/showthread.php?t=916814
I Think i understand the process of editing images, I'm not a noob when it comes to photoshop, but i get a little frustrated when it comes to the topic of signing. I have a windows vista system, and section two of this https://docs.google.com/Doc?docid=0AcdxIJRSH9ypZGZzc2pxNDlfMjdnazk4OHNxZA&hl=en states that signing in vista causes bootloops unless you take other steps. The directions for XP seem so straight forward, is there a way to sign without all the hassle that vista seems to cause?
I've been told that if you use another theme for a base, resigning is not needed. I'm a noob at this also, really wanting to learn.
thenaut said:
I want to learn how to theme. I've read this guide http://forum.xda-developers.com/showthread.php?t=916814
I Think i understand the process of editing images, I'm not a noob when it comes to photoshop, but i get a little frustrated when it comes to the topic of signing. I have a windows vista system, and section two of this https://docs.google.com/Doc?docid=0AcdxIJRSH9ypZGZzc2pxNDlfMjdnazk4OHNxZA&hl=en states that signing in vista causes bootloops unless you take other steps. The directions for XP seem so straight forward, is there a way to sign without all the hassle that vista seems to cause?
Click to expand...
Click to collapse
When it comes to basic themeing, you don't need to sign anything....its a matter of extracting and re-zipping the apk without signing it so it keeps its original signature...then you would add all your themed apks in a CWM flashable zip(that isn't signed either).....use APK Manager....it works wonders for theme devs
Mr. Apocalypse said:
When it comes to basic themeing, you don't need to sign anything....its a matter of extracting and re-zipping the apk without signing it so it keeps its original signature...then you would add all your themed apks in a CWM flashable zip(that isn't signed either).....use APK Manager....it works wonders for theme devs
Click to expand...
Click to collapse
Thanks man,
If i'm understanding you correctly you are basically saying that if i take from an existing theme i don't have to sign. but i create my own theme based off of a rom i need to sign it?
EDIT: nevermind, i mixed both responses up and with my question. i'm a little off today
thenaut said:
Thanks man,
If i'm understanding you correctly you are basically saying that if i take from an existing theme i don't have to sign. but i create my own theme based off of a rom i need to sign it?
EDIT: nevermind, i mixed both responses up and with my question. i'm a little off today
Click to expand...
Click to collapse
Ok...let me try to clarify this...if you're new to theme developing, get "signing" out of your head
You would only need to sign an apk if it was being installed...
When you theme, nothing is being "installed", all of the original apks that are in your /system/ directory are replaced with your themed ones while flashing....
YOU NEVER SIGN AN APK THAT IS BEING SENT TO /system/ DIRECTORY
In reality, no themed apks are signed, because they are sent to the /system/ directory....its just a matter of extracting the stock apk, make your mods, and re-zip. As a said above, if you use Apk Manager, this will be a breeze
Mr. Apocalypse said:
Ok...let me try to clarify this...if you're new to theme developing, get "signing" out of your head
You would only need to sign an apk if it was being installed...
When you theme, nothing is being "installed", all of the original apks that are in your /system/ directory are replaced with your themed ones while flashing....
YOU NEVER SIGN AN APK THAT IS BEING SENT TO /system/ DIRECTORY
In reality, no themed apks are signed, because they are sent to the /system/ directory....its just a matter of extracting the stock apk, make your mods, and re-zip. As a said above, if you use Apk Manager, this will be a breeze
Click to expand...
Click to collapse
Thanks, You've helped a lot. can't wait to start. I have to go to work though, so tomorrow, hopefully.
thenaut said:
Thanks, You've helped a lot. can't wait to start. I have to go to work though, so tomorrow, hopefully.
Click to expand...
Click to collapse
If you have any other questions, PM me....i'm always willing to help someone who is willing to learn.
What I do when i want to change something... example I made my own lock screen.
If it was already explained how to do this... im sorry for wasting your and mine time... I only have about 5 minutes so I cant read everything before i post this... but this is what i do when i want to edit the theme.
I put the rom on my computer and extract it... locate the files I need to edit, (they are alwas going to be in the res folder of an extracted .apk and then in a drawable folder.) I take the files i want and I edit them. put them back on my phone... copy the framework-res.apk from systems>framework>framework-res.apk and then put it in a folder i created on my sdcard.
Using Astro File Manager I select my edited files and copy them.... then click on framework-res.apk and select browse and past my edited files into the framework-res.apk then using root explorer I then copy my edited framework-res.apk and paste it back in system>framework>framework-res.apk

Help with skins

If I want to use the rosie from one skin, and the lockring from another, etc., do I have to decompile all the apk's or can I just move these things around with a file explorer? Also when I tried to decompile the base skin from here http://forum.xda-developers.com/showthread.php?t=1144572 I get a bunch of errors?? I was using apk manager and honestly don't know wtf I'm doing, but I wanted to try. I haven't found a noobish enough tutorial for this stuff. Any help/ advice would be greatly appreciated.
You can usually move the .pngs around however you want without using any apk manager. Just use 7zip on a PC or Springy on a Mac, and open the apk without extracting it. Resign it after editing, install, and you should be good to go.

[Q] PinyinMe to normal APK, English only and AZERTY

So there is this PinyinMe keyboard which looks the most like an iphone keyboard which I like as my phone is an iPhone Replica.
1. So the things I want to do is change the APK to a normal APK but I only know the way by TitaniumBackup but this app aint installed so it doesnt work.
2. The next thing I want to do is edit the APK xml files so I can remove all the chinese signs in it and change it to normal letters (mainly english).
- I already tried this but the APK wont install
3. If this is all working, I would like to make a second version of it which has AZERTY keyboard instead of QWERTY.
Please, I would really apreciate it and others too.
bOyka8 said:
So there is this PinyinMe keyboard which looks the most like an iphone keyboard which I like as my phone is an iPhone Replica.
1. So the things I want to do is change the APK to a normal APK but I only know the way by TitaniumBackup but this app aint installed so it doesnt work.
2. The next thing I want to do is edit the APK xml files so I can remove all the chinese signs in it and change it to normal letters (mainly english).
- I already tried this but the APK wont install
3. If this is all working, I would like to make a second version of it which has AZERTY keyboard instead of QWERTY.
Please, I would really apreciate it and others too.
Click to expand...
Click to collapse
Here's the APK and OBEX which I forgot to add
http://www.mediafire.com/?216cm8rcgi2z5m8
I really hope someone can help me out with this !
Ok so in this ZIP file is the original APK that you can just install and use. Also the one I edited which gives App not installed.
Can anyone look into this please??
http://www.mediafire.com/?216cm8rcgi2z5m8
bOyka8 said:
Ok so in this ZIP file is the original APK that you can just install and use. Also the one I edited which gives App not installed.
Can anyone look into this please??
http://www.mediafire.com/?216cm8rcgi2z5m8
Click to expand...
Click to collapse
You have two files in the zip. One is an .apk and the other is an .odex file.
I saw this thread as I was browsing around and came across your GooApple thread.
I am not sure what your level of expertise is, but basically, an apk from a manufacturer comes in two parts (.apk and .odex). If you want to edit the app, you must either edit both the .apk and .odex files, or you can 'deodex' the file which basically takes the contents of the .odex file and places it inside the .apk file.
If you have deodexed an apk file (removed the need for the .odex), you no longer need the .odex file. In this way, you get 'deodexed' ROMs with no .odex files inside. These are much easier to edit and work with.
There are lots of tutorials to find out more about this and about deodexing and editing .apk files if you search.
Here is a good starting point
If you are already aware of this, I apologise
nobnut said:
You have two files in the zip. One is an .apk and the other is an .odex file.
I saw this thread as I was browsing around and came across your GooApple thread.
I am not sure what your level of expertise is, but basically, an apk from a manufacturer comes in two parts (.apk and .odex). If you want to edit the app, you must either edit both the .apk and .odex files, or you can 'deodex' the file which basically takes the contents of the .odex file and places it inside the .apk file.
If you have deodexed an apk file (removed the need for the .odex), you no longer need the .odex file. In this way, you get 'deodexed' ROMs with no .odex files inside. These are much easier to edit and work with.
There are lots of tutorials to find out more about this and about deodexing and editing .apk files if you search.
Here is a good starting point
If you are already aware of this, I apologise
Click to expand...
Click to collapse
Hey man, thanks for giving me this information.
I did read about deodexing but havent had the time to look it up. And I think TBP does the deodex (I could be wrong) when changing the system app to a user app.
Anyways, I have been able to edit the xml & png's, but whenever I try to install the newly created APK, I get the error : App not installed.
Maybe this deodexing can do the trick, I'll test it out once I find 30min of free time ^^
Titanium backup doesn't deodex the .apk. That is why you are having the issue. You can swap pngs etc without decompiling, but to edit smali and some xmls etc you have to decompile... it is much easier if you have first deodexed your apk to remove the .odex file.
nobnut said:
Titanium backup doesn't deodex the .apk. That is why you are having the issue. You can swap pngs etc without decompiling, but to edit smali and some xmls etc you have to decompile... it is much easier if you have first deodexed your apk to remove the .odex file.
Click to expand...
Click to collapse
I did recompile a working APK, but when I put it all back together and try as a system/normal app and do zipalign or no zipalign, I always get an error or just a crash. But probably deodexing will do the trick.
Hopefully I'll get some time this week for doing it cause its like:
Wake up - Eat - Job - Eat - Sleep - Eat - Soccer - Eat - Sleep
The life of a mailman

Editing Settings.apk - Signing possible or custom ROM needed?

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

Categories

Resources