Windows下安装androguard

一、准备工作

1、安装msysgit

下载地址:

https://code.google.com/p/msysgit/downloads/list
https://code.google.com/p/msysgit/downloads/detail?name=msysGit-fullinstall-1.8.3-preview20130601.exe&can=2&q=

2、参考 AndroGuard谷歌代码上的说明

Building from source code (default install)

Requirements

Mandatory:

  • >= python 2.6. Note that if you wish to use andromercury, python >= 2.7 is required.

Only with default python installation, you can disassemble/decompile Android Application (APK/DEX/ODEX), but if you need more features (images, interactive shell, similarities, elf analysis), you must install the next modules:

Optional:

  • ipython >= 0.12 is required by androlyze.py.
  • pygments is required by androlyze.py, to have colors with decompilation
  • pydot for androdd.py
  • python-ptrace for androdump.py
  • chilkat: used to unzip the APK application for python2.6, otherwise the zip python module is used (module apk.py). Also used to retrieve the APK's certificate.
  • magic is used in method get_files_types in APK module to found files types (module apk.py)
  • pyfuzzy is used to calculate risk indicator (module androrisk.py)
  • mercury is required by andromercury.py
  • the elsim subdirectory, used by androcsign.py, androsign.py, androdiff.py, androsim.py and andromercury.py, also require:
  • psyco is used to accelerate androguard, but it's not mandatory to install it.

/ To check: requirement of numpy, scipy, smiasmxz /


依次下载:

http://archive.ipython.org/release/0.10.1/

https://pypi.python.org/pypi/Pygments
https://pypi.python.org/packages/source/P/Pygments/Pygments-1.6.tar.gz#md5=a18feedf6ffd0b0cc8c8b0fbdb2027b1


http://www.chilkatsoft.com/installPython27.asp


https://github.com/ahupp/python-magic
https://github.com/ahupp/python-magic/archive/master.zip


http://sourceforge.net/projects/pyfuzzy/files/pyfuzzy/

http://labs.mwrinfosecurity.com/tools/2012/03/16/mercury/downloads/
http://labs.mwrinfosecurity.com/assets/418/mercury-installer-2.2.2.zip






http://zlib.net/



Androguard是一个用于分析和反编译Android应用程序的强大工具。以下是使用Androguard的一般步骤: 1. 安装Androguard:首先,你需要安装Androguard库。你可以使用pip命令来安装它: ``` pip install androguard ``` 2. 导入Androguard库:在Python脚本中,导入Androguard库以便使用其中的功能: ``` from androguard.core.bytecodes.apk import APK from androguard.core.bytecodes.dvm import DalvikVMFormat ``` 3. 加载APK文件:使用APK类加载APK文件,以便进行后续分析和操作: ``` apk = APK("path/to/apk/file.apk") ``` 4. 获取应用程序信息:通过APK对象,你可以获取应用程序的各种信息,例如包名、版本号、权限等: ``` package_name = apk.get_package() version_code = apk.get_androidversion_code() permissions = apk.get_permissions() ``` 5. 分析DEX文件:使用DalvikVMFormat类加载DEX文件,以便对应用程序的字节码进行分析: ``` dex = DalvikVMFormat(apk.get_dex()) ``` 6. 分析类和方法:通过DalvikVMFormat对象,你可以获取类和方法的信息,例如类名、方法名、参数等: ``` classes = dex.get_classes() for cls in classes: class_name = cls.get_name() methods = cls.get_methods() for method in methods: method_name = method.get_name() parameters = method.get_descriptor().get_parameters() ``` 7. 其他功能:Androguard还提供了其他一些功能,例如分析资源文件、查找敏感API调用等。你可以根据你的需求进一步探索Androguard的文档和示例。 需要注意的是,Androguard是一个功能强大但复杂的工具,对Android应用程序进行深入分析需要一定的知识和经验。在使用Androguard进行任何操作时,请确保你有合法的使用权限,并遵守相关法律和伦理规范。
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

asmcvc

你的鼓励将是我创作的最大动力

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值