大麦网购票插件开发
购买插件开发的关键点在于抓包及x-sign的计算。
抓包
抓包辅助插件详见某宝app抓包插件编写
请求头与某宝x-sign,x-umt,x-mini-wua,x-sgext如出一辙,请求包不同的是,请求参数中多了type,version,appType,channel_from,osType,souce等参数。
分析x-sign,x-mini-wua,x-umt
Object doCommandNative(int code,Object[] args);
通过xposed hook的方式获取到相应参数及返回值,并编写相应模块计算。
Object doCommandRS = XposedHelpers.callMethod(JNICLibrary, "doCommandNative", byInput);
编写客户端调用搜索
String api = "mtop.damai.wireless.search.search";
String v = "1.0";
String ttid = "10005882@damai_android_7.6.7";
String t = (new Date().getTime() / 1000) + "";
String sUrl = "https://acs.m.taobao.com/gw/mtop.damai.wireless.search.search/1.0/";
...
请求返回
{"api":"mtop.alibaba.damai.detail.getdetail","data":{"result":"{"detailViewComponentMap"
...
},"ret":["SUCCESS::调用成功"],"v":"1.2"}
}