From 62a2cf4758cb4e009739f883ef9f97b21575944855ae16cd088d1c09f069615b Mon Sep 17 00:00:00 2001 From: Boris Manojlovic Date: Fri, 27 Sep 2024 07:50:39 +0000 Subject: [PATCH] - Switch upstream to a maintained fork - Update to version 2.4.2 OBS-URL: https://build.opensuse.org/package/show/devel:tools/binwalk?expand=0&rev=30 --- .gitattributes | 23 +++++ .gitignore | 1 + binwalk-2.3.4.tar.gz | 3 + binwalk-2.4.2.tar.gz | 3 + binwalk.changes | 195 +++++++++++++++++++++++++++++++++++++++++++ binwalk.spec | 97 +++++++++++++++++++++ 6 files changed, 322 insertions(+) create mode 100644 .gitattributes create mode 100644 .gitignore create mode 100644 binwalk-2.3.4.tar.gz create mode 100644 binwalk-2.4.2.tar.gz create mode 100644 binwalk.changes create mode 100644 binwalk.spec diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000..9b03811 --- /dev/null +++ b/.gitattributes @@ -0,0 +1,23 @@ +## Default LFS +*.7z filter=lfs diff=lfs merge=lfs -text +*.bsp filter=lfs diff=lfs merge=lfs -text +*.bz2 filter=lfs diff=lfs merge=lfs -text +*.gem filter=lfs diff=lfs merge=lfs -text +*.gz filter=lfs diff=lfs merge=lfs -text +*.jar filter=lfs diff=lfs merge=lfs -text +*.lz filter=lfs diff=lfs merge=lfs -text +*.lzma filter=lfs diff=lfs merge=lfs -text +*.obscpio filter=lfs diff=lfs merge=lfs -text +*.oxt filter=lfs diff=lfs merge=lfs -text +*.pdf filter=lfs diff=lfs merge=lfs -text +*.png filter=lfs diff=lfs merge=lfs -text +*.rpm filter=lfs diff=lfs merge=lfs -text +*.tbz filter=lfs diff=lfs merge=lfs -text +*.tbz2 filter=lfs diff=lfs merge=lfs -text +*.tgz filter=lfs diff=lfs merge=lfs -text +*.ttf filter=lfs diff=lfs merge=lfs -text +*.txz filter=lfs diff=lfs merge=lfs -text +*.whl filter=lfs diff=lfs merge=lfs -text +*.xz filter=lfs diff=lfs merge=lfs -text +*.zip filter=lfs diff=lfs merge=lfs -text +*.zst filter=lfs diff=lfs merge=lfs -text diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..57affb6 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +.osc diff --git a/binwalk-2.3.4.tar.gz b/binwalk-2.3.4.tar.gz new file mode 100644 index 0000000..e8ced10 --- /dev/null +++ b/binwalk-2.3.4.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:60416bfec2390cec76742ce942737df3e6585c933c2467932f59c21e002ba7a9 +size 39723471 diff --git a/binwalk-2.4.2.tar.gz b/binwalk-2.4.2.tar.gz new file mode 100644 index 0000000..1fc0523 --- /dev/null +++ b/binwalk-2.4.2.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:36b11a4d245bce9663c2c17085282eb1012716c9f0f6754497126b1ad25cd4e7 +size 39746629 diff --git a/binwalk.changes b/binwalk.changes new file mode 100644 index 0000000..026c4b7 --- /dev/null +++ b/binwalk.changes @@ -0,0 +1,195 @@ +------------------------------------------------------------------- +Fri Sep 27 03:20:21 UTC 2024 - Jan Kužílek + +- Switch upstream to a maintained fork +- Update to version 2.4.2 + * enhance the accuracy of esp image by @samhjn in #17 + * Improve install by @stkw0 in #20 + * Show warning when extraction fails and print only successful extracted entries +- Update to version 2.4.1 + * change jefferson uri by @stkw0 in #7 + * Detect WAVE and FLAC by @puhitaku in #8 + * Update audio signature file by @kagekiyo7 in #10 + * entropy: don't parse math by @ElDavoo in #12 +- Update to version 2.4.0 + This release merged the next upstream PR: + * Add magic for ZTE firmware + * Improve YAFFS signature + * Add Microware OS-9/68000 magic support + * Add PKCS#1 DER hash signatures + * Add firmware signatures used with JBOOT bootloader + * Added ESP32 image and partition entry signatures + * Add WinCE file extractor plugin + * PKCS #8 Private key +- Update to version 2.3.8 + * Fix support for python3.12 +- Update to version 2.3.7 + * Fix issue in Windows due to the use of pwd + * Fix dep.sh bug in some specific distros +- Update to version 2.3.6 + * Fix missing import on extractor.py +- Update to version 2.3.5 + This release applies a bunch of important pull request from the original repository. + Most relevant changes: + * Add support for python 3.12 + * Switch from nose to pytest + * Update minimum supported python version to 3.8 + * Move from travis to Github actions + * Fix dep.sh build issues + +------------------------------------------------------------------- +Tue Feb 14 08:16:19 UTC 2023 - Robert Frohl + +- Update to version 2.3.4 + * CVE-2022-4510: path traversal in PFS extractor script (boo#1207744) +- drop CVE-2022-4510.patch + +------------------------------------------------------------------- +Mon Jan 30 09:18:51 UTC 2023 - Boris Manojlovic + +- add CVE-2022-4510 patch file: CVE-2022-4510.patch (boo#1207744) + +------------------------------------------------------------------- +Sat Sep 11 12:23:54 UTC 2021 - Martin Hauke + +- Update to version 2.3.3 + * Added checks to prevent directory traversal vulnerability when + external extractors create symlinks on the filesystem. + * Added --run-as command line option to allow users to control + the privilege level external extractors are given as well as + the power to run as root if they so choose. + +------------------------------------------------------------------- +Thu Aug 19 19:27:51 UTC 2021 - Martin Hauke + +- Update to version 2.3.2 + * Minor bug fixes + * Removed hilink decryption plugin + +------------------------------------------------------------------- +Sun Mar 28 11:29:10 UTC 2021 - Martin Hauke + +- Update to version 2.3.1 + * Upstream does not provide a changelog + +------------------------------------------------------------------- +Mon Mar 22 10:42:20 UTC 2021 - Martin Hauke + +- Update to version 2.3.0 + * Upstream does not provide a changelog + +------------------------------------------------------------------- +Fri Sep 25 16:08:57 UTC 2020 - Martin Hauke + +- Create (via help2man) and package manpage +- Recommend more unpacking programs + * capstone, cramfs-tools, cramfsswap, jefferson, lhasa, lzop, + sasquatch, sleuthkit, squashfs, srecord, ubi_reader, yaffshiv + +------------------------------------------------------------------- +Thu Feb 6 19:05:14 UTC 2020 - Klaus Kämpf + +- Update to version 2.2.0 + - no further information available - + +------------------------------------------------------------------- +Thu Oct 17 14:39:23 UTC 2019 - Richard Brown + +- Remove obsolete Groups tag (fate#326485) + +------------------------------------------------------------------- +Fri Aug 10 13:00:35 UTC 2018 - tchvatal@suse.com + +- Use only python3 variant +- Drop argparse dependency +- Use %license macro + +------------------------------------------------------------------- +Mon Jul 2 19:48:09 UTC 2018 - kstreitova@suse.com + +- Recommends p7zip-full for TW as 7z binary used in binwalk was + moved there + +------------------------------------------------------------------- +Wed Dec 23 18:04:53 UTC 2015 - aloisio@gmx.com + +- Update to version 2.1.1: + * Many bug fixes + * New/improved file signatures + * Disassembly scans (using the Capstone Engine) + * Improved raw Deflate compression detection and extraction + * Raw LZMA compression detection and extraction + * Improved false positive detection for common compressions + (Zlib, LZMA) + * An IDA plugin for running binwalk inside of IDA + * Integration of better extraction utilities (e.g., sasquatch + for SquashFS, jefferson for JFFS2) + * Removal of all C library dependencies, including + libmagic - pure Python! + * Native Windows support! + +------------------------------------------------------------------- +Mon Sep 14 10:56:52 UTC 2015 - sor.alexei@meowr.ru + +- Use Python 3.x in new openSUSE releases. +- Use built-in pyqtgraph. +- Require "file" instead of python-magic as a shadow ABI-agnostic + libmagic dependency and "ssdeep" instead of "libfuzzy2". +- Dependencies fixes. +- Remove manpage generation from "binwalk --help": sometimes it + makes package build to fail. +- Spec cleanup. + +------------------------------------------------------------------- +Wed Jul 1 13:57:37 UTC 2015 - aloisio@gmx.com + +- Added requirement for python-curses + +------------------------------------------------------------------- +Mon Aug 4 09:20:11 UTC 2014 - boris@steki.net + +- updated to latest upstream 2.0.1 + + Python3 support + + Raw deflate detection/extraction + + Improved API + + Improved speed + + More (and improved) signatures + + Faster entropy scans +- Project has moved from google code hosting to github + +------------------------------------------------------------------- +Mon Sep 23 13:13:57 UTC 2013 - vcizek@suse.com + +- update to 1.2.1 + * complete re-write in Python and includes new features and + a scriptable Python module + * several new features, including recursive scanning and extraction, + strings and entropy analysis, and plugin support + * major speed improvements and regex filter support, + as well as bug fixes and signature updates + * adds the --extract option and extends --dd, allowing auto extraction + and auto decompression of extracted files + * Improved signatures and scan speed + +------------------------------------------------------------------- +Tue Oct 30 12:42:57 UTC 2012 - boris@steki.net + +- updated to latest upstream 0.4.5 + * Fixed magic file white space parsing bug. + * Fixed memory leak when more than one target file was specified. + * Added --dd option for auto-extraction of files. + * Bug fixes, signature updates + * Much improved scanning speed (thanks dannyb!). + * New options (--grep, --raw-bytes). + * Improved filtering. + * Various bug fixes and signature updates. + * Improved signature matching for SquashFS file systems. + * Added support for Linux block devices. + * Added support for building against libmagic. + * Added ability to optionally disable update features. + +------------------------------------------------------------------- +Tue Aug 23 12:39:24 UTC 2011 - boris@steki.net + +- Initial packaging of 0.3.8 version + diff --git a/binwalk.spec b/binwalk.spec new file mode 100644 index 0000000..ec3621a --- /dev/null +++ b/binwalk.spec @@ -0,0 +1,97 @@ +# +# spec file for package binwalk +# +# Copyright (c) 2024 SUSE LLC +# +# All modifications and additions to the file contributed by third parties +# remain the property of their copyright owners, unless otherwise agreed +# upon. The license for this file, and modifications and additions to the +# file, is the same license as for the pristine package itself (unless the +# license for the pristine package is not an Open Source License, in which +# case the license is the MIT License). An "Open Source License" is a +# license that conforms to the Open Source Definition (Version 1.9) +# published by the Open Source Initiative. + +# Please submit bugfixes or comments via https://bugs.opensuse.org/ +# + + +Name: binwalk +Version: 2.4.2 +Release: 0 +Summary: Firmware Analysis Tool +License: MIT +URL: https://github.com/OSPG/binwalk +Source: https://github.com/OSPG/%{name}/archive/v%{version}.tar.gz#/%{name}-%{version}.tar.gz +BuildRequires: fdupes +BuildRequires: help2man +BuildRequires: python-rpm-macros +BuildRequires: python3-curses +BuildRequires: python3-setuptools +# Depends on libmagic. +Requires: file +Requires: python3 >= 3.8 +Requires: python3-curses +# Depends on libfuzzy. +Requires: ssdeep +Recommends: bzip2 +Recommends: cabextract +Recommends: capstone +Recommends: cpio +Recommends: cramfs-tools +Recommends: cramfsswap +Recommends: gzip +Recommends: jefferson +Recommends: lhasa +Recommends: lzop +Recommends: sasquatch +Recommends: sleuthkit +Recommends: squashfs +Recommends: srecord +Recommends: ubi_reader +Recommends: unrar +Recommends: xz +Recommends: yaffshiv +Recommends: zlib +Suggests: java +BuildArch: noarch +%if 0%{?suse_version} > 1500 +Recommends: p7zip-full +%else +Recommends: p7zip +%endif + +%description +Binwalk is a tool for searching a given binary image for embedded +files and executable code. Specifically, it is designed for +identifying files and code embedded inside of firmware images. +Binwalk uses the libmagic library, so it is compatible with magic +signatures created for the Unix file utility. Binwalk also includes +a custom magic signature file which contains improved signatures +for files that are commonly found in firmware images such as +compressed/archived files, firmware headers, Linux kernels, +bootloaders, filesystems, etc. + +%prep +%setup -q + +%build +%python3_build + +%install +%python3_install +chmod 644 API.md +export PYTHONPATH=%{buildroot}%{python3_sitelib} +help2man %{buildroot}/%{_bindir}/binwalk --no-discard-stderr --version-string="%{version}" --no-info > binwalk.1 +install -Dpm 0644 %{name}.1 %{buildroot}/%{_mandir}/man1/%{name}.1 +%fdupes %{buildroot}%{python3_sitelib} + +%files +%license LICENSE +%doc API.md +%{_bindir}/%{name} +%{_mandir}/man1/binwalk.1%{?ext_man} +%{python3_sitelib}/%{name}/ +%{python3_sitelib}/%{name}-* + +%changelog