How to resign apk files after modding them!

Discussion in 'Android Hacks and Help' started by sportsterBK8, Mar 4, 2010.

  1. sportsterBK8

    sportsterBK8 Member

    Joined:
    Feb 12, 2010
    Messages:
    60
    Likes Received:
    0
    Trophy Points:
    6
    Location:
    Fargo
    Ratings:
    +0
    Okay, so I hope this is in the right area on this forum, because it MIGHT belong in themes depending on how people use this info... Mods, feel free to move it, or put it in both areas.

    But I have searched high and low, and haven't found any threads here on how to sign an apk, so that you can install it again after modding it. This is necissary to skip a ton of terminal or adb code.

    SO HERE IT IS!

    xda-developers - View Single Post - [HOW TO] Manuals for creating a theme

    That thread at xda should get people here set up for modding apk themes, or apk files etc. then just resign them so they are installable again.

    THIS SHOULD MAKE USING FORUM HACKS MUCH EASIER FOR NOOBS!

    GOOD LUCK EVERYONE, let me know how it goes. and share some of your work with me ;] I love beta testing!
     
  2. cplus

    cplus Member

    Joined:
    Dec 24, 2009
    Messages:
    234
    Likes Received:
    0
    Trophy Points:
    16
    Ratings:
    +0
    Ok, here is another way.

    Here is another thread from xda. I found this one easier to use than the one you posted.

    Editing APKs to match themes (Not just app icons!) - xda-developers

    Get mixpix405's modified signing tool half way down on the first post.

    Make sure you install JDK and JRE before hand. IF YOU USE x64 WINDOWS YOU WILL NEED x64 JDK/JRE otherwise you will get errors.


    I just resigned a themed audimanager widget apk and installed. YAY!!
     
  3. jtydroid

    jtydroid Member

    Joined:
    Apr 25, 2010
    Messages:
    123
    Likes Received:
    0
    Trophy Points:
    16
    Location:
    Milwaukee, WI
    Ratings:
    +0
    So... what's the general feeling on editing people signed packages?

    If I want to change a logo in Helixlauncher, or change the look of the Jorte calendar, should I approach those folks for their permission first?

    I am not intending to distribute, of course, but I am still curious. I like our Android devs and don't want to run afoul of their hard work and good intentions.
     
  4. Big Lou

    Big Lou Member

    Joined:
    Dec 3, 2009
    Messages:
    733
    Likes Received:
    0
    Trophy Points:
    16
    Ratings:
    +0
    Isn't this only for apps that are in the /system/app folder?
     
  5. jtydroid

    jtydroid Member

    Joined:
    Apr 25, 2010
    Messages:
    123
    Likes Received:
    0
    Trophy Points:
    16
    Location:
    Milwaukee, WI
    Ratings:
    +0
    Hrm, I dont know. I was able to edit Settings.apk without resigning, I thought it was market apps that had to be resigned...

    Are you saying it's Market apps in the /system/app folder?

    (Sorry, I'm still sortof clueless, just working my way through all this stuff)
     
  6. cplus

    cplus Member

    Joined:
    Dec 24, 2009
    Messages:
    234
    Likes Received:
    0
    Trophy Points:
    16
    Ratings:
    +0

    Yeah I think its market apps that need resigned. All I wanted was a custom colored Audiomanager Widget and now I have it and LOVE it. I hope this is legal and does not hurt anyone's feeling.
     
  7. jtydroid

    jtydroid Member

    Joined:
    Apr 25, 2010
    Messages:
    123
    Likes Received:
    0
    Trophy Points:
    16
    Location:
    Milwaukee, WI
    Ratings:
    +0
    Well, seeing as he allows for skinning of his app, I doubt he'll have an overly large problem with it.

    That said, any updates will undo your changes, right?

    He's said he'll have full skin-creation support soon, I'm excited for that because then I wont have to re-push the image files with each update.

    Next up, restructuring the powercontrol widget to a different form-factor...
     
  8. pyro6128

    pyro6128 Senior Member

    Joined:
    Jan 5, 2010
    Messages:
    1,517
    Likes Received:
    8
    Trophy Points:
    68
    Location:
    NYC
    Ratings:
    +8
    can't you make it a zip file, then use winrar to copy out the files you need, then replace them when you're done? I think that stops you from breaking the signature. I seem to remember doing this when I was doing the replacing verizon wireless hack.
     
  9. jtydroid

    jtydroid Member

    Joined:
    Apr 25, 2010
    Messages:
    123
    Likes Received:
    0
    Trophy Points:
    16
    Location:
    Milwaukee, WI
    Ratings:
    +0
    Honestly, I don't know the answer to this. I just learned about signing because it seemed important to do.
     
  10. kevdog

    kevdog Member

    Joined:
    Nov 14, 2009
    Messages:
    722
    Likes Received:
    0
    Trophy Points:
    16
    Ratings:
    +0
    Yes the WinRar, 7zip trick usually works without breaking signatures, but you can also resign them as well. Two ways to skin the same cat -- although I find the WinRar trick much easier myself unless an update.zip needs to be made.
     
  11. jasonb

    jasonb Active Member

    Joined:
    Dec 6, 2009
    Messages:
    1,151
    Likes Received:
    0
    Trophy Points:
    36
    Ratings:
    +0
    i tried both methods and astro still won't let me install a modified apk. what am i doing wrong? i really want a smoked glass feedr widget.
     
  12. actngrezy

    actngrezy Active Member Developer

    Joined:
    Mar 21, 2010
    Messages:
    1,074
    Likes Received:
    2
    Trophy Points:
    38
    Location:
    delaware
    Ratings:
    +2
    The one autpsign tool says you cant use ti with vista or windows 7 or it will make you phoen go itno bootloops when you install the file. I was going to try and swap out icons for a few things but pulling the apk then open it with winrar witout extracting it then putting new icon image in then closeing and pushing back to phoen will this work or do I need to sign it???
     
  13. DF Smod

    DF Smod Silver Member

    Joined:
    Apr 23, 2010
    Messages:
    11,457
    Likes Received:
    92
    Trophy Points:
    163
    Ratings:
    +92
    Could you explain this "trick" in a little bit more detail, I have WinWar and am trying to customize the Audio Widget but am having difficulties getting the .apk resigned or pulling files without breaking a signature

    thanks in advance

    Sent From My Laptop Thru Time and Space
     
  14. kevdog

    kevdog Member

    Joined:
    Nov 14, 2009
    Messages:
    722
    Likes Received:
    0
    Trophy Points:
    16
    Ratings:
    +0
    I could help you a lot more if I knew what you were exactly doing, but I'll give you a brief idea how I make use of this trick.

    Make 3 copies of the apk you are trying to add to
    #1 - Backup copy -- keep in safe place in case of breakage
    #2 - Working Copy -- one you will extract and unzip to get to the files you want to alter
    #3 - Copy to be placed back onto the Device when you are done -- open in WinRar or 7zip and navigate to directory(directories) of things you want to replace -- do not extract this copy. Keep zipped

    Make your changes with the #2 copy or just come up with new files. Of the files you want to change, you must rename the file names to the exact name of the old files -- you can not just throw in some random files with random file names and expect them to work

    An example -- say you want to change one of the images within the drawable_hdpi folder -- make your changes to the .png file (.png.7 files are different). Make sure the name you are saving the file as is the same as the original.

    Now within Windows Explorer (or comparable), simply drop and drag this file into its appropriate directory within 7zip. You can do this multiple times.

    Once done, push copy #3 back to the device using adb or whatever means.
    You should be good to go. Because you simply replaced files within the zip or apk file, the signature was not broken. It only needs to be resigned if you attempted to zip it back up and then install it on the device. This process requires to zip and then resign if doing it via the other method.

    I hope this was clear???
     
  15. Jim 777

    Jim 777 Silver Member

    Joined:
    Dec 26, 2009
    Messages:
    2,270
    Likes Received:
    2
    Trophy Points:
    103
    Ratings:
    +2
    I
    m not sure if it was stated, I didn't see it, but the signature is only needed when placing apks in the /data/app folder. The /system/app folder doesn't require it.

    I just copy the apk file from the data/app folder and get it on the pc. Then use 7zip to get to the pngs I want to change, inset them, close it up and put on the root of the sdcard. I then put the edited apk in the /system/app folder (remember it came from the /data/app folder) and set the permissions. Exit out and sync the two via the Terminal Emulator and reboot. Viola!

    Did the audio manager, 'settings, pandora, youtube, music, facebook, miniinfo, and setcpu widgets in my sig picture.

    No signatures necessary. Had to find a way as I didn't like downloading over a 1GB of files for SDK only to have it not even open correctly for me.
     
Search tags for this page
apk resign
,
how to resign apk
,
how to resign apk files
,
how to sign an apk
,

how to sign apk

,
how to sign apk file
,
how to sign apk files
,

resign apk

,

sign apk

,
sign apk file