SHA256
1
0
forked from pool/binwalk
Alexei Sorokin 2015-09-15 18:28:28 +00:00 committed by Git OBS Bridge
parent d84165b56e
commit 1e14e70041
3 changed files with 16 additions and 190 deletions

166
binwalk.1
View File

@ -1,166 +0,0 @@
.\" DO NOT MODIFY THIS FILE! It was generated by help2man 1.43.3.
.TH BINWALK "1" "August 2014" "binwalk VERSION_STRING" "User Commands"
.SH NAME
binwalk \- manual page for binwalk VERSION_STRING
.SH SYNOPSIS
.B binwalk
[\fIOPTIONS\fR] [\fIFILE1\fR] [\fIFILE2\fR] [\fIFILE3\fR] ...
.SH DESCRIPTION
Binwalk v2.0.0
Craig Heffner, http://www.binwalk.org
.SS "Signature Scan Options:"
.TP
\fB\-B\fR, \fB\-\-signature\fR
Scan target file(s) for common file signatures
.TP
\fB\-R\fR, \fB\-\-raw=\fR<str>
Scan target file(s) for the specified sequence of bytes
.TP
\fB\-A\fR, \fB\-\-opcodes\fR
Scan target file(s) for common executable opcodes
.TP
\fB\-C\fR, \fB\-\-cast\fR
Cast offsets as a given data type (use \fB\-y\fR to specify the data type / endianess)
.TP
\fB\-m\fR, \fB\-\-magic=\fR<file>
Specify a custom magic file to use
.TP
\fB\-b\fR, \fB\-\-dumb\fR
Disable smart signature keywords
.SS "Extraction Options:"
.TP
\fB\-e\fR, \fB\-\-extract\fR
Automatically extract known file types
.TP
\fB\-D\fR, \fB\-\-dd=\fR<type:ext:cmd>
Extract <type> signatures, give the files an extension of <ext>, and execute <cmd>
.TP
\fB\-M\fR, \fB\-\-matryoshka\fR
Recursively scan extracted files
.TP
\fB\-d\fR, \fB\-\-depth=\fR<int>
Limit matryoshka recursion depth (default: 8 levels deep)
.TP
\fB\-j\fR, \fB\-\-size=\fR<int>
Limit the size of each extracted file
.TP
\fB\-r\fR, \fB\-\-rm\fR
Cleanup extracted / zero\-size files after extraction
.TP
\fB\-z\fR, \fB\-\-carve\fR
Carve data from files, but don't execute extraction utilities
.SS "Entropy Analysis Options:"
.TP
\fB\-E\fR, \fB\-\-entropy\fR
Calculate file entropy
.TP
\fB\-J\fR, \fB\-\-save\fR
Save plot as a PNG
.TP
\fB\-N\fR, \fB\-\-nplot\fR
Do not generate an entropy plot graph
.TP
\fB\-Q\fR, \fB\-\-nlegend\fR
Omit the legend from the entropy plot graph
.SS "Binary Visualization Options:"
.TP
\fB\-3\fR, \fB\-\-3D\fR
Generate a 3D binary visualization
.TP
\fB\-2\fR, \fB\-\-2D\fR
Project data points onto 3D cube walls only
.TP
\fB\-Z\fR, \fB\-\-points=\fR<int>
Set the maximum number of plotted data points
.TP
\fB\-V\fR, \fB\-\-grids\fR
Display the x\-y\-z grids in the resulting plot
.SS "Binary Diffing Options:"
.TP
\fB\-W\fR, \fB\-\-hexdump\fR
Perform a hexdump / diff of a file or files
.TP
\fB\-G\fR, \fB\-\-green\fR
Only show lines containing bytes that are the same among all files
.TP
\fB\-i\fR, \fB\-\-red\fR
Only show lines containing bytes that are different among all files
.TP
\fB\-U\fR, \fB\-\-blue\fR
Only show lines containing bytes that are different among some files
.TP
\fB\-w\fR, \fB\-\-terse\fR
Diff all files, but only display a hex dump of the first file
.SS "Heuristic Compression Options:"
.TP
\fB\-H\fR, \fB\-\-heuristic\fR
Heuristically classify high entropy data
.TP
\fB\-a\fR, \fB\-\-trigger=\fR<float>
Set the entropy trigger level (0.0 \- 1.0, default: 0.90)
.SS "Fuzzy Hash Options:"
.TP
\fB\-F\fR, \fB\-\-fuzzy\fR
Perform fuzzy hash matching on files/directories
.TP
\fB\-u\fR, \fB\-\-cutoff=\fR<int>
Set the cutoff percentage
.TP
\fB\-S\fR, \fB\-\-strings\fR
Diff strings inside files instead of the entire file
.TP
\fB\-s\fR, \fB\-\-same\fR
Only show files that are the same
.TP
\fB\-p\fR, \fB\-\-diff\fR
Only show files that are different
.TP
\fB\-n\fR, \fB\-\-name\fR
Only compare files whose base names are the same
.TP
\fB\-L\fR, \fB\-\-symlinks\fR
Don't ignore symlinks
.SS "Raw Compression Options:"
.TP
\fB\-X\fR, \fB\-\-deflate\fR
Scan for raw deflate compression streams
.SS "General Options:"
.TP
\fB\-l\fR, \fB\-\-length=\fR<int>
Number of bytes to scan
.TP
\fB\-o\fR, \fB\-\-offset=\fR<int>
Start scan at this file offset
.TP
\fB\-K\fR, \fB\-\-block=\fR<int>
Set file block size
.TP
\fB\-g\fR, \fB\-\-swap=\fR<int>
Reverse every n bytes before scanning
.TP
\fB\-I\fR, \fB\-\-invalid\fR
Show results marked as invalid
.TP
\fB\-x\fR, \fB\-\-exclude=\fR<str>
Exclude results that match <str>
.TP
\fB\-y\fR, \fB\-\-include=\fR<str>
Only show results that match <str>
.TP
\fB\-f\fR, \fB\-\-log=\fR<file>
Log results to file
.TP
\fB\-c\fR, \fB\-\-csv\fR
Log results to file in CSV format
.TP
\fB\-t\fR, \fB\-\-term\fR
Format output to fit the terminal window
.TP
\fB\-q\fR, \fB\-\-quiet\fR
Supress output to stdout
.TP
\fB\-v\fR, \fB\-\-verbose\fR
Enable verbose output
.TP
\fB\-h\fR, \fB\-\-help\fR
Show help output

View File

@ -7,8 +7,9 @@ Mon Sep 14 10:56:52 UTC 2015 - sor.alexei@meowr.ru
libmagic dependency.
- Avoid depending on library specific ABI by depending on ssdeep
instead of libfuzzy2.
- Dependencies cleanup.
- Add missing optional dependencies.
- Dependencies fixes.
- Remove pregenerated binwalk.1: leave old openSUSE releases
without a manpage.
- Spec cleanup.
-------------------------------------------------------------------

View File

@ -23,9 +23,7 @@ Summary: Firmware Analysis Tool
License: MIT
Group: Development/Tools/Debuggers
Url: https://github.com/devttys0/binwalk
Source: https://github.com/devttys0/binwalk/archive/v%{version}.tar.gz#/binwalk-%{version}.tar.gz
Source1: binwalk.1
BuildRequires: help2man
Source: https://github.com/devttys0/%{name}/archive/v%{version}.tar.gz#/%{name}-%{version}.tar.gz
# Depends on libmagic.
Requires: file
Recommends: bzip2
@ -38,15 +36,16 @@ Recommends: xz
Recommends: zlib
Suggests: java
%if 0%{?suse_version} >= 1230
# Required by help2man.
BuildRequires: help2man
BuildRequires: python3-curses
BuildRequires: python3-devel
Requires: python3-curses
# Depends on libfuzzy.
Requires: ssdeep
%else
# Required by help2man.
BuildRequires: python-curses
BuildRequires: python-devel
Requires: python-argparse
Requires: python-curses
BuildRoot: %{_tmppath}/%{name}-%{version}-build
%endif
@ -69,38 +68,30 @@ bootloaders, filesystems, etc.
%if 0%{?suse_version} >= 1230
--with-python=python3 \
--disable-libfuzzy \
%else
--with-python=python2 \
%endif
--disable-libmagic
make %{?_smp_mflags}
%if 0%{?suse_version} >= 1230
python3 setup.py install --root="$PWD/h2m" --prefix=%{_prefix}
export PYTHONPATH=./h2m%{python3_sitelib}
help2man -N --version-string=%{version} ./h2m%{_bindir}/binwalk > binwalk.1
%else
sed -e 's/VERSION_STRING/%{version}/g' %{SOURCE1} > binwalk.1
%endif
%install
%if 0%{?suse_version} >= 1230
python3 setup.py install --root=%{buildroot} --prefix=%{_prefix}
help2man -N --version-string=%{version} %{buildroot}%{_bindir}/%{name} > %{name}.1
install -Dm 0644 %{name}.1 %{buildroot}%{_mandir}/man1/%{name}.1
%else
python2 setup.py install --root=%{buildroot} --prefix=%{_prefix}
%endif
install -Dm 0644 binwalk.1 %{buildroot}%{_mandir}/man1/binwalk.1
%files
%defattr(-,root,root)
%{_bindir}/%{name}
%if 0%{?suse_version} >= 1230
%{python3_sitelib}/binwalk/
%{python3_sitelib}/binwalk-*
%{python3_sitelib}/%{name}/
%{python3_sitelib}/%{name}-*
%{_mandir}/man?/%{name}.?%{?ext_man}
%else
%{python_sitelib}/binwalk/
%{python_sitelib}/binwalk-*
%{python_sitelib}/%{name}/
%{python_sitelib}/%{name}-*
%endif
%{_mandir}/man1/binwalk.1%{?ext_man}
%changelog