mirror of
https://github.com/revanced/revanced-patches.git
synced 2025-05-20 16:27:11 +02:00
fix(Instagram) - Fix hide ads
fingerprint and add bypass check signature
(#4901)
Co-authored-by: oSumAtrIX <johan.melkonyan1@web.de>
This commit is contained in:
parent
d014507851
commit
dda747379b
@ -240,6 +240,10 @@ public final class app/revanced/patches/instagram/ads/HideAdsPatchKt {
|
||||
public static final fun getHideAdsPatch ()Lapp/revanced/patcher/patch/BytecodePatch;
|
||||
}
|
||||
|
||||
public final class app/revanced/patches/instagram/misc/signature/SignatureCheckPatchKt {
|
||||
public static final fun getSignatureCheckPatch ()Lapp/revanced/patcher/patch/BytecodePatch;
|
||||
}
|
||||
|
||||
public final class app/revanced/patches/irplus/ad/RemoveAdsPatchKt {
|
||||
public static final fun getRemoveAdsPatch ()Lapp/revanced/patcher/patch/BytecodePatch;
|
||||
}
|
||||
|
@ -9,6 +9,5 @@ internal val adInjectorFingerprint = fingerprint {
|
||||
parameters("L", "L")
|
||||
strings(
|
||||
"SponsoredContentController.insertItem",
|
||||
"SponsoredContentController::Delivery",
|
||||
)
|
||||
}
|
||||
|
@ -0,0 +1,20 @@
|
||||
package app.revanced.patches.instagram.misc.signature
|
||||
|
||||
import app.revanced.patcher.fingerprint
|
||||
import app.revanced.util.getReference
|
||||
import app.revanced.util.indexOfFirstInstruction
|
||||
import com.android.tools.smali.dexlib2.iface.reference.MethodReference
|
||||
|
||||
internal val isValidSignatureClassFingerprint = fingerprint {
|
||||
strings("The provider for uri '", "' is not trusted: ")
|
||||
}
|
||||
|
||||
internal val isValidSignatureMethodFingerprint = fingerprint {
|
||||
parameters("L", "Z")
|
||||
returns("Z")
|
||||
custom { method, _ ->
|
||||
method.indexOfFirstInstruction {
|
||||
getReference<MethodReference>()?.name == "keySet"
|
||||
} >= 0
|
||||
}
|
||||
}
|
@ -0,0 +1,19 @@
|
||||
package app.revanced.patches.instagram.misc.signature
|
||||
|
||||
import app.revanced.patcher.patch.bytecodePatch
|
||||
import app.revanced.util.returnEarly
|
||||
|
||||
@Suppress("unused")
|
||||
val signatureCheckPatch = bytecodePatch(
|
||||
name = "Disable signature check",
|
||||
description = "Disables the signature check that causes the app to crash on startup."
|
||||
) {
|
||||
compatibleWith("com.instagram.android"("378.0.0.52.68"))
|
||||
|
||||
execute {
|
||||
isValidSignatureMethodFingerprint
|
||||
.match(isValidSignatureClassFingerprint.classDef)
|
||||
.method
|
||||
.returnEarly(true)
|
||||
}
|
||||
}
|
Loading…
x
Reference in New Issue
Block a user