[Bug 297235] security/binwalk: fails to start with python 3.12 due to removed 'imp' module
[email protected] Sun, 02 Aug 2026 17:42:28 +0000
| Newsgroups | gmane.os.freebsd.devel.ports.bugs |
|---|---|
| Message-ID | <[email protected]/bugzilla/> |
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=297235
Bug ID: 297235
Summary: security/binwalk: fails to start with python 3.12 due
to removed 'imp' module
Product: Ports & Packages
Version: Latest
Hardware: amd64
OS: Any
Status: New
Severity: Affects Some People
Priority: ---
Component: Individual Port(s)
Assignee: [email protected]
Reporter: [email protected]
Assignee: [email protected]
Flags: maintainer-feedback?([email protected])
Environment:
- FreeBSD 14.4-RELEASE amd64
- Python 3.12.13
- security/binwalk 2.3.3_1
Problem:
Binwalk no longer starts under Python 3.12 because it still imports the
deprecated 'imp' module, which was removed in Python 3.12.
Running binwalk results in:
ModuleNotFoundError: No module named 'imp'
I prepared and tested a compatibility patch that replaces the deprecated imp
implementation with a Python 3.12-compatible alternative.
Validation performed:
- Binwalk starts successfully
- Firmware signature scanning
- Firmware extraction
- python3 -m compileall
The patch and validation procedure are available here:
https://github.com/Mil3tus/binwalk-python312-freebsd-patch
If useful, I'd be happy to provide additional testing or information.
--
You are receiving this mail because:
You are the assignee for the bug.