yashsingh1/xdaforums huggingface dataset:
[Magisk] PieOfJustice:
fOmey @ XDA
Patcher Version: 0.0.4.6
==> Binary download complete
==> Unpacked binarys.
==> Detected Java: 1.8.0_201
I: Using Apktool 2.4.0 on services.jar
I: Copying assets and libs...
I: Copying unknown files...
I: Copying original files...
!!! ERROR: Target JAR must be deodexed.

Read through comments. Only seeing use the the latest version which I am.

Running Android 9. There doesn't seem to be a way to deodex it as mentioned by a previous user. Using 4.6 doesn't work and results in it saying

!!! ERROR: Target JAR must be deodexed.

How are people using this on 9.0?
[Magisk] jimbo77:
Looks like a binary issue. Delete the bin folder and close-open the Patcher again, let it download the binary files and try again
[Magisk] PieOfJustice:
Deleted bin folder and close-open patcher. Let download files and wait for idle. Same error.

This is the contents of the bin folder.

[IMG="Bin Folder"]https://i.imgur.com/WEFmi6W.png[/IMG]
[Magisk] fOmey:
Have you bothered reading the instructions on the first post?
[Magisk] fOmey:
Are you using the ADB method or browsing for a jar?
[Magisk] PieOfJustice:
Browsing for the jar. Moved it from the phone to PC and browsed to the jar location on the PC.
[Magisk] jimbo77:
Is your services.jar properly deodexed? If not use the Adb method instead that will automatically deodex your files and patch
[Magisk] kieblink5:
You need to deodex it first if not using the adb method..
[Magisk] fOmey:
Please read the first post instructions..
[Magisk] miked2332:
Been working great thanks for the effort. This is just an FYI. First time use worked flawlessly. Updated the next months security patch on a custom kernel and stock ROM needed to deodex. Flashed a couple of kernels and found one that worked. The app has been updated since then so it may not make a difference now, this was when people we're uploading their jar files here. On a Nexus 6 wouldn't work with a stock ROM. Pixel 1 wouldn't work with a stock ROM. Pixel 2 Xl works on stock. I use Magisk and a few modules I don't really mess with the file system.
[Magisk] sobirin90:
Hello @f0mey

So im updating my ROM just now to MIUI EU 9.3.28 on my pocophone. I figure that I need to repatch again. Unfortunately, yeah like everyone else, I got error my JAR need to be deodexed, as the tool was unable to.

fOmey @ XDA

Patcher Version: 0.0.4.6

==> Detected Java: 1.8.0_201

adb: warning: stat failed for path /system/framework/miuisdk.jar: No such file or directory

adb: warning: stat failed for path /system/framework/miuisystem.jar: No such file or directory

/system/framework/: 134 files pulled. 23.6 MB/s (77990943 bytes in 3.148s)

==> Dumped framework

Error occurred during initialization of VM

!!! ERROR: Target JAR must be deodexed.

Try to revert back to the last version of the ROM before I updated. Still same result. I am sure that it worked before this and I still have the patch to use with it. Too bad now, I cannot even update further my ROM as long as this issue isn't resolved. I hope you can take a look on this matter. Feel free to request any test I need to make. So far what I've done is, using the same ROM and previous version of Smali Patcher that I had, 4.2 and 4.1 respectively, and all returned same error although it was working before at least on version 4.2. I even tested on my other devices and looks like all return the same error. I already did multiple times deleting the bin and adb folder for it to download back the latest binary release, and yet this problem still occur.

Any thoughts?
[Magisk] redking974:
Honor 8 on Nougat

Hi [MENTION=1620550]fOmey[/MENTION], thanks for your patcher. I would like to know if there could be some reasons why I continue to get rubberbanding on my device.

I use a Honor 8 with B394 build (Android Nougat 7.0). I copied my framework folder with MiXplorer, deodexed the whole folder with FulmicsDeodexer_1.6 and patched the services.jar with your patcher. After installing the Magisk's module with TWRP, I try several spoofing app with mock location activated for these apps but when I checked on Google Maps I'm still teleported beetween my real and my spoofing location.

Regards.
[Magisk] fOmey:
Try using the spoofer attached to the original post, also make sure your location settings are set to device only.
[Magisk] redking974:
Thanks for the reply. I've tried and I got rubberbanding too. Is it be possible than the patch could be inefficient on some specific manufactor's ROM (I use the EMUI on my Honor) ?

Can I have the possibility to check if the service.jar into the module created have been patched (looking for some specific data for example) ?

I've also checked by making the spoofing app as system app and I still getting rubberbanding :/

Because I think that I made the good process, here the logs :

Regards
[Magisk] Mensarius:
Worked. Thanks.:good:
[Magisk] fOmey:
Could be, upload your deodexed services.jar I'll take a look..
[Magisk] Matvei27:
When I run the patcher, seems to be able to get through the mock locations, but then eventually it gives an error saying my JAR must be deodexed. Of course, it already is. Here's the services.jar in question, from a Samsung G160N

https://drive.google.com/open?id=0B89QoNNHvvfWeHpLeXh6d0wwTTQ
[Magisk] fOmey:
Run as admin, whitelist in virus scanner etc.
[Magisk] dari-woka:
I cannot patch services.jar

I took it straight from my phone (LineageOS on a Lenovo vibe k5), when I click to path, the program crashed: "smalipatcher has stopped working" on windows

I have tried in 2 different computers
[Magisk] Matvei27:
Doesn't work. This is what happens (see attached PNG)
[Magisk] Longge1:
Got the red warning today...
[Magisk] oreo27:
Quick question for everyone using the patch. Does this also patch the package manager signature verification to allow for installation of lower versions than the app currently installed?
[Magisk] mildi2000:
Was setup do you have? Are you using joystick?
[Magisk] dimm0k:
[MENTION=1620550]fOmey[/MENTION] slightly off-topic, but I'm looking to create a module to replace my own services.jar for reasons other than what you've used it for and was wondering if it's simply a matter of replacing that file in /system using a Magisk module or is it more complicated?
[Magisk] DodoGTA:
It's not complicated
[Magisk] fOmey:
If you intend on using it for personal use it's not complicated at all..

If you have any requests for patches, I will add them to the patcher so other users can use it also !
[Magisk] AvisAile:
Hi :)

Fulmics deodexer doesn't work for me with my stock rom (nexus 5x android 8.1) :/

Any solution ?
[Magisk] fOmey:
Plenty of deodexing methods, just search.. doesn't matter which one you use.. as long as service.jar is deodexed.
[Magisk] dimm0k:
I was looking to do the following two:

custom volume step count for everything

https://xdaforums.com/v20/themes/mod-custom-volume-step-count-everything-t3691240

WakeBlock

https://xdaforums.com/android/software/wakeblock-blocking-drain-late-t3526313

any possibilities of adding these two?
[Magisk] fOmey:
I'm pretty sure there is a easier way to add volume steps from memory.. didnt require any smali edits..

Try this in your build.prop

ro.config.vc_call_vol_steps=14
ro.config.media_vol_steps=30

14 / 2 = 7 steps

30 / 2 = 15 steps

Double the value to equal the amount of steps you want.
[Magisk] Longge1:
oneplus 5 with stock rom 7.1.1

patcher 0.8 with a joystick from google play, not the one OP provided though.
[Magisk] TWIISTED_MODS:
I fixed it by deleting the file and then re trying it just for some reason didn't work the first time
[Magisk] fOmey:
Java issue.. "Error occurred during initialization of VM".

Google it, find a fix.. nothing to do with the patcher.

My guess: run the patcher as admin or restart PC..
[Magisk] sobirin90:
Found the culprit, I had set my JAVA_OPTIONS environment variable which set to -Xmx512m. Recently I was setting up environment for ionic development, so that might conflict. I will ask my senior whether this environment variable is necessary or not. If it is I need to readd back the variable and delete it back if I want use the patcher. Although temporary fix, but it I'm glad to found out what is the cause.

Thanks for the insight f0mey, ya just reallized my deodexed error is slightly different with others.
[Magisk] expiredd:
Is there any way to make Smali Patcher work on a Linux machine? :crying:
[Magisk] fOmey:
That variable sets a maximum for the java memory heap size.. I'm guessing apktool is a little memory hungry which is why it spat that error out.

Unless your strictly trying to stay under that 512 limit, I don't really see a reason to set a hard maximum limit.
[Magisk] BugHats:
Installation failed

- copying zip to temp directory

- installing SmaliPatcherModule-0.0.4.6-f0mey@XDA.zip

*************************************

Please install the latest Magisk!

*************************************

! Installation failed

Can u help me? Im using magisk 19.0
[Magisk] Playersidhu:
ANY POCO F1 USER PLZ HELP?

I am unable to make patch because my pc is not working.

Can anyone upload Smali patcher for miui

10.3.4.0 ?

Thanks
[Magisk] sobirin90:
pulling out services.jar because ADB method fails

Can anyone give step by step how you achieved this? I checked my ROM zip file and system/framework isn't there.

Just a precaution if I face this problem in the future. Thanks.
[Magisk] AnonVendetta:
This patch works fine with Pie, I've tested on Resurrection Remix for the Galaxy Note 4. My ROM appears to be partially odexed, like most other LOS/AOSP-based P ROMs. But it really isnt, because most APKs/JARs in /system have one or more classes.dex inside them. I have tried deodexing the ROM with SuperR's Kitchen, it boots but boot time is really slow. Once in the ROM everything runs at normal speed. Smali Patcher didnt complain about an odexed ROM, but I used the services.jar that I copied over to PC, not ADB. I dont use Magisk either, so I just extracted services.jar from the zip and moved it to /system/framework with 0644 perms set. I applied disable sig verification (so I can use modded Play Store), enable sig spoofing (for MicroG), and mock location patch. The first 2 appear to be working, but I am not sure that the mock location patch worked.

[MENTION=1620550]fOmey[/MENTION]: Your GPS spoofer app crashes on RR and HavocOS P, it asks for location permission and I grant, then a "X has stopped working" appears. Any other way I can test to see if the mock location patch worked? Do I need to select GPS Spoofer as a mock location provider in Development settings? Thanks!

[MENTION=9744953]Playersidhu[/MENTION]: My laptop is working, get a copy of your ROM's services.jar from /system/framework, put it in a zip file, then upload that file to XDA in a post attachment. Specify what patches you want, then I will post the patched file.
[Magisk] fOmey:
Yeah that spoofer is probably severely outdated.. tons of better options out there!

CHANGELOG ::

4.7

Secure flag patch update (based off 9.0).

Signature verification patch update (based off 9.0).
[Magisk] AnonVendetta:
[MENTION=1620550]fOmey[/MENTION]: Do you think it will help my boot speed if I also extract the odex/vdex files from the zip too? I don't think so, because they are zero bytes, except services.jar which is normal size. Boot time is fast until I patch services.jar, once I replace that with the patched copy it gets really slow booting up (up to 100 seconds sometimes). As stated before, my ROM appears to be odexed but really isn't, there are oat/vdex files in /system/framework, but most JARs there have a classes.dex inside them, which means they are really deodexed. Explains why the patcher didn't complain, if it didn't find a dex to patch then the "deodex" message would appear. Thanks!

I did try deodexing the entire ROM before, but boot times were slow then too, even without patching services.jar (well over 100 seconds on every boot).
[Magisk] fOmey:
Any files that are 0 bytes you should be deleting if you're not using magisk. 0 byte files act like a delete in magisk modules.
[Magisk] ulisesr_aldana:
Hi, im using Samsung Note 8 with android Pie, ROM LightROM by TeamExyKings.

I'm trying to use Smali Patcher in its latest version (SmaliPatcher-0.0.4.7)

fOmey @ XDA

Patcher Version: 0.0.4.7

==> Detected Java: 1.6.0_37

/system/framework/: 671 files pulled. 18.8 MB/s (374894809 bytes in 19.046s)

==> Dumped framework

java.lang.UnsupportedClassVersionError: brut/apktool/Main : Unsupported major.minor version 52.0

!!! ERROR: Target JAR must be deodexed.

There is a way to fix it?
[Magisk] jimbo77:
Read the last few pages of the thread. All the information is here :)
[Magisk] H4X0R46:
Just tried this module for the first time, it's great! Used it to enable screenshots in secure apps on my OnePlus 6T and was surprised! It works so well! :D
[Magisk] Cisencjusz:
i have a problem with newest update, after i flashed it my rom booted but after that the screen was black and the only thing i can do was rebooting into bootloader, the 4.6 version was working perfectly

---------- Post added at 11:37 AM ---------- Previous post was at 11:02 AM ----------

i forgot to say that im on android 9 and magisk 19, i want to give some kind of logs bo idk how
[Magisk] GreedyCat:
4.6 version(I haven't tested 4.7 yet) of patch doesn't work on magisk 18.2 and older. Pokemon Go shows me an error "Failed to detect location(11)" when joystick is launched. It works only on magisk 19 which is a bit unstable for me. I have security patch from 1 January 2019 so is it the case of the problem? Android 8.

P.s. sry for my English, I'm not a native speaker.
[Magisk] fOmey:
What patches are you applying? Try isolate what patch you believe is causing it by using one at a time.

Also google "android how to logcat".

I just tried the first joystick app on the playstore (app ninja) and it worked fine on my S10.. all I did was enable pokemon go under magisk hide, set my mock provider to the joystick app and play.

I'm using the canary version of magisk..
[Magisk] jimbo77:
Careful that Joystick is Blacklisted try to use the privacy option.. To generate an app with a random name otherwise you'll get suspended :/. I use the same app but with a random package name
[Magisk] GreedyCat:
I used the last canary version of magisk, patch worked fine, but on older version it doesn't work. Test magisk 18.1/18.2 on your device, please.

I want to use older versions because I have some problems with the recent verison.
[Magisk] fOmey:
You can adapt the generated module to a older module template.. I only support the latest magisk.
[Magisk] danw84:
Just installed the "Magisk reboot" for my Galaxy S10. The installation process went well but when I restart the phone Magisk is disabled.

Doesn't seem to work.

I have ASD5 firmware
[Magisk] fOmey:
Can you upload the generated module & patch log.
[Magisk] danw84:
Sorry it was just me being stupid. Didn't realize i got to activate the module in Magisk... :/

Thanks for your work !
[Magisk] Cisencjusz:
i updated magisk to newest canary version and patched only mocking locations, without signature spoofing like earlier and its working again, i will downgrade and provide logcats in a few days, i dont have time right now for that, sorry
[Magisk] fOmey:
Ha! Glad you got it sorted.

Don't bother, probably just some funky magisk voodoo.
[Magisk] leandrosando:
Cant see the link of gps
[Magisk] sachin karinki:
Please answer these questions.

1)Is there any method to install this without PC

Device: OnePlus 2

Rom: Havoc Os pie

2) if i generated the zip from pc when using havoc pie, can i use that zip on all other AOSP and LOS based oreo and pie based custom roms ?
[Magisk] fOmey:
1) No.

2) Probably not, unless they share identical services.jar.
[Magisk] NordicSwE:
I got bootloop on Galaxy S9

When i did every step correct of installing Smali Patcher latest version from my pc and then go to the phone and installing it through magisk manager and then rebooting my phone and boom a bootloop starts and i got to wipe my phone
[Magisk] Phantom Thief:
When that happens you can just flash the magisk Uninstaller. At least you won't lose your data.
[Magisk] pawwaap:
Hi, just trying your patch, needed for reinstalling applications freely from signature checking.

It seems working partially, installations of "unsigned" applications succeeds.

However cant downgrade applications (reinstalling to lower release).

Is it what the patch entirelly can do?

XperiaXZ F8331 Oreo eXistenz debloated
[Magisk] renzyyy:
hmmm only saw windows executable, any chance there is a unix based script...? might be useful for linux/mac users
[Magisk] theredbaron1834:
No linux, It uses .net and doesn't work on wine. :(

Luckily I still have a win partition for stuff like thus.
[Magisk] fOmey:
Yes, at the time of creating the patch it was the only option.. the files that needed to be patched to allowing overwriting with lower versions are outside services.jar.

Setup a Windows VM? Unix based script is not going to happen.. maximum effort for such a small user base.
[Magisk] renzyyy:
no worries, i was just being lazy :o i did find some info on what would be needed to replicate what youve done. dunno if its really worth the effort like you said hah.

i just dont like an app telling me what i can (or cant) do, like take a screenshot, even when i have root privs. appreciate the response :D
[Magisk] Fre$h:
For some reason I can't understand, smalipatcher has a bad impact on April release of Los 16 [MENTION=1620550]fOmey[/MENTION]. Everything is running fine on March release, but smali break the volume buttons control, set the sound as it's max, and corrupt some system icons in the notification bar. If I disable smali module, everything is running fine. Something in the services.jar had change from march to april that smali breaks

BTW, spoofing still works as attended, but now I've to choose between spoofing or having a 'normal' device
[Magisk] joluke:
Is this tool open source?

Works great on [MENTION=3931450]dr.ketan[/MENTION] P08 rom:

Log of sucessful actions done (all four selected and working):

fOmey @ XDA

Patcher Version: 0.0.4.7

==> Detected Java: 1.8.0_211

/system/framework/: 673 files pulled. 24.7 MB/s (439700877 bytes in 16.957s)

==> Dumped framework

[INFO] Processing 1 file(s) from bin\services.vdex

[INFO] 1 out of 1 Vdex files have been processed

bin\compact_dex_converter: 1 file pushed. 20.1 MB/s (5087392 bytes in 0.241s)

bin\classes.cdex: 1 file pushed. 22.7 MB/s (13561096 bytes in 0.571s)

Opened '/data/local/tmp/classes.cdex', DEX version '001'

/data/local/tmp/classes.cdex.new: 1 file pulled. 28.1 MB/s (14103216 bytes in 0.479s)

bin\compact_dex_converter: 1 file pushed. 24.4 MB/s (5087392 bytes in 0.199s)

bin\classes2.cdex: 1 file pushed. 25.2 MB/s (21142816 bytes in 0.801s)

Opened '/data/local/tmp/classes2.cdex', DEX version '001'

/data/local/tmp/classes2.cdex.new: 1 file pulled. 25.3 MB/s (10023376 bytes in 0.378s)

==> Extracted classes.dex

==> Extracted classes2.dex

I: Using Apktool 2.4.0 on services.jar

I: Baksmaling classes.dex...

I: Baksmaling classes2.dex...

I: Copying assets and libs...

I: Copying unknown files...

I: Copying original files...

==> Patched mock location boolean

==> Patched mock location boolean

==> Patched secure flag function

==> Patched secure capture function

==> Patched secure capture function

==> Patched signature verification function

I: Using Apktool 2.4.0

I: Checking whether sources has changed...

I: Smaling smali folder into classes.dex...

I: Checking whether sources has changed...

I: Smaling smali_classes2 folder into classes2.dex...

I: Building apk file...

I: Copying unknown files/dir...

I: Built apk...

0 error(s), 0 warning(s)

==> Merged patch: sigspoof_7.0-9.0

0 error(s), 0 warning(s)

==> Merged patch: sigspoof_core

==> Magisk template download complete

==> Generated magisk module zip file

*** Complete ***
[Magisk] fOmey:
Very odd behaviour! I can't think of anything that would trigger that...

Are you using any other mods? Can you disable any other mods you have installed and test to see if the behaviour persists.

You have generated a new module to use on the new release haven't you?

It is not unfortunately.
[Magisk] Fre$h:
Smalipatcher is the only magisk mod I use. I did those test from a scratch reinstall, and couldn't find the issue, until user Golv point me to that result. I'll try an older 0.0.4.5 file to see if maybe that can come from the latest april Lineage build, or smalipatcher itself.

But if I use 0.0.4.7 with march Los 16 build, everything is ok :)
[Magisk] 13thbugs:
Dear sir,i'm having a problem using the adb method

I've follow the method for adb that automaticaly deodex the service.jar but the patcher always come with adb error that said not found adb device,

The procedure entry point ucrtbase_create_locale could not be located in the dynamic link library api-ms-win-crt-locale-l1-1-0.dll

I'm using windows 7,and my device is redmi note 5 pro,developer rom.

Can you tell me if anything i've done wrong.

Thank you in advance

Sorry if my english is bad
[Magisk] amg314:
Instruction on services.jar patching for signature spoofing using BatchApkTool

Some users do not like Xposed FakeGapps method for signature spoofing while using microG (SafetyNet issue, etc)

The following show a way to get pure signature spoofing)))

1. Unpack BatchApkTool373.7z by BurSoft to handy directory. https://bursoft-portable.blogspot.com/p/blog-page_23.html

2. To copy /system/framework from your Android device to Your_Path\BatchApkTool_3.7.3\_system:

Select 13 command - pull > and then type 3 = All files from /system/framework (in 15 seconds /framework will be copied to _system)))

You can also use ADB plugin for Total Commander or adb pull /system/framework in TWRP or USB flash, etc.

3. Run BatchApkTool.exe, choose language, then run 84 command to set your API. After tuning run deodexation command 01

After deodexations process will over, you will find result in the same _system directory.

4. For signature spoofing you need to patch the only file _system\framework\services.jar

Patch this file using SmaliPatcher.exe https://xdaforums.com/apps/magisk/module-smali-patcher-0-7-t3680053

a) Copy SmaliPatcher.exe to handy directory

b) Run the program, click 'Browse' button and point on _system\framework\services.jar

After that click 'Patch Jar' and wait. As a result you will get SmaliPatcherModule-0.0.4.6-fOmey@XDA.zip - ready for Magisk flashing module.

c) Copy SmaliPatcherModule-0.0.4.6-fOmey@XDA.zip to your device (see Paragraph 2) and install it thru Magisk Manager.

Reboot.

---------- Post added at 08:48 AM ---------- Previous post was at 08:46 AM ----------

Use ApkBatchTool (see https://xdaforums.com/showpost.php?p=79399590&postcount=2812)
[Magisk] n. arx:
Other methods of spoofing in pokemon go requires me to downgrade Google play services.. Not sure whether using Smali Patcher to spoof still requires me to downgrade play services? Or is it usable in latest android security patch
[Magisk] pawwaap:
So, please, would you make any improvement to this work to also allow for apks reinstallation-downgrading?

And, specifically, please say and enumerate what kind of signature verification omitting this patch can provide?

- installing "unsigned" can, right?

- reinstalling apk with different signature but still the same full name?

It just cant allow for downgrading?

Would you suggest another patch or solution to allow for downgrading?

For some reason XperiaXZ Oreo (rooted etc) cant allow for Xposed nor Magisk's edXposed.

XperiaXZ F8331 Oreo eXistenz debloated
[Magisk] shoey63:
[MENTION=7903587]pawwaap[/MENTION]

Just use a root explorer or twrp to replace your apk's and reboot with signature verification disabled. It should work.
[Magisk] TheUndertaker21:
cant patch s10 sayin it should be deoxed

and if i use the app to patch it

it get stuck on pull files lol
[Magisk] amg314:
To deodex use BatchAPKTool

See https://xdaforums.com/showpost.php?p=79399590&postcount=2812
[Magisk] pawwaap:
Idea theoretically sunds good, but hasn't worked for TitaniumBackup, only has tried this so far.

And maybe, is apk file rights significant to doublecheck in this operation?
[Magisk] TheUndertaker21:
getting error for some

is that normal?