GmsCore icon indicating copy to clipboard operation
GmsCore copied to clipboard

What do I need to do to make the GMSCore apk compiled by Android Studio pass the signature deception?

Open debusun opened this issue 1 year ago • 19 comments

Describe the bug: I used a OnePlus phone to flash the crdroid system, and then installed the source code compiled apk, but the self-check showed that the signature deception did not pass. However, I installed the downloaded release version and it showed that the signature deception passed.

What do I need to do to make the GMSCore apk compiled by Android Studio pass the signature deception?

My own compiled apk Image

Download release apk Image

Mobile phone system Image

System Android Version: 14 Custom ROM: crDroid 10.10

microG microG Core version: 0.3.5.244735-3 microG Self-Check results: Partially checked

debusun avatar Dec 13 '24 06:12 debusun

You need to update crDroid once they add a new spoofing patch, see https://github.com/microg/GmsCore/issues/2680#issuecomment-2538425189

JonnyTech avatar Dec 13 '24 11:12 JonnyTech

一旦他们添加了新的 sppofing 补丁,您就需要更新 crDroid,请参阅#2680 (评论)

I am using the latest crdroid version, and the same crdroid version is used https://github.com/microg/GmsCore/releases/tag/v0.3.5.240913 The apk released in this can be used, but my own compiled one cannot. Why is that?

stkv3i avatar Dec 16 '24 03:12 stkv3i

Please share a link to your repo.

JonnyTech avatar Dec 16 '24 03:12 JonnyTech

@stkv3i Because the version 0.3.5 of microG doesn't contains the latest commits so it erroneously pass the signature spoofing test when it shouldn't, and the apps will not works correctly unless the new signature spoofing patch is applied to the ROM.

ale5000-git avatar Dec 16 '24 04:12 ale5000-git

Please share a link to your repo.

I use following repo link build the apk(https://github.com/microg/GmsCore.git), so is there anything wrong with this link?

stkv3i avatar Dec 16 '24 05:12 stkv3i

@stkv3i Because the version 0.3.5 of microG doesn't contains the latest commits so it erroneously pass the signature spoofing test when it shouldn't, and the apps will not works correctly unless the new signature spoofing patch is applied to the ROM.

thanks very much, If I want to use my own compiled apk to run normally, what do I need to do?

stkv3i avatar Dec 16 '24 05:12 stkv3i

Please share a link to your repo.

https://github.com/microg/GmsCore.git I used the code to connect to the repository and did not pull a new branch.

debusun avatar Dec 16 '24 05:12 debusun

thanks very much, If I want to use my own compiled apk to run normally, what do I need to do?

You didn't undestand my reply:

  • Using current official microG release => will NOT work correctly even if the test pass
  • Using your compiled microG => will NOT work and the test do NOT pass

In all cases you must wait the update of the ROM with the new signature spoofing patch and update it.

You can see the details here: #2680

ale5000-git avatar Dec 16 '24 05:12 ale5000-git

thanks very much, If I want to use my own compiled apk to run normally, what do I need to do?

You didn't undestand my reply:

  • Using current official microG release => will NOT work correctly even if the test pass
  • Using your compiled microG => will NOT work and the test do NOT pass

In all cases you must wait the update of the ROM with the new signature spoofing patch and update it.

You can see the details here: #2680

thanks very much, so if I want to using my compiled microG apk can pass the test(just like the official mocroG release), what should I do?

stkv3i avatar Dec 16 '24 06:12 stkv3i

Anyone can explain it better?

I'm trying to figure out if there's a comprehension problem.

One last time: The test in the v0.3.5 only pass because it is broken (actually incomplete), once all apps are updated with the new Google libs they will all fail with microG even if the test of v0.3.5 is passing.

ale5000-git avatar Dec 16 '24 06:12 ale5000-git

Anyone can explain it better?

I'm trying to figure out if there's a comprehension problem.

One last time: The test in the v0.3.5 only pass because it is broken (actually incomplete), once all apps are updated with the new Google libs they will all fail with microG even if the test of v0.3.5 is passing.

I'm very sorry for the confusion caused by my description. I understand that using the latest Google library may not work properly, but I don't need to use the latest version of Google Maps on my end. The version I am using is 24.47.05.699977727, and I only need to use this version, The official apk of microG can be used normally, as shown in the attached image, but the APK compiled from the downloaded code( https://github.com/microg/GmsCore.git) cannot pass the test detection, so I would like to ask how to achieve the effect of the official microG APK

Image

stkv3i avatar Dec 16 '24 08:12 stkv3i

Anyone can explain it better?

We seem to have two users here: @debusun and @stkv3i have compiled microg from source and their apk is not detecting signature spoofing.

Please note that Google has recently changed their signature detection method and all Google apps will fail unless the ROM builders update their code and release a new version which you must flash onto your device. This is completely outside the realm of microg and you need to contact crdoid or lineageos or whoever else makes your rom.

As to why self-built microg apk files failed, unless you provide details of how you built them, then we cannot help. Full instructions are provided in the wiki: https://github.com/microg/GmsCore/wiki/Building - can you confirm that you are following those steps and are building on a Linux system and provide build logs?

JonnyTech avatar Dec 16 '24 12:12 JonnyTech

The "partial" signature spoofing will still works on old apps even if the test in microG self check do NOT pass, there is no need force it to pass as it doesn't make any difference in practice (for old apps).

ale5000-git avatar Dec 16 '24 14:12 ale5000-git

@JonnyTech @ale5000-git : Thank you very much, both of you。 now I following https://github.com/microg/GmsCore/wiki/Building to build apk and open microG settings like following picture show Image

if I install the apk from official microG release (https://github.com/microg/GmsCore/releases/tag/v0.3.5.240913) and then open the microG settings like following: Image

I that Google has recently changed their signature detection method and all Google apps will fail. But currently using the same room I just want to know how to achieve the effect of selecting all the above options like the official release apk using using my compiled ?The following is the log of compiling by executing the "gradlew build " command gradlew-build-log.txt

stkv3i avatar Dec 20 '24 07:12 stkv3i

Your log shows that you are building from Windows. That is why. Use Linux.

https://github.com/microg/GmsCore/wiki/Building

Prerequisites Please note that building with other operating systems than Linux is not officially supported.

JonnyTech avatar Dec 20 '24 09:12 JonnyTech

But currently using the same room I just want to know how to achieve the effect of selecting all the above options like the official release apk using using my compiled ?

If you want to have the same result of the release then just clone the tag: git clone --branch v0.3.5.240913 https://github.com/microg/android_packages_apps_GmsCore.git

ale5000-git avatar Dec 20 '24 15:12 ale5000-git

I that Google has recently changed their signature detection method and all Google apps will fail.

Soon enough all apps will fail, not just Google ones.

ale5000-git avatar Dec 20 '24 15:12 ale5000-git

Your log shows that you are building from Windows. That is why. Use Linux.

https://github.com/microg/GmsCore/wiki/Building

Prerequisites Please note that building with other operating systems than Linux is not officially supported.

@JonnyTech The running effect after I compile the linux system is the same as that of the windows system. The following is the log after I run the "./gradlew build "command on the linux system. Code is clone "git clone - branch v0.3.5.240913 https://github.com/microg/android_packages_apps_GmsCore.git" as @ale5000-git provided, could help me please?

build.log

stkv3i avatar Dec 23 '24 03:12 stkv3i

@JonnyTech The running effect after I compile the linux system is the same as that of the windows system. The following is the log after I run the "./gradlew build "command on the linux system. Code is clone "git clone - branch v0.3.5.240913 https://github.com/microg/android_packages_apps_GmsCore.git" as @ale5000-git provided, could help me please?

If it still doesn't work even when using the tag v0.3.5.240913 then your problem is probably different, maybe the ROM on your device only grant signature spoofing to microG if it has the official signature. If this is the case then there is no solution.

PS: There is also the case that it doesn't check the official microG signature but only grant it to system apps; in this case you just need to put microG in the /system partition.

ale5000-git avatar Dec 23 '24 16:12 ale5000-git