交xposed教程的作业:破解美女找茬 (原贴: https://www.52pojie.cn/thread-850885-1-1.html)
jeb分析,首先定位到 点击按钮处。
只要hook这个Util.getMoney 就行了。
注意: 静态方法。
写xposed hook 修改返回值为999即可
if (lpparam.packageName.equals("com.jimmy.beauty.pick")) {
Log.i("HOOK", "hook package");
final Class<?> clazz = findClass("com.jimmy.beauty.pick.Util",
lpparam.classLoader);
findAndHookMethod(
clazz,
"getMoney",
Context.class,
new XC_MethodHook() {
@Override
protected void beforeHookedMethod(MethodHookParam param) throws Throwable {
Log.i("HOOK", "beforeHookedMethod");
}
@Override
protected void afterHookedMethod(MethodHookParam param) throws Throwable {
param.setResult(999);
Log.i("HOOK", "设置999");
}
}
);
}
|