[Q] rebuild .apk after using dex2jar and jd-gui - Android Software Development

Hello,
I'm trying to learn how to edit .apk files,
So after a bit of reading I got dex2jar working, and now I can see the actual code with jd-gui.
1. How can I edit the classes that are in jd-gui?
2. How can I repack everything to a .apk file?
Thanks.

I would suggest you learn to do basic stuff with the android ask, any questions pm me and ill be glad to help. Does dex2jar realty work, think I might take a look at that.

leoon said:
Hello,
I'm trying to learn how to edit .apk files,
So after a bit of reading I got dex2jar working, and now I can see the actual code with jd-gui.
1. How can I edit the classes that are in jd-gui?
2. How can I repack everything to a .apk file?
Thanks.
Click to expand...
Click to collapse
That's impossible. Only reading, no reassembling. For editing you need to learn Smali.
Sent from my GT-I9100 using XDA App

Related

Confused about 9.png files

Ok, first sorry for posting this question, and I did search and found that the information is some what broken up and it confused me. Sorry I'm not a developer so the lingo is way far advanced.
But this is what I've gathered and done.
-I took an app that I wanted to edit. I got the images and did my PS CS4 editing to my liking and saved them.
-I did the draw9patch and manage to save them in a folder and then I put the correct names on the pngs with the 9 still at the end of the file name.
-I got lost with step no.6 of one of the threads talks about "eclipse" and thats where I'm lost.
I don't know what the heck its talking about workspace. I don't know what to do from here. Can somebody please explain it to me in laymans term. thank you.
You need to load up the sdk, eclipse is part of that.
evilkorn said:
You need to load up the sdk, eclipse is part of that.
Click to expand...
Click to collapse
I have the SDK installed but do I go to the SDK Manager or to the tools? if I go to the tools which app do I open? this is where I'm stuck at
Did you try this?
http://developer.android.com/sdk/index.html
@johnny quest: forget about that outdated method. Use apktool or ApkManager instead.
Brut.all said:
@johnny quest: forget about that outdated method. Use apktool or ApkManager instead.
Click to expand...
Click to collapse
hey brut is there a video or post relating to the steps on editing .9.png's using apkmanager or apktool? ive been looking into the draw9patch thing but everything i run into is an old post and i guess thats what you saying here. i was a total noob and now ive got down using theme porter, update.zip maker for modding stuff but ive only taken the png plunge seeing that most people are saying you gota be a pro to edit .9's and xml and all that. im fully capable of getting it im just not finding the right tutorial and info. any direction would be much appreciated
also im trying to mod my phone dialer (attached) is that something a semi-new modder can handle. eg-changing the background from black to white...the orange numbers from orange to white? just a shot in the dark you know

[Q] .xml files

Ok I'm posting this in hope that a developer will answer.
I have been trying to edit .xml files on the droid x. I'm running linux (who runs windows anyway) I have experience in c++ and scripting , but non in themeing.
I have download a bunch of xml file editors. The problem is that every time I open one with the editor I get a error saying " coding not supported ". What ia the deal here and why? Does anyone have any suggestions or ideas why?
Thank you xda
The .xml files need to be decompiled first. Otherwise, they are unreadable. The only way I know off is to decompile the entire apk file with apk manager or aapt.
Note that you have to recompile the apk (xml) before putting it back on your phone.
GL
Thank you makes sense.
B-dub25 said:
Ok I'm posting this in hope that a developer will answer.
I have been trying to edit .xml files on the droid x. I'm running linux (who runs windows anyway) I have experience in c++ and scripting , but non in themeing.
I have download a bunch of xml file editors. The problem is that every time I open one with the editor I get a error saying " coding not supported ". What ia the deal here and why? Does anyone have any suggestions or ideas why?
Thank you xda
Click to expand...
Click to collapse
Still working with this myself. You need to look on google code for smali/baksmaling, as this is what is used to compress/decompress the xml files.
Thank you systemadmin that's what I thought I had to do, decompile the. Xml file ,but just didn't now how thank you for your reply.
No worries. I have been working on trying to theme and what not myself, and it seems pretty complex at the beginning. Im trying to get some tips from like bignadad, acidbath, and some of the other big developers out here, but they are usually pretty busy and I haven't had much luck. If you start making some progress, send me a PM and share the love =)
Sent from my DROIDX using XDA App

New To theming

I am new to theming, and was just going to reach a kind hand out for some help... i can get into the framework and all but just missing some steps on how to put it all back together. any help would be appreciated, and if i am posting in the wrong location feel free to delete or move the post. thank you
Use winrar to open the framework-Res and mess with those files then just put them back in framework-Res with winrar.
Rel500 has a great themeing guide. Thats how I got started check it out and if you have any questions ill be glad to answer it for you
Hope that helped.....
Sent from my SGH-T959 using XDA App
Search for a program called "Apk Manager"
Play around with your frameworks...
Soon you'll get the hang of it...and don't be afraid to ask around
Great thread. I'm in the exact same position. Looking forward to creating MY theme.
Anyone know what program to use to view/edit the xml files?
buru898 said:
Anyone know what program to use to view/edit the xml files?
Click to expand...
Click to collapse
the apk must be de-compiled first (use Apk Manager for that)...then use Notepad++ to view/edit xml's..the re-compile using Apk Manager
Im still fairly new to the theming scene, but ive found a good place to start is by porting a theme, find a theme you like on another theme and port it to the vibrant teaches you quite a bit about theming minus creating images from scratch.
some essential apps i have found are:
gimp (for image editing)
apk manager
notepad++
of course android sdk for draw9patch and other android utilities
other programs i may be forgetting.
Ive heard cs5 and corel are really good for creating icons and the like but im a college student and dont have the cash for those kinda programs
shreddintyres said:
Im still fairly new to the theming scene, but ive found a good place to start is by porting a theme, find a theme you like on another theme and port it to the vibrant teaches you quite a bit about theming minus creating images from scratch.
some essential apps i have found are:
gimp (for image editing)
apk manager
notepad++
of course android sdk for draw9patch and other android utilities
other programs i may be forgetting.
Ive heard cs5 and corel are really good for creating icons and the like but im a college student and dont have the cash for those kinda programs
Click to expand...
Click to collapse
Neither do i
when using notepad++ I get alot of jiberish, how do I edit when the things the guides on xda tell you to search for arent in the xml code?
sorry about duplicate post but heres a pic
aamir123 said:
when using notepad++ I get alot of jiberish, how do I edit when the things the guides on xda tell you to search for arent in the xml code?
Click to expand...
Click to collapse
You need to decompile the apk using Apkmanager or apktool in order to view the xml in a readable format.
Ginger Clones of the World Unite!!! via the XDA App
aamir123 said:
when using notepad++ I get alot of jiberish, how do I edit when the things the guides on xda tell you to search for arent in the xml code?
Click to expand...
Click to collapse
You have to decompile the apk to edit the xmls.
Sent from my SGH-T959 using XDA Premium App

Editing XML wierd characters

Hello!
I'm trying to edit one of the XML's of the S Health app so hopefully I can discover some way to hide some info from the widget. However opening the said XML file in Notepad++ gives me a bunch of weird characters.. How do I procede?
testmonkey1 said:
Hello!
I'm trying to edit one of the XML's of the S Health app so hopefully I can discover some way to hide some info from the widget. However opening the said XML file in Notepad++ gives me a bunch of weird characters.. How do I procede?
Click to expand...
Click to collapse
Hi,
You cannot just pull out the file and edit it. You need to learn to decompile it first and then edit. When done, recompile. Hope this helps ?
Sent from my Nexus 7 using xda app-developers app
Jishnu Sur™ said:
Hi,
You cannot just pull out the file and edit it. You need to learn to decompile it first and then edit. When done, recompile. Hope this helps ?
Sent from my Nexus 7 using xda app-developers app
Click to expand...
Click to collapse
Ahh I thought it was the same as when replacing images, just change the file in 7z and resign the app.
How would one go àbout the most easy/fast way to decompile? I am no developer, I just want to edit out some text that is displayed on a widget by removing a couple of ljnes in the XML (I guess), nothing fancy. I don't want to be installing SDKs and what not..
testmonkey1 said:
Ahh I thought it was the same as when replacing images, just change the file in 7z and resign the app.
How would one go àbout the most easy/fast way to decompile? I am no developer, I just want to edit out some text that is displayed on a widget by removing a couple of ljnes in the XML (I guess), nothing fancy. I don't want to be installing SDKs and what not..
Click to expand...
Click to collapse
The easiest way is this mate :
1. Download tickle my android.
2. Download java applet 6U25.
3. Framework.resapk and other abc-res.apk.
4. Run tickle my android and decompile.
Sent from my Nexus 7 using xda app-developers app
Jishnu Sur™ said:
The easiest way is this mate :
1. Download tickle my android.
2. Download java applet 6U25.
3. Framework.resapk and other abc-res.apk.
4. Run tickle my android and decompile.
Sent from my Nexus 7 using xda app-developers app
Click to expand...
Click to collapse
Thanks a lot mate

Creating a modded apk

Hello everyone.
I'm trying to start to make some mods in some applications but I'm not sure where to start, mainly because i'm in Linux.
For Windows I know about dnSpy which allow us to decompile, edit, compile etc etc apk files!
Is there any applications for Linux to do the same job?
HorusEyE said:
Hello everyone.
I'm trying to start to make some mods in some applications but I'm not sure where to start, mainly because i'm in Linux.
For Windows I know about dnSpy which allow us to decompile, edit, compile etc etc apk files!
Is there any applications for Linux to do the same job?
Click to expand...
Click to collapse
APK Studio :good:
guitardedhero said:
APK Studio :good:
Click to expand...
Click to collapse
Ok, I have already that application installed, but it keeps telling me that I should have some 3rd party applications in my "vendor" folder. What applications are those? I already tried to copy into that folde "adb" and also the applications that comes with APK Tool, but it still shows the same warning. And I cannot edit dll modules with APK Studio as I can with dnSpy!
HorusEyE said:
Ok, I have already that application installed, but it keeps telling me that I should have some 3rd party applications in my "vendor" folder. What applications are those? I already tried to copy into that folde "adb" and also the applications that comes with APK Tool, but it still shows the same warning. And I cannot edit dll modules with APK Studio as I can with dnSpy!
Click to expand...
Click to collapse
I use apktool and smali/baksmali...no studio needed. It is also a good idea to have old and new versions of smali/baksmali (I use 1.3.3 and 2.1.3) because some mods you download the smali files will be in old code format. So I smali them into classes.dex with the 1.3.3 and then baksmali with 2.1.3 to convert old code to new before merging with your apk.
Sent from my SM-T210 using Tapatalk
RealWelder said:
I use apktool and smali/baksmali...no studio needed. It is also a good idea to have old and new versions of smali/baksmali (I use 1.3.3 and 2.1.3) because some mods you download the smali files will be in old code format. So I smali them into classes.dex with the 1.3.3 and then baksmali with 2.1.3 to convert old code to new before merging with your apk.
Sent from my SM-T210 using Tapatalk
Click to expand...
Click to collapse
Ok, thanks
I have downloaded version 2.2.0 of smali and baksmali and also a zip containing (i hope, smali and balsmali) version 1.3.3 of the same application! Is there any basic tutorials to teach how to start with these applications?
apktool
https://youtu.be/1t5n8rR5hTE
Smali/baksmali
https://forum.xda-developers.com/showthread.php?t=1296802
Sent from my KYOCERA-C6745 using Tapatalk
RealWelder said:
apktool
https://youtu.be/1t5n8rR5hTE
Smali/baksmali
https://forum.xda-developers.com/showthread.php?t=1296802
Sent from my KYOCERA-C6745 using Tapatalk
Click to expand...
Click to collapse
Ok, after I have decompressed/decompiled/whatever the apk file I need to edit a file that is a dll module! It has some like c# or so code. How can I edit these files, change them and compile the file again???? Some use dnSpy and when the dll file is opened, we can see a lot of code, functions and stuff. How can I do that without dnSpy because looks like there is no linux version of dnSpy.
HorusEyE said:
Ok, after I have decompressed/decompiled/whatever the apk file I need to edit a file that is a dll module! It has some like c# or so code. How can I edit these files, change them and compile the file again???? Some use dnSpy and when the dll file is opened, we can see a lot of code, functions and stuff. How can I do that without dnSpy because looks like there is no linux version of dnSpy.
Click to expand...
Click to collapse
I've never had to edit dlls. Are you trying to hack a game? Anyways, on windows I use Notepad++, but on Ubuntu I use Notepadqq.
Sent from my KYOCERA-C6745 using Tapatalk
RealWelder said:
I've never had to edit dlls. Are you trying to hack a game? Anyways, on windows I use Notepad++, but on Ubuntu I use Notepadqq.
Sent from my KYOCERA-C6745 using Tapatalk
Click to expand...
Click to collapse
Yes, I was trying to create my own modded version of a game! I usually use Atom, but I already tried to open DLL files with Atom and it doesn't work!
Do I have that Notepadqq for Debian?
HorusEyE said:
Yes, I was trying to create my own modded version of a game! I usually use Atom, but I already tried to open DLL files with Atom and it doesn't work!
Do I have that Notepadqq for Debian?
Click to expand...
Click to collapse
I`ve been trying to figure out why do you want to "create a modded apk" and according to your last post , you`re trying to bypass functionalities of an original game
This kind of thread / discussion isn`t allowed on XDA according to rule 6
6. Do not post or request warez.
If a piece of software requires you to pay to use it, then pay for it. We do not accept warez nor do we permit members to request, post, promote or describe ways in which warez, cracks, serial codes or other means of avoiding payment, can be obtained or used. This is a site of developers, i.e. the sort of people who create such software. When you cheat a software developer, you cheat us as a community.
Thanks for understanding
Thread closed

Categories

Resources