Im trying to install Scapy on windows 10, python 2.7.11, and stuck on this error:
>>> from scapy.all import *
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "C:\tools\python\lib\site-packages\scapy\all.py", line 25, in <module>
from scapy.route import *
File "C:\tools\python\lib\site-packages\scapy\route.py", line 182, in <module>
_betteriface = conf.route.route("0.0.0.0", verbose=0)[0]
File "C:\tools\python\lib\site-packages\scapy\route.py", line 150, in route
aa = atol(a)
File "C:\tools\python\lib\site-packages\scapy\utils.py", line 400, in atol
except socket.error:
socket.gaierror: [Errno 11001] getaddrinfo failed
What does it mean?
As stated in the python 2.7 documentation , this error is thrown either by the getaddrinfo() or getnameinfo() function.
Judging by the stack trace, the scapy module tries to initialize a socket during its import and the port number is invalid (we can see the atol function being called, which convert a string to an integer).
It is unclear what the real issue is. However, you can try the following things:
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.