Ubuntu下的固件分析Binwalk的安装

自述

这次安装binwalk踩了N多的坑,为大家避一下,并介绍一下软件的安装;

安装

环境

这方面需要是Ubuntu16 这系列的版本的, 刚开始我用的是 Ubuntu20 ,结果报了很多错;

然后需要虚拟机上面安装 python2.7;

安装语句:

一.安装python 2.7

首先使用以下命令更新包列表:

$ sudo apt-get update

然后安装python2.7

$ sudo apt-get install python2.7
$ sudo apt update

安装python2.7 pip

$ sudo apt install python-pip
$ pip install --upgrade pip

二.binwalk安装

$ sudo apt-get update
$ sudo apt-get install build-essential autoconf git
 
# https://github.com/devttys0/binwalk/wiki/Quick-Start-Guide
$ wget https://github.com/devttys0/binwalk/archive/master.zip
$ unzip master.zip
 
$ (cd binwalk-master && sudo python setup.py uninstall && sudo python setup.py install)
 
# 自动安装依赖库文件和工具组件
$ sudo ./binwalk-master/deps.sh

要是上面的# 自动安装依赖库文件和工具组件执行不了,执行下面这一个;

# 自动安装依赖库文件
$ sudo ./deps.sh

安装python-lzma

sudo apt-get install python-lzma

安装好之后基本上就可以使用一些常规的命令了;

binwalk -Y 
binwalk -Me   解压固件

3.有选择性的安装binwalk的依赖库文件和组件工具。

$ sudo apt-get update
$ sudo apt-get install build-essential autoconf git
 
# https://github.com/devttys0/binwalk/blob/master/INSTALL.md
$ git clone https://github.com/devttys0/binwalk.git
$ cd binwalk
 
# python2.7安装
$ sudo python setup.py install
 
# python2.7手动安装依赖库
$ sudo apt-get install python-lzma
 
$ sudo apt-get install python-crypto
 
$ sudo apt-get install libqt4-opengl python-opengl python-qt4 python-qt4-gl python-numpy python-scipy python-pip
$ sudo pip install pyqtgraph
 
$ sudo apt-get install python-pip
$ sudo pip install capstone
 
# Install standard extraction utilities(必选)
$ sudo apt-get install mtd-utils gzip bzip2 tar arj lhasa p7zip p7zip-full cabextract cramfsprogs cramfsswap squashfs-tools
 
# Install sasquatch to extract non-standard SquashFS images(必选)
$ sudo apt-get install zlib1g-dev liblzma-dev liblzo2-dev
$ git clone https://github.com/devttys0/sasquatch
$ (cd sasquatch && ./build.sh)
 
# Install jefferson to extract JFFS2 file systems(可选)
$ sudo pip install cstruct
$ git clone https://github.com/sviehb/jefferson
$ (cd jefferson && sudo python setup.py install)
 
# Install ubi_reader to extract UBIFS file systems(可选)
$ sudo apt-get install liblzo2-dev python-lzo
$ git clone https://github.com/jrspruitt/ubi_reader
$ (cd ubi_reader && sudo python setup.py install)
 
# Install yaffshiv to extract YAFFS file systems(可选)
$ git clone https://github.com/devttys0/yaffshiv
$ (cd yaffshiv && sudo python setup.py install)
 
# Install unstuff (closed source) to extract StuffIt archive files(可选)
$ wget -O - http://my.smithmicro.com/downloads/files/stuffit520.611linux-i386.tar.gz | tar -zxv
$ sudo cp bin/unstuff /usr/local/bin/
  • 2
    点赞
  • 7
    收藏
    觉得还不错? 一键收藏
  • 打赏
    打赏
  • 0
    评论
Ubuntu系统上安装binwalk可以按照以下步骤进行操作: 1. 打开终端,更新安装包列表: ``` $ sudo apt-get update ``` 2. 安装Python2.7: ``` $ sudo apt-get install python2.7 ``` 3. 更新pip: ``` $ sudo apt update $ sudo apt install python-pip $ pip install --upgrade pip ``` 4. 安装必要的开发工具和依赖项: ``` $ sudo apt-get install build-essential autoconf git ``` 5. 从GitHub上克隆binwalk的源代码: ``` $ git clone https://github.com/devttys0/binwalk ``` 6. 进入binwalk文件夹: ``` $ cd binwalk ``` 7. 使用Python3环境安装binwalk: ``` $ sudo python3 setup.py install ``` 这样就完成了在Ubuntu系统上安装binwalk的过程。请注意,安装过程中可能需要输入密码以获取root权限。\[1\]\[2\] #### 引用[.reference_title] - *1* [在ubuntu的终端上安装Binwalk](https://blog.csdn.net/z2664836046/article/details/89193138)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v91^insertT0,239^v3^insert_chatgpt"}} ] [.reference_item] - *2* [在Ubuntu系统下安装杂项必备工具binwalk](https://blog.csdn.net/qq_62999000/article/details/122010423)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v91^insertT0,239^v3^insert_chatgpt"}} ] [.reference_item] - *3* [Ubuntu安装binwalk完整步骤](https://blog.csdn.net/u013071014/article/details/122426769)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v91^insertT0,239^v3^insert_chatgpt"}} ] [.reference_item] [ .reference_list ]
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

打赏作者

半岛铁盒@

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

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

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

打赏作者

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

抵扣说明:

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

余额充值