fix(Disable Pairip license check): Change patch to default off

This commit is contained in:
LisoUseInAIKyrios 2025-05-22 12:14:33 +02:00
parent b143610ed6
commit 74b6a94577
3 changed files with 10 additions and 9 deletions

View File

@ -17,7 +17,8 @@ val removeShareTargetsPatch = resourcePatch(
try { try {
document("res/xml/shortcuts.xml") document("res/xml/shortcuts.xml")
} catch (_: FileNotFoundException) { } catch (_: FileNotFoundException) {
return@execute Logger.getLogger(this::class.java.name).warning("The app has no shortcuts") return@execute Logger.getLogger(this::class.java.name).warning(
"The app has no shortcuts. No changes applied.")
}.use { document -> }.use { document ->
val rootNode = document.getNode("shortcuts") as? Element ?: return@use val rootNode = document.getNode("shortcuts") as? Element ?: return@use

View File

@ -26,7 +26,6 @@ val removeMetaAIPatch = bytecodePatch(
returnIndex, returnIndex,
""" """
invoke-static { p1, p2, v$returnRegister }, $EXTENSION_CLASS_DESCRIPTOR->overrideConfigBool(JZ)Z invoke-static { p1, p2, v$returnRegister }, $EXTENSION_CLASS_DESCRIPTOR->overrideConfigBool(JZ)Z
move-result v$returnRegister move-result v$returnRegister
""" """
) )

View File

@ -7,20 +7,21 @@ import java.util.logging.Logger
@Suppress("unused") @Suppress("unused")
val disableLicenseCheckPatch = bytecodePatch( val disableLicenseCheckPatch = bytecodePatch(
name = "Disable pairip license check", name = "Disable Pairip license check",
description = "Disable Play Integrity Protect (pairip) client-side license check." description = "Disable Play Integrity Protect (Pairip) client-side license check.",
use = false
) { ) {
execute { execute {
if (processLicenseResponseFingerprint.methodOrNull == null || validateLicenseResponseFingerprint.methodOrNull == null) if (processLicenseResponseFingerprint.methodOrNull == null || validateLicenseResponseFingerprint.methodOrNull == null) {
return@execute Logger.getLogger(this::class.java.name) return@execute Logger.getLogger(this::class.java.name)
.warning("Could not find pairip licensing check. No changes applied.") .warning("Could not find Pairip licensing check. No changes applied.")
}
// Set first parameter (responseCode) to 0 (success status). // Set first parameter (responseCode) to 0 (success status).
processLicenseResponseFingerprint.method.addInstruction(0, "const/4 p1, 0x0") processLicenseResponseFingerprint.method.addInstruction(0, "const/4 p1, 0x0")
// Short-circuit the license response validation. // Short-circuit the license response validation.
validateLicenseResponseFingerprint.method.returnEarly(); validateLicenseResponseFingerprint.method.returnEarly()
} }
} }