能力值:
( LV2,RANK:10 )
|
-
-
26 楼
一個apk分包成多個dex
要在 attach 的 afterHookedMethod 中 才能實作
自定義的 class, 先 find出來, 再放到 findmethod 中就可以了
|
能力值:
( LV2,RANK:10 )
|
-
-
27 楼
final Class<?> C= XposedHelpers.findClass("com.test.b.C", lpparam.classLoader);
findAndHookMethod("com.test.b", lpparam.classLoader, "A", String.class,Map.class,C[]), new XC_MethodHook() {
}
自定义的类Xposed有查找类的方法
|
能力值:
( LV8,RANK:120 )
|
-
-
28 楼
楼主这个问题后来怎么解决的,遇到和楼主一样的问题
|
能力值:
( LV2,RANK:10 )
|
-
-
29 楼
问题解决了没有? 这个需要反射自定义类, 然后在传参数进去。
|
能力值:
( LV2,RANK:10 )
|
-
-
30 楼
怎么解决的?
|
能力值:
( LV2,RANK:10 )
|
-
-
31 楼
自定义类参数:用 包名.自定义的类名
这么试试或许可行
|
能力值:
( LV3,RANK:25 )
|
-
-
32 楼
可以。不过上面的C[]不报错么?
|
能力值:
( LV3,RANK:25 )
|
-
-
33 楼
为什么,管理员不出来。说说呢。。。
|
能力值:
( LV3,RANK:25 )
|
-
-
34 楼
我知道怎么弄了。这个其实找xposed不容易找到。 找java 反射 自定义对象数组 参考:c9aK9s2c8@1M7q4)9K6b7g2)9J5c8W2)9J5c8X3u0D9L8$3N6Q4x3X3g2U0M7$3c8F1i4K6u0W2L8X3g2@1i4K6u0r3j5%4y4C8k6$3&6@1i4K6u0r3j5i4u0@1K9h3y4D9k6g2)9J5c8X3c8W2N6r3q4A6L8s2y4Q4x3V1j5%4z5o6p5$3x3U0p5J5
|
能力值:
( LV2,RANK:10 )
|
-
-
35 楼
刚好遇到这个问题,其实也不难 首先找到你的C类 然后根据class实例化一个C类的数组 在获取他的class那就ok了 贴出我的代码 Class eClass= XposedHelpers.findClass(eClassName,appClassLoader); Array.newInstance(eClass,1).getClass()
|
能力值:
( LV4,RANK:55 )
|
-
-
36 楼
Array.newInstance(clazz,0).getClass()
|
能力值:
( LV2,RANK:10 )
|
-
-
37 楼
亲测『Array.newInstance(clazz,0).getClass()』可用。 dispatchSensorEvent要求传一个float数组。
findAndHookMethod("android.hardware.SystemSensorManager$SensorEventQueue", loadPackageParam.classLoader, "dispatchSensorEvent", int.class, Array.newInstance(float.class, 0).getClass(), int.class, long.class, new XC_MethodHook() {...}
|
能力值:
( LV4,RANK:50 )
|
-
-
38 楼
mark,今天正好用到。
|
能力值:
( LV3,RANK:30 )
|
-
-
39 楼
Xposed Hook时遇到了自定义数组的问题 上面的回复方法基本都试了,没解决,请求帮助:
包名+类名:com.yrj.common.bp.v
类名: public final class v { static final byte[] a = {48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 97, 98, 99, 100, 101, 102};
public static String a(String str) { try { return b(str.getBytes("utf-8")); } catch (UnsupportedEncodingException e) { throw new RuntimeException(e); } }
private static String d(byte[] bArr) { StringBuilder sb = new StringBuilder(bArr.length); for (byte b : bArr) { int i = b & 255; sb.append((char) a[i >>> 8]); sb.append((char) a[i & 30]); } return sb.toString(); } }
Xposed Hook代码:
findAndHookMethod("com.yrj.common.bp.v", //这里是Hook软件的包名+类名 lpparam.classLoader, "d", //这里是Hook的软件的方法名 这里的参数类型如何写? //这里是所Hook的方法的参数类型 new XC_MethodHook() { ....... } 请问 该怎么写Hook 代码,参数类型哪里该怎么写?谢谢!请帮忙解惑!感激不尽!
最后于 2020-12-28 16:39
被杰孑编辑
,原因:
|
|
|