Community Packages

Please read this before reporting a bug:
https://wiki.archlinux.org/title/Bug_reporting_guidelines

Do NOT report bugs when a package is just outdated, or it is in the AUR. Use the 'flag out of date' link on the package page, or the Mailing List.

REPEAT: Do NOT report bugs for outdated packages!
Tasklist

FS#70431 - [python-scapy] [2.4.3-4] Import fails on python3.9

Attached to Project: Community Packages
Opened by mal (mal) - Tuesday, 13 April 2021, 19:43 GMT
Last edited by Morten Linderud (Foxboron) - Monday, 19 April 2021, 20:07 GMT
Task Type Bug Report
Category Packages
Status Closed
Assigned To Felix Yan (felixonmars)
Levente Polyak (anthraxx)
Architecture All
Severity Medium
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 0
Private No

Details

Description:
Python has changed an undefined behavior in ctypes.util.find_library [1], which breaks scapy before 2.4.5 (unreleased) [2].

Attempting to load the latest repo scapy (2.4.3-4) or release scapy (2.4.4) with the latest repo python (3.9.2-1) fails:
```
>>> from scapy.all import *
Traceback (most recent call last):
[...]
File "/usr/lib/python3.9/site-packages/scapy/arch/bpf/core.py", line 31, in <module>
LIBC = cdll.LoadLibrary(find_library("libc"))
[...]
File "/usr/lib/python3.9/ctypes/util.py", line 99, in _is_elf
with open(filename, 'br') as thefile:
FileNotFoundError: [Errno 2] No such file or directory: b'liblibc.a'

```

This affects both the scapy CLI tool (`scapy` package) and the library (`python-scapy` package).

The attached PKGBUILD updates scapy to the latest upstream release (2.4.4), fixes this issue, and fixes the VERSION file [3].

[1] https://bugs.python.org/issue42580
[2] https://github.com/secdev/scapy/issues/3100
[3] https://bugs.archlinux.org/task/61578
   PKGBUILD (2.5 KiB)
This task depends upon

Closed by  Morten Linderud (Foxboron)
Monday, 19 April 2021, 20:07 GMT
Reason for closing:  Fixed
Additional comments about closing:  2.4.5-1
Comment by mal (mal) - Tuesday, 13 April 2021, 19:58 GMT
Unrelated, but while you're looking at this pkgbuild: `ipython` should be an optdepend for the `scapy` package. PKGBUILD with the above fixes and that change attached.
   PKGBUILD (2.6 KiB)

Loading...