基於微信7.0.12版本,請自尋下載對應微信版本。打開jadx反編譯工具自行比對,主要怕你以爲我騙你。至於這個爬蟲代碼如何運行,請關注我的逆向工作臺hooker項目:https://github.com/CreditTone/radar-frida,打開腦洞好好思考一下。題材過於敏感,這裏不多作介紹。
package gz.wxvideo;
import com.tencent.mm.plugin.finder.cgi.aa;
import com.tencent.mm.plugin.finder.search.FinderMixSearchUI;
import com.tencent.mm.plugin.finder.search.e;
import com.tencent.mm.ui.search.FTSEditTextView;
import java.lang.reflect.Field;
import gz.com.alibaba.fastjson.JSON;
public class SearchUIMocker {
private FinderMixSearchUI finderMixSearchUI;
private Field finderMixSearchUI_pFF;
private Field finderMixSearchUI_pGf;
private Field finderMixSearchUI_pFF_FAg;
private Field fTSEditTextView_Fzz;
private Field pFMField = null;
public SearchUIMocker(FinderMixSearchUI finderMixSearchUI) throws Exception {
this.finderMixSearchUI = finderMixSearchUI;
finderMixSearchUI_pFF = FinderMixSearchUI.class.getDeclaredField("pFF");
finderMixSearchUI_pFF.setAccessible(true);
finderMixSearchUI_pFF_FAg = com.tencent.mm.ui.search.a.class.getDeclaredField("FAg");
finderMixSearchUI_pFF_FAg.setAccessible(true);
fTSEditTextView_Fzz = FTSEditTextView.class.getDeclaredField("FzZ");
fTSEditTextView_Fzz.setAccessible(true);
finderMixSearchUI_pGf = FinderMixSearchUI.class.getDeclaredField("pGf");
finderMixSearchUI_pGf.setAccessible(true);
pFMField = e.class.getDeclaredField("pFM");
pFMField.setAccessible(true);
}
private FTSEditTextView getFTSEditTextView() throws Exception {
com.tencent.mm.ui.search.a pff = (com.tencent.mm.ui.search.a) finderMixSearchUI_pFF.get(finderMixSearchUI);
FTSEditTextView fTSEditTextView = (FTSEditTextView) finderMixSearchUI_pFF_FAg.get(pff);
return fTSEditTextView;
}
public void search(final String keyword) throws Exception {
finderMixSearchUI.runOnUiThread(new Runnable() {
@Override
public void run() {
try {
FTSEditTextView fTSEditTextView = getFTSEditTextView();
fTSEditTextView.clearText();
fTSEditTextView.getEditText().setText(keyword);
fTSEditTextView.eKX();
finderMixSearchUI.hideVKB();
Thread.sleep(1000);
FTSEditTextView.a fzz = (FTSEditTextView.a) fTSEditTextView_Fzz.get(fTSEditTextView);
fzz.bjl();
} catch (Exception e) {
e.printStackTrace();
}
}
});
}
public String getSearchText() throws Exception {
FTSEditTextView fTSEditTextView = getFTSEditTextView();
return fTSEditTextView.getInEditTextQuery();
}
public String getResultsJson() throws Exception {
e searche = (e) finderMixSearchUI_pGf.get(finderMixSearchUI);
aa pfm = (aa) pFMField.get(searche);
return JSON.toJSONString(pfm.ppJ.pbk);
}
}