-
Notifications
You must be signed in to change notification settings - Fork 65
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(patches): update "comet_beta" spoof fingerprint to pass Play Inte…
…grity
- Loading branch information
Showing
2 changed files
with
18 additions
and
24 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
From 86f1a57a505499c7a863e0574304762d8b9b0c4a Mon Sep 17 00:00:00 2001 | ||
From c0a32c12185c697008ac982a2c337b2ffe0d16bd Mon Sep 17 00:00:00 2001 | ||
From: Alberto Ponces <[email protected]> | ||
Date: Thu, 9 Nov 2023 12:33:55 +0100 | ||
Subject: [PATCH 01/10] gmscompat: Change attestation and instrumentation to | ||
|
@@ -10,9 +10,9 @@ Adapted by @iceows for his own AOSP A13 GSI. | |
Adapted by @ponces based on the work of @chiteroman to pass newest Play Integrity API. | ||
--- | ||
core/java/android/app/Instrumentation.java | 4 + | ||
.../internal/gmscompat/AttestationHooks.java | 93 +++++++++++++++++++ | ||
.../internal/gmscompat/AttestationHooks.java | 89 +++++++++++++++++++ | ||
.../keystore2/AndroidKeyStoreSpi.java | 3 + | ||
3 files changed, 100 insertions(+) | ||
3 files changed, 96 insertions(+) | ||
create mode 100644 core/java/com/android/internal/gmscompat/AttestationHooks.java | ||
|
||
diff --git a/core/java/android/app/Instrumentation.java b/core/java/android/app/Instrumentation.java | ||
|
@@ -46,10 +46,10 @@ index db216b1af974..9445bc1b581a 100644 | |
|
||
diff --git a/core/java/com/android/internal/gmscompat/AttestationHooks.java b/core/java/com/android/internal/gmscompat/AttestationHooks.java | ||
new file mode 100644 | ||
index 000000000000..288b51bfd738 | ||
index 000000000000..0841fe83c389 | ||
--- /dev/null | ||
+++ b/core/java/com/android/internal/gmscompat/AttestationHooks.java | ||
@@ -0,0 +1,93 @@ | ||
@@ -0,0 +1,89 @@ | ||
+/* | ||
+ * Copyright (C) 2021 The Android Open Source Project | ||
+ * | ||
|
@@ -88,8 +88,6 @@ index 000000000000..288b51bfd738 | |
+ private static volatile boolean sIsGms = false; | ||
+ private static volatile boolean sIsFinsky = false; | ||
+ | ||
+ private AttestationHooks() { } | ||
+ | ||
+ private static void setPropValue(String key, String value) { | ||
+ try { | ||
+ Log.i(TAG, "Spoofing " + key + " with value \"" + value + "\""); | ||
|
@@ -113,8 +111,8 @@ index 000000000000..288b51bfd738 | |
+ setPropValue("MANUFACTURER", "Google"); | ||
+ setPropValue("BRAND", "google"); | ||
+ setPropValue("MODEL", "Pixel 9 Pro Fold"); | ||
+ setPropValue("FINGERPRINT", "google/comet_beta/comet:15/AP41.240925.009/12534705:user/release-keys"); | ||
+ setPropValue("VERSION.SECURITY_PATCH", "2024-10-05"); | ||
+ setPropValue("FINGERPRINT", "google/comet_beta/comet:Baklava/BP21.241018.009/12628839:user/release-keys"); | ||
+ setPropValue("VERSION.SECURITY_PATCH", "2024-11-05"); | ||
+ setPropValue("VERSION.DEVICE_INITIAL_SDK_INT", "32"); | ||
+ } | ||
+ | ||
|
@@ -123,9 +121,7 @@ index 000000000000..288b51bfd738 | |
+ PROCESS_UNSTABLE.equals(Application.getProcessName())) { | ||
+ sIsGms = true; | ||
+ spoofBuildGms(); | ||
+ } | ||
+ | ||
+ if (PACKAGE_FINSKY.equals(app.getPackageName())) { | ||
+ } else if (PACKAGE_FINSKY.equals(app.getPackageName())) { | ||
+ sIsFinsky = true; | ||
+ } | ||
+ } | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,15 @@ | ||
From bb8e4025d02627f63f703a46e9778efb30aecca1 Mon Sep 17 00:00:00 2001 | ||
From 9d3693e86df969df8dc8d0f0fc3666b894d046a4 Mon Sep 17 00:00:00 2001 | ||
From: vladsendrix <[email protected]> | ||
Date: Fri, 31 Dec 2021 03:18:04 +0100 | ||
Subject: [PATCH 02/10] gmscompat: Spoof Pixel XL for Google Photos | ||
|
||
Change-Id: I905e40625b07ebf500cbb3ce1deadedee2e624c5 | ||
--- | ||
.../internal/gmscompat/AttestationHooks.java | 14 ++++++++++++++ | ||
1 file changed, 14 insertions(+) | ||
.../android/internal/gmscompat/AttestationHooks.java | 12 ++++++++++++ | ||
1 file changed, 12 insertions(+) | ||
|
||
diff --git a/core/java/com/android/internal/gmscompat/AttestationHooks.java b/core/java/com/android/internal/gmscompat/AttestationHooks.java | ||
index 288b51bfd738..1eff5842e224 100644 | ||
index 0841fe83c389..f90883e655c0 100644 | ||
--- a/core/java/com/android/internal/gmscompat/AttestationHooks.java | ||
+++ b/core/java/com/android/internal/gmscompat/AttestationHooks.java | ||
@@ -31,6 +31,7 @@ public final class AttestationHooks { | ||
|
@@ -20,7 +20,7 @@ index 288b51bfd738..1eff5842e224 100644 | |
private static final String PROCESS_UNSTABLE = "com.google.android.gms.unstable"; | ||
|
||
private static volatile boolean sIsGms = false; | ||
@@ -66,6 +67,15 @@ public final class AttestationHooks { | ||
@@ -64,6 +65,15 @@ public final class AttestationHooks { | ||
setPropValue("VERSION.DEVICE_INITIAL_SDK_INT", "32"); | ||
} | ||
|
||
|
@@ -36,17 +36,15 @@ index 288b51bfd738..1eff5842e224 100644 | |
public static void initApplicationBeforeOnCreate(Application app) { | ||
if (PACKAGE_GMS.equals(app.getPackageName()) && | ||
PROCESS_UNSTABLE.equals(Application.getProcessName())) { | ||
@@ -76,6 +86,10 @@ public final class AttestationHooks { | ||
if (PACKAGE_FINSKY.equals(app.getPackageName())) { | ||
@@ -71,6 +81,8 @@ public final class AttestationHooks { | ||
spoofBuildGms(); | ||
} else if (PACKAGE_FINSKY.equals(app.getPackageName())) { | ||
sIsFinsky = true; | ||
} | ||
+ | ||
+ if (PACKAGE_PHOTOS.equals(app.getPackageName())) { | ||
+ } else if (PACKAGE_PHOTOS.equals(app.getPackageName())) { | ||
+ spoofGooglePhotos(); | ||
+ } | ||
} | ||
} | ||
|
||
private static boolean isCallerSafetyNet() { | ||
-- | ||
2.34.1 | ||
|
b274e91
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Does that fixes fingerprint problem? Samsung Galaxy tab s6. Does not allow to add any fingerprint because says it's "full". Android 15_r5
b274e91
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No