The following error occured in OpenSuse 13.2. It seems there are some umlauts in /etc/services that caused the error. Changing line 110 in scapy/data.py in load_services(filename) from
into
f=open(filename, encoding='latin1')
solved the problem for me.
Here is the error message:
Traceback (most recent call last):
File "/home/marco/tmp/tmp.py", line 1, in
from scapy.all import sniff
File "/usr/lib/python3.4/site-packages/scapy/all.py", line 10, in
from .config import *
File "/usr/lib/python3.4/site-packages/scapy/config.py", line 11, in
from .data import *
File "/usr/lib/python3.4/site-packages/scapy/data.py", line 185, in
TCP_SERVICES,UDP_SERVICES=load_services("/etc/services")
File "/usr/lib/python3.4/site-packages/scapy/data.py", line 111, in load_services
for l in f:
File "/usr/lib64/python3.4/codecs.py", line 313, in decode
(result, consumed) = self._buffer_decode(data, self.errors, final)
UnicodeDecodeError: 'utf-8' codec can't decode byte 0xe9 in position 3269: invalid continuation byte
The following error occured in OpenSuse 13.2. It seems there are some umlauts in /etc/services that caused the error. Changing line 110 in scapy/data.py in load_services(filename) from
into
solved the problem for me.
Here is the error message:
Traceback (most recent call last):
File "/home/marco/tmp/tmp.py", line 1, in
from scapy.all import sniff
File "/usr/lib/python3.4/site-packages/scapy/all.py", line 10, in
from .config import *
File "/usr/lib/python3.4/site-packages/scapy/config.py", line 11, in
from .data import *
File "/usr/lib/python3.4/site-packages/scapy/data.py", line 185, in
TCP_SERVICES,UDP_SERVICES=load_services("/etc/services")
File "/usr/lib/python3.4/site-packages/scapy/data.py", line 111, in load_services
for l in f:
File "/usr/lib64/python3.4/codecs.py", line 313, in decode
(result, consumed) = self._buffer_decode(data, self.errors, final)
UnicodeDecodeError: 'utf-8' codec can't decode byte 0xe9 in position 3269: invalid continuation byte