When running the example as root on either Debian
unstable or OSX, findalldevs.py in the examples
directory I get the error:
Traceback (most recent call last):
File "./findalldevs.py", line 23, in ?
test_findalldevs()
File "./findalldevs.py", line 6, in test_findalldevs
print pcap.findalldevs()
pcapc.EXCEPTION: [Errno -1] unknown address family
I compiled against 0.7.2 on Debian.
Running as non-root I get:
[]
I have eth0 and lo on the machine.
Logged In: YES
user_id=230582
I'm finding exactly the same thing, running under gentoo.
Perhaps it's the kernel version, I'm on 2.6.12-rc4, but I've
seen the same thing happen on 2.6.9. The only other thing I
can think of is that my glibc is built with nptl, pic and
pie. If anyone else has any ideas, it'd be great to hear
them. It just seems as though this package might be
unmaintained these days. Thanks...
Mike 5:)
Logged In: YES
user_id=110010
This might be fixed in -0.5, if the address family in question was
IPv6.
Logged In: YES
user_id=59261
Originator: NO
Running this on Ubuntu 6.10 as NON-root with Python 2.4.4c1 I get this:
$ python findalldevs.py
[]
Running as ROOT I get this:
# python findalldevs.py
at line 516
at line 516
Traceback (most recent call last):
File "./findalldevs.py", line 23, in ?
test_findalldevs()
File "./findalldevs.py", line 6, in test_findalldevs
print pcap.findalldevs()
Exception: unsupported address family
Logged In: YES
user_id=110010
Originator: NO
I've committed a change which will make it simply return a string of the form <AF 16> for unrecognized address family 16. (On OSX, that's AppleTalk.)