I'm trying to find a good and stable network packet sniffer in python, that allows me to do exactly the as I used to with tcpdump.

I found this pycap but it does not seem to be that stable... Another options would be Scapy but it does not handle reassembling TCP streams.

Any other options? Or am I wrong about pycap?

有帮助吗?

解决方案

If you're worried about the stability of other python based packages, you can use python's ctypes library to dynamically load in libpcap.so.

You can find out more on using libpcap.so over here while the ctypes documentation is here.

其他提示

Take a look at PyShark. It allows you to sniff specific interface continuously.

许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top