File tree Expand file tree Collapse file tree
app/src/main/java/com/sevtinge/hyperceiler/module/hook/securitycenter/other Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1818*/
1919package com.sevtinge.hyperceiler.module.hook.securitycenter.other
2020
21- import com.github.kyuubiran.ezxhelper.*
2221import com.github.kyuubiran.ezxhelper.HookFactory.`-Static`.createHook
23- import com.github.kyuubiran.ezxhelper.finders.MethodFinder.`-Static`.methodFinder
2422import com.sevtinge.hyperceiler.module.base.*
23+ import com.sevtinge.hyperceiler.module.base.dexkit.DexKit.dexKitBridge
24+ import org.luckypray.dexkit.query.enums.*
2525
2626object BypassSimLockMiAccountAuth : BaseHook() {
27- override fun init () {
28- runCatching {
29- ClassUtils .loadClass(" com.miui.simlock.b" ).methodFinder()
30- .filterByName(" m" )
31- .single().createHook {
32- returnConstant(true )
27+ private val findMethod by lazy {
28+ dexKitBridge.findMethod {
29+ matcher {
30+ declaredClass {
31+ addUsingString(" SimLockUtils" , StringMatchType .Contains )
32+ }
33+ addCall {
34+ addUsingString(" SimLockStartFragment::simLockSetUpFlow::step =" , StringMatchType .Contains )
3335 }
36+ paramCount = 1
37+ paramTypes(" android.content.Context" )
38+ returnType = " boolean"
39+ }
40+ }.map { it.getMethodInstance(lpparam.classLoader) }.toSet()
41+ }
42+
43+ override fun init () {
44+ logD(TAG , lpparam.packageName, " BypassSimLockMiAccountAuth find method is ${findMethod.last()} " )
45+ findMethod.last().createHook {
46+ returnConstant(true )
3447 }
3548 }
3649}
You can’t perform that action at this time.
0 commit comments