Mobsf--windows10部署

移动安全框架(MobSF)是一种自动、一体化的移动应用(Android / iOS / Windows)静态和动态分析的测试,恶意软件分析和安全评估框架。
首先提供一下官网的中文手册MobSF Documentation,其实官网写的也比较清晰,下面我分享下我的安装历程.



  • 安装过程遇到的一些问题

    首先,我也看了很多Mobsf的安装教程,有看到过程是要手动安装依赖包
    python –m pip install -r requirements.txt
    这个方式我尝试过,即使安装完了,在运行setup.bat他还是会在安装一次依赖包
    估计是寻找依赖包的位置有差别,所以不是很建议去手动安装   

    运行setup.bat,如果pip安装的速度很慢的话,经常会断开,建议在C:\Users\用户名\AppData\Roaming下创建一个pip.ini
    [global]
    index-url = http://pypi.douban.com/simple
    [install]
    use-mirrors =true
    mirrors =http://pypi.douban.com/simple/
    trusted-host =pypi.douban.com
    这是修改更新源    
    或者这个
    [global]
    index-url = https://pypi.tuna.tsinghua.edu.cn/simple
    [install]
    trusted-host=mirrors.aliyun.com

    经常跑到frida,然后就会error,这个无可厚非,多跑几次吧

    还有报过这个错,也可以多试试,或者重启大法,不过我添加完pip.ini后就没有遇到过了
    
    (1)WARNING: Retrying (Retry(total=4, connect=None, read=None, redirect=None, status=None)) after connection broken 
   by 'ConnectTimeoutError(<pip._vendor.urllib3.connection.HTTPSConnection object at 0x000001AFF0282D30>, 'Connection 
   to pypi.tuna.tsinghua.edu.cn timed out. (connect timeout=15)')': /simple/pip/

    (2)WARNING: Retrying (Retry(total=4, connect=None, read=None, redirect=None, status=None)) after connection broken 
  by 'ProtocolError('Connection aborted.', ConnectionResetError(10054, '远程主机强迫关闭了一个现有的连接。', None, 10054, None))': /simple/hyperframe/    

    接下来就是我遇到最大的坑,搞了我一整天才解决掉,心态都要崩了

    ERROR: pip's legacy dependency resolver does not consider dependency conflicts when selecting packages. 
  This behaviour is the source of the following dependency conflicts.
    mitmproxy 7.0.4 requires ruamel.yaml<0.17.17,>=0.16, but you'll have ruamel-yaml 0.17.17 which is incompatible.

    这个需要修改requirements.txt,把ruamel.yaml>=0.16.0<0.17修改为ruamel.yaml==0.16.13或者任意找得到的版本,但是满足ruamel.yaml>=0.16.0<0.17这个范围
    其实我不能理解,为啥他会默认安装到0.17.17版本,所以直接指定版本,就可以完美解决    

    解决完以上,你的Mobsf的依赖应该就可以正常跑完啦

    然后你就要迎来另一个坑啦

    就是一堆的报错,仔细看看

    from django.conf.urls import url
    ImportError: cannot import name 'url' from 'django.conf.urls'

    就是说要从django导入url,但是失败了,我们可以看看版本,依赖包是4.0,满足requirements.txt的要求啊,所以这是个坑
    我们只需要修改requirements.txt里Django==3.1.5就可以解决这个问题,原因我也不太清楚,估计4.0版本有啥问题吧,不兼容等

    然后在重新运行setup.bat
    正常情况下你可以看到以下界面

    然后就可以运行  run.bat 127.0.0.1:8000 
    在用浏览器去访问   127.0.0.1:8000

posted @ 2021-12-16 11:06  白白以桃花入笺  阅读(4340)  评论(0编辑  收藏  举报