yashsingh1/xdaforums huggingface dataset:
[Android Software Development] Ticklefish:
Are you still having trouble with this?

If apktool isn't loading your second framework, it'll be because the tool doesn't think it's needed. Which may mean you need a different second framework instead.

This post looks practically identical to one a few posts before. Did you mean to quote it?

I never had the pleasure of gingerbread. My first phone was on Froyo, my second was on ICS. Which was a mind-blowing leap in quality and style.

But Gingerbread has always had this mystical allure about it to me. It was the one that got away..

Anyway..framework dex files are now either in boot.oat or boot-framework*.vdex.

In case anybody needed to know.
[Android Software Development] kimoVoid:
It works fine now, I had to force the use of the second framework and now I can decompile the app without errors :)
[Android Software Development] Svan987:
Hi everybody,

Trying to decompile a deodexed Samsung Nougat 7.0 "SystemUI.apk". I use a custom framework firectory "FW". The only frameworks .apk in the firmware : framework-res.apk + samsung-framework-res.apk

Installed both in my custom "FW" directory.

Nothing modified :

C:\Users\Svan\Documents\apktool>apktool d SystemUI.apk -p FW
I: Using Apktool 2.3.4 on SystemUI.apk
I: Loading resource table...
I: Decoding AndroidManifest.xml with resources...
I: Loading resource table from file: FW\1.apk
I: Regular manifest package...
I: Decoding file-resources...
I: Decoding values */* XMLs...
I: Baksmaling classes.dex...
I: Copying assets and libs...
I: Copying unknown files...
I: Copying original files...

C:\Users\Svan\Documents\apktool>apktool b SystemUI -p FW
I: Using Apktool 2.3.4
I: Checking whether sources has changed...
I: Smaling smali folder into classes.dex...
I: Checking whether resources has changed...
I: Building resources...
W: warning: string 'kg_keycode_enter' has no default translation.
W: warning: string 'screenshot_failed_to_capture_text' has no default translation.
W: warning: string 'screenshot_failed_to_save_text' has no default translation.
W: warning: string 'screenshot_failed_to_save_unknown_text' has no default translation.
I: Building apk file...
I: Copying unknown files/dir...
I: Built apk...

With one smali file modified :

C:\Users\Svan\Documents\apktool>apktool d SystemUI.apk -p FW
I: Using Apktool 2.3.4 on SystemUI.apk
I: Loading resource table...
I: Decoding AndroidManifest.xml with resources...
I: Loading resource table from file: FW\1.apk
I: Regular manifest package...
I: Decoding file-resources...
I: Decoding values */* XMLs...
I: Baksmaling classes.dex...
I: Copying assets and libs...
I: Copying unknown files...
I: Copying original files...

C:\Users\Svan\Documents\apktool>apktool b SystemUI -p FW
I: Using Apktool 2.3.4
I: Checking whether sources has changed...
I: Smaling smali folder into classes.dex...
I: Checking whether resources has changed...
I: Building resources...
W: fakeLogOpen(/dev/log_system) failed
W: fakeLogOpen(/dev/log_crash) failed
W: fakeLogOpen(/dev/log_system) failed
W: fakeLogOpen(/dev/log_crash) failed
W: fakeLogOpen(/dev/log_crash) failed
W: fakeLogOpen(/dev/log_stats) failed
W: fakeLogOpen(/dev/log_stats) failed
W: fakeLogOpen(/dev/log_stats) failed
W: warning: string 'kg_keycode_enter' has no default translation.
W: warning: string 'screenshot_failed_to_capture_text' has no default translation.
W: warning: string 'screenshot_failed_to_save_text' has no default translation.
W: warning: string 'screenshot_failed_to_save_unknown_text' has no default translation.
I: Building apk file...
I: Copying unknown files/dir...
I: Built apk...

I know that the "no default translation" warning errors are nothing to care but what about the "fakeLogOpen" ones ?

Thanx for your help in advance ;)

Update : I just tested the patched "SystemUI.apk" it's working
[Android Software Development] Ticklefish:
You can normally ignore most warnings as they won't stop the app from recompiling. Just be aware of them if it won't work when you put it back to your phone.
[Android Software Development] tsoump:
Install modified .apk

Hello,

I'm trying to modify and install a system app through APKtool (stock Oreo 8.0) or APK Easy tool (windows 10) and the result is "App not installed". The application is MotoDisplay.apk and I'm editing a new released update of this. I have to say that I used root browser and found the application inside the file priv-app but I'm unrooted. I think that my main problem is the signatures of the developer, though.

What is the right way of decompiling and compiling an .apk but keeping the original signature?

Is there any other way of installing my moded .apk ?

Thanks
[Android Software Development] Ibuprophen:
There could be a number of reasons for what you're experiencing.

Your best bet is to go to the following link for further how-to guidance...

https://ibotpeaches.github.io/Apktool/documentation/

... and go to the following link to locate an answer to or report any issues your experiencing.

https://github.com/iBotPeaches/Apktool/issues

Good Luck!

~~~~~~~~~~~~~~~

UNLESS asked to do so, PLEASE don't PM me regarding support. Sent using The ClaRetoX Forum App on my SM-G900T device.
[Android Software Development] Thebear j koss:
Need root to install a system app. Would need to delete existing apk out of priv app and put in new 1 or flash new 1 over existing. Need root permissions either way

Sent from my PH-1 using Thebear Blue XDA Labs
[Android Software Development] tsoump:
!

I have ended up to that conlusion... You' re right. Because I modified other apps with APKtool from my smartphone and before I installed the app I completeley remove the previous version and voila! So, I have to find a way to completely remove or replace the system's .apk without rooting, because I don't wanna lose the warranty. :(

Is there any way of doing this?

But, I need to say that I can install on this system's .apk other original versions. So, the problem might be to the developer specific signature. Any way to bypass it or to keep the original signature?

Thank you!
[Android Software Development] levone1:
Baksmali deodex question

Anybody know - Smali decoded instructions page says .art now supported, but when I attempt to deodex, I get same old message: "... Is not an odex, apk or oat file". Need a special command or something?

I'm using the newest version on the download page.

Thanks
[Android Software Development] Thebear j koss:
Yes it is due to signature. Again you need root, but you can disable signature verification

Sent from my PH-1 using Thebear Blue XDA Labs
[Android Software Development] tsoump:
Is it possible to change the signature verification to a system .apk and still work? (root as well..?)
[Android Software Development] S3V3N:
[MENTION=3924617]iBotPeaches[/MENTION]

https://github.com/iBotPeaches/Apktool/issues/1942

use apktool 2.3.4

framework-res in Motorola Moto Z3 Play - Android 8.1

framework : https://www47.zippyshare.com/v/ZeMFipmU/file.html
[Android Software Development] djdarkknight96:
No you need root to replace system apps no other way...

Edit: there is one way without root see bellow post
[Android Software Development] Svan987:
Thanx for your reply ;)

The minimum required is TWRP recovery and a deodexed rom.

When you modify an ".apk" you breaking the signature and you will need the developer's private key to sign it.

If it's not working without Signature spoofing you can use "NanoDroid patcher" to patch "services.jar" (Backup first your "services.jar" file in TWRP) Google search "NanoDroid xda forums".

Check this link for infos : Application Signature Verification

Without root you can copy the app in TWRP : mount "System partition" and go to "Advanced" - "File manager"

Set permissions "chmod" to 0644 for the "MotoDisplay.apk" and 0755 for the directory.
[Android Software Development] djdarkknight96:
I keep forgetting we actually have root access in recovery. Been that long since I've had no root with twrp installed. Making a flash-able zip would be more efficient and you can set permissions in the updater script.
[Android Software Development] tsoump:
Too much info! :eek: I have a lot to read!

So, as a coclusion, is there a way to install/replace a system application without root? (I'm in stock Oreo 8.0 - Moto Z)

I ask this because I need to get clear in my mind. Is there any guide for this?

Thank you very much, you give me hope! :D
[Android Software Development] Ticklefish:
If you have TWRP installed, yes. But you'll need to unlock your bootloader to install TWRP and, if you're doing that, you might as well root your phone. There's a thread about doing that here: https://xdaforums.com/moto-z/help/oreo-stock-root-t3768113

Normally, if you don't have root, you don't have writable access to the files at the root of your device (which is essentially what rooting means).

Any system APK or JAR file you modify will need to have the same signature, or key, as the original or Android will reject it even if you are rooted.

But you can disable signature verification by modifying one of your JAR files. Your rom will need to be deodexed for that.

Disabling signature verification does make it easier for malware to install itself but that just means you need to be careful about what you're installing. Which you should be, anyway.
[Android Software Development] djdarkknight96:
You can replace system apps with different signature, no need to kill the signature validation at all. Once on system it will be ignored...even test keys work on system bro.
[Android Software Development] Pain-N-Panic:
Usually I just copy the manifest and resources.arsc to my newly compiled apk and push it to system. Haven't done it in a while though..this still work?
[Android Software Development] djdarkknight96:
Yep or push changed built files to untouched apk
[Android Software Development] Pain-N-Panic:
Speaking of this, I'm about to modify my systemUI. If I go into boot loop is there a way I can push my stock systemUI back to the system partition through fastboot? Since I'll be in bootloop I won't have access to ADB to push it back. My op6t also doesn't have a functional TWRP to make a backup.
[Android Software Development] djdarkknight96:
I would never mess with system without recovery. No you can't use fastboot to restore apps without full image.
[Android Software Development] Pain-N-Panic:
Heck. I have a bootable version of TWRP but it can't decrypt. It does have the "ADB sideload" feature. Could I use that to restore stock systemUI?
[Android Software Development] Pain-N-Panic:
I'm getting massive .9pmg compile error on Android 9.0 running the latest OOS build for the op6t. Any work around? Can't find anything on the web
[Android Software Development] Thebear j koss:
What is the error? Probably been fixed in this thread numerous times.

Sent from my PH-1 using Thebear Blue XDA Labs
[Android Software Development] Pain-N-Panic:
Bunch of .9 png compile errors
[Android Software Development] Spannaa:
It'll tell you what needs fixing in the error log.

Post the relevant lines here...
[Android Software Development] Thebear j koss:
It is most likely 1- 9 png that is malformed. The rest is usually just extras...

Sent from my PH-1 using Thebear Blue XDA Labs
[Android Software Development] Ibuprophen:
[MENTION=5188663]Pain-N-Panic[/MENTION], this is a known bug that has been reported on a number of occasions to [MENTION=3924617]iBotPeaches[/MENTION] within his Github Apktool Repo.

Instead of providing a number of separate links, the following link is a search within the Apktool Issues Repo of iBotPeaches that will reflect more than one that, I believe, will also reflect your specific issue.

https://www.github.com/iBotPeaches/Apktool/issues?q=is:issue+is:open+9+png+compile

I've seen a few workarounds that seemed to have worked for some but, not all.

EDIT: I almost forgotten to provide the following thread that might be helpful for you as well. I'm not sure if it applies to you or not but, I had just remembered seeing it before.

https://xdaforums.com/showthread.php?t=2326393

Good Luck! :)

~~~~~~~~~~~~~~~

UNLESS asked to do so, PLEASE don't PM me regarding support. Sent using The ClaRetoX Forum App on my Tandy TRS-80.
[Android Software Development] Svan987:
Thanx for this info. Passed modified "SystemUI.apk" without signature proof :good:
[Android Software Development] Pain-N-Panic:
I'll post it later tonight when I'm back on my PC. This is also my first OnePlus device (only used Google phones the past five years). I noticed there's a separate framework file called oneplus-framework-res.apk which I did not install. I'll install that one as well and see what happens.
[Android Software Development] Pain-N-Panic:
Thanks for the resources [MENTION=1803258]ibu[/MENTION]profen! I'll do some reading :)
[Android Software Development] Pain-N-Panic:
Thanks again [MENTION=4828250]Ibuprophen[/MENTION]! With the research you provided I was successfully able to recompile and change the fingerprint icon to my 6t.
[Android Software Development] Ibuprophen:
I'm glad it worked out for you! :)

Happy Modding! :eek:

~~~~~~~~~~~~~~~

UNLESS asked to do so, PLEASE don't PM me regarding support. Sent using The ClaRetoX Forum App on my Tandy TRS-80.
[Android Software Development] bobfrantic:
I am trying to recompile the framework-res from the Android Pie beta that is on my S9+. I get the following error and have no idea what it is. Anyone who can help please, I am stumped.

[C:\Users\John\AppData\Local\Temp\brut_util_Jar_1628709967963961646.tmp, p, --forced-package-id, 1, --min-sdk-version, 28, --target-sdk-version, 28, --version-code, 28, --version-name, 9, --no-version-vectors, -F, C:\Users\John\AppData\Local\Temp\APKTOOL4902017706286751044.tmp, -x, -0, arsc, -0, arsc, -S, C:\android\apktool2\framework-res\res, -M, C:\android\apktool2\framework-res\AndroidManifest.xml]
[Android Software Development] Ibuprophen:
I can only recommend that you Search/Report this within the following Apktool Github Issues area.

https://github.com/iBotPeaches/Apktool/issues

I did locate the following issues that looks like/similar to your issue as well.

https://github.com/iBotPeaches/Apktool/issues/1853

https://github.com/iBotPeaches/Apktool/issues/1875

https://github.com/iBotPeaches/Apktool/issues/1888

Good Luck! :)

~~~~~~~~~~~~~~~

UNLESS asked to do so, PLEASE don't PM me regarding support. Sent using The ClaRetoX Forum App on my Tandy TRS-80.
[Android Software Development] MEYSAMKIA:
Hi

use this apktool

http://www.mediafire.com/file/9s4j5sgs28a4niz/Apktool_by_Meysam_KiA.zip/file

and

rename "pip_dismiss_scrim.9.png" to "pip_dismiss_scrim.png"

---------- Post added at 02:50 AM ---------- Previous post was at 02:48 AM ----------

http://www.mediafire.com/file/9s4j5sgs28a4niz/Apktool_by_Meysam_KiA.zip/file

---------- Post added at 02:52 AM ---------- Previous post was at 02:50 AM ----------

Hi

use this apktool

http://www.mediafire.com/file/9s4j5sgs28a4niz/Apktool_by_Meysam_KiA.zip/file

and

rename "pip_dismiss_scrim.9.png" to "pip_dismiss_scrim.png"

:cool:

---------- Post added at 02:53 AM ---------- Previous post was at 02:52 AM ----------

http://www.mediafire.com/file/9s4j5sgs28a4niz/Apktool_by_Meysam_KiA.zip/file
[Android Software Development] Ticklefish:
I understand that you want people to use something you've put together and that's very helpful of you.

But you're replying to posts made over a year ago and your solution would not have helped either.
[Android Software Development] djdarkknight96:
Afaik Samsung apk's have not been able to compile for a long time. They use their own resources to build we don't have access to.
[Android Software Development] bobfrantic:
I've been trying to find a download for aapt2.exe, which from what I've read helps.
[Android Software Development] Ibuprophen:
You should be able to obtain a copy of it from the following link.

https://developer.android.com/studio/command-line/aapt2

It provides the download options for AAPT2.exe...

Enjoy! :)

~~~~~~~~~~~~~~~

UNLESS asked to do so, PLEASE don't PM me regarding support. Sent using The ClaRetoX Forum App on my Tandy TRS-80.
[Android Software Development] Ticklefish:
Have you tried using apktool with the option of using aapt2? I find that some new APK's will only recompile with that option enabled.
[Android Software Development] bobfrantic:
I'd love to but I can't get aapt2 anywhere, yet... lol

ok got the aapt2 thanks to Ibuprophen, but still getting same error...
[Android Software Development] Ibuprophen:
[MENTION=2855249]bobfrantic[/MENTION], I just wanted to add to what [MENTION=4315551]Ticklefish[/MENTION] has stated along with a slight clarification to my last post.

AAPT1/AAPT2 is integrated within Apktool but, it does require the individual to specify which one to specifically use in many/most cases.

The following are links that should be very helpful.

https://ibotpeaches.github.io/Apktool/documentation/

https://connortumbleson.com/2018/02/18/taking-a-look-at-aapt2/

https://github.com/iBotPeaches/Apktool/blob/master/INTERNAL.md

Also, if you are having issues regarding this, your more likely to receive a quicker response from [MENTION=3924617]iBotPeaches[/MENTION] via a submitted issue in Github than here since iBotPeaches is present there much more often than his periodic appearance on the XDA Forum.

Good Luck! :)

~~~~~~~~~~~~~~~

UNLESS asked to do so, PLEASE don't PM me regarding support. Sent using The ClaRetoX Forum App on my Tandy TRS-80.
[Android Software Development] levone1:
If anyone's interested... Maybe old news to some, but breakthrough for me.

https://xdaforums.com/android/general/apktool-command-line-android-t3874677
[Android Software Development] Hamidreza2010:
[MENTION=3924617]iBotPeaches[/MENTION]

Hi bro

bro i downloaded a Apk and wanted to edit it but get error

for test , i decompile and recompile it without any edit but get same error.

I: Using Apktool 2.3.4
I: Smaling smali folder into classes.dex...
I: Smaling smali_assets folder into assets.dex...
..\_WorkArea1\_working\yes.apk\smali_assets\devoptions\devoptions2\com\instagram\analytics\eventlog\EventLogListFragment.smali[18,16] Class Lcom/instagram/analytics/eventlog/EventLogListFragment; has already been interned
Could not smali file: devoptions/devoptions2/com/instagram/analytics/eventlog/EventLogListFragment.smali

here is my history and recompile and decompile logs.

would you please help me here?
[Android Software Development] Thebear j koss:
Instagram has issues....

Sent from my PH-1 using Thebear Blue XDA Labs
[Android Software Development] Eleo:
As mentioned here:

https://xdaforums.com/showthread.php?t=1633333&p=78214682

Changing instagram apk name to yes.apk is only deceiving developers and people who are trying to help you. Please do not deceive us and tell us whole story!
[Android Software Development] Hamidreza2010:
I dont think so

because i saw some people moded this apk

its unoffical apk

bro the apk name wasnt important

i always rename any apk which want to edit to YES.APK

if you can help me , if not please dont mention me for unimportant thing
[Android Software Development] Spannaa:
So maybe ask them how they did it?
[Android Software Development] Eleo:
R..U .D..E
[Android Software Development] Ibuprophen:
Patience is a virtue...

~~~~~~~~~~~~~~~

UNLESS asked to do so, PLEASE don't PM me regarding support. Sent using The ClaRetoX Forum App on my Commodore VIC-20.
[Android Software Development] Hamidreza2010:
I did it but he dont want to tell me
[Android Software Development] Thebear j koss:
Download the original apk and diff out the changes between the 2.

Sent from my PH-1 using Thebear Blue XDA Labs
[Android Software Development] Hamidreza2010:
I cant.because its an unofficial Apk and i want to edit this one ( its many diff from orginal )

Here you are bro

would you please test it and let me know?

https://dl.farazapps.com/apps/ir/android/instaroyal-100986906.apk

thanks
[Android Software Development] Ibuprophen:
Are you ultimately looking to...

Change/Modify just the name/label of the app?

~OR~

Sever it from the Google Play Store?

~~~~~~~~~~~~~~~

UNLESS asked to do so, PLEASE don't PM me regarding support. Sent using The ClaRetoX Forum App on my Commodore VIC-20.
[Android Software Development] Hamidreza2010:
No, i didnt edit anything.

this app didnt release on google play store
[Android Software Development] Ibuprophen:
I see it here...

https://play.google.com/store/apps/details?id=info.greensoft.ig

~~~~~~~~~~~~~~~

UNLESS asked to do so, PLEASE don't PM me regarding support. Sent using The ClaRetoX Forum App on my Commodore VIC-20.
[Android Software Development] Hamidreza2010:
Yes thats true

thanks a lot

I try it but get same error

would you please download it and try to de/recompile it and see whats error?

Special thanks bro
[Android Software Development] Ibuprophen:
I can't read the default language (it looks Arabic) and I don't (HONESTLY) have the time to look that deep into it.

Maybe you should try to obtain some support and guidance from the developers contact information via the Play Store.

My Apologies but, I do wish you the best of luck with this app.

~~~~~~~~~~~~~~~

UNLESS asked to do so, PLEASE don't PM me regarding support. Sent using The ClaRetoX Forum App on my Commodore VIC-20.
[Android Software Development] Spannaa:
Tried with your original linked apk and got the same 'already been interned' error as you when building with no changes after decoding which suggests nested smali/java.

Delete the devoptions2 folder and it builds but probably still won't work.
[Android Software Development] Thebear j koss:
After building the apk, replace the classes dex file with original classes dex file from original apk.

Sent from my PH-1 using Thebear Blue XDA Labs
[Android Software Development] Spannaa:
It's a multidex apk so I guess replacing classes.dex, classes2.dex, classes3.dex & assets.dex would be necessary.

Probably easier to just drop the edited resources from the new apk into the original
[Android Software Development] Thebear j koss:
Yeah, just replace any changes made from new into original.

Sent from my PH-1 using Thebear Blue XDA Labs
[Android Software Development] Hamidreza2010:
Thanks bro

Hope i understand good

i will try it

thanks all dears
[Android Software Development] DoR3M3:
A system apk that I am trying to edit that OnePlus created has errors in the resources, so even if I just decompile and compile the apk without any changes apktool throws errors and I can't build it.

Is there any way to force apktool to compile even if the resoruces have errors? The apk does work, as I mentioned it's a system apk from OnePlus, I don't really know what they did to it, that apktool can't compile it.

I tried using these flags but they didn't do anything to help;

-f,--force-all

-k,--keep-broken-res

I also thought the -k flag to keep the broken res was the solution for this?

It's clearly resource issues because if I decompile and compile with -r,--no-res this works...

I was hoping maybe there was a way to just decompile it without touching the resources, then changing the apk to a zip, extract and put in a new unpacked and edited resources.arsc, if this is possible?

I also tried apktool b Settings -a ./aapt but it's not working.

All of the errors are like this;

No resource found that matches the given name [MENTION=5711379]ANDROID[/MENTION]:style

No resource found that matches the given name: attr