Open stiray opened 4 years ago
I have decompiled the code and checking patch... the GeneratePackageInfoHook is there but generatePackageInfo has a bit strange flow. It only calls GeneratePackageHook if generatePackageInfo$wrapSource didnt return its own object. Is this code part of patch? (generatePackageInfo$wrapSource is original function while this generatePackageInfo is patch stub, first calling the original function and then patched code?
The .method private generatePackageInfo(Lcom/android/server/pm/PackageSetting;II)Landroid/content/pm/PackageInfo;
.locals 3
invoke-direct {p0, p1, p2, p3}, Lcom/android/server/pm/PackageManagerService;->generatePackageInfo__$wrapSource(Lcom/android/server/pm/PackageSetting;II)Landroid/content/pm/PackageInfo;
move-result-object v0
if-eqz p1, :cond_0
if-eqz v0, :cond_0
iget-object v1, p1, Lcom/android/server/pm/PackageSetting;->pkg:Landroid/content/pm/PackageParser$Package;
if-eqz v1, :cond_0
iget-object v2, p0, Lcom/android/server/pm/PackageManagerService;->mContext:Landroid/content/Context;
invoke-static {v0, v2, v1, p2, p3}, Lcom/android/server/pm/GeneratePackageInfoHook;->hook(Landroid/content/pm/PackageInfo;Landroid/content/Context;Landroid/content/pm/PackageParser$Package;II)Landroid/content/pm/PackageInfo;
move-result-object v0
:cond_0
return-object v0
.end method
Is this code part of patch?
yes it is, you can see the patch java sources in this repo.
first, it is a mistake to deodex part of the rom. you must deodex the complete rom or stuff may break. so yeah, it can be deodexing thing.
once that is done, if you still have issues, you can choose to patch without the UI, which is optional, and test the result.
also, make sure you are using checker version 1.1 or results can be incorrect.
I am trying to build microg rom for cosmo communicator, but i got stuck on patching services.jar, or to rather say, I deodex it, apply patches sigspoof-hook-7.0-9.0/services.jar.dex and sigspoof-core/services.jar.dex, but Signature Spoofing Checker says spoofing is disabled.
May I ask you for advice what is wrong as I am stuck. I am using HEAD from this repo.
I have wrote a little script to do it automatically (trying to build microg rom for cosmo communicator), are the main part.
Deodexing:
The process completes and services.jar has classes.dex file inside. This is the output:
Patching:
Again everything passes fine, 0 errors, 0 warnings:
The ROM is flashed to the device but the Signature Spoofing Checker says "Signature Spoofing: DISABLED"
getprop allow_fake_signature_global
returns empty line
I have searched for a potential reason a lot but as most people have issues with deodexing which is not case here...
Thank you for any help in advance.