zoukankan      html  css  js  c++  java
  • Frida 使用

    1.安装 frida-server

    adb push frida-server-15.1.12-android-arm64 /data/local/tmp
    adb shell chmod 755 /data/local/tmp/frida-server-15.1.12-android-arm64

    2.安装 objection

    pip3 install objection
    pip3 install --upgrade objection

    3.启动 frida-server

    adb shell /data/local/tmp/frida-server-15.1.12-android-arm64

    4.使用objection 

    参考资料:

    https://baijiahao.baidu.com/s?id=1680254855843073847&wfr=spider&for=pc

    https://blog.csdn.net/song_lee/article/details/108993169

    #objection -g 包名 explore
    objection -g com.immomo.momo explore

    #列出所有activity
    android hooking list activities

    #列出内存中所有类
    android hooking list classes

    #根据关键字搜索内存中的类
    android hooking search classes Okhttp


    #列出类的所有方法
    android hooking list class_methods com.fish.main.MainGameActivity


    #hook 指定类
    android hooking watch class com.xxx.xxx


    #hook 指定方法,打印出入参,堆栈
    android hooking watch class_method com.xxx.xxx.methodName --dump-args --dump-backtrace --dump-return


    #关闭SSL证书锁定,可以抓包
    android sslpinning disable

    5.使用 frida 脚本注入

    参考资料:https://blog.csdn.net/cqcre/article/details/107602760

    Java.perform(function () {
        var OkHttpClient = Java.use("okhttp3.OkHttpClient");
    
        OkHttpClient.newCall.implementation = function (request) {
            var result = this.newCall(request);
            console.log(request.url());
            var headers = request.headers();
            for (var i=0;i<headers.size();i++) {
               console.log(headers.name(i) + "=" + headers.value(i));
            }
            console.log("====================================");
            return result;
        };
    
    });
    
    #列出正在运行的进程
    frida-ps -U

    #注入指定pid的进程
    frida -U -p 11097 explore -l hook_momo_http.js
  • 相关阅读:
    Pentaho
    知识地图
    分享学习笔记本
    2015-7-1 记而随,随而记
    web 导出 csv
    vs2013 密钥
    超时时间已到。超时时间已到,但是尚未从池中获取连接。出现这种情况可能是因为所有池连接均在使用,并且达到了最大池大小。
    如何绘制业务流程图?
    总是保存下拉选项的第一个值
    mac 修改密码后 频繁输入钥匙串问题修复方法
  • 原文地址:https://www.cnblogs.com/nasdaqhe/p/15686980.html
Copyright © 2011-2022 走看看