libpcap and python
harry.python at gmail.com
Wed Feb 3 03:42:05 CET 2010
On 2月1日, 下午8时47分, Mag Gam <magaw... at gmail.com> wrote:
> Hello All,
> I used tcpdump to capture data on my network. I would like to analyze
> the data using python -- currently using ethereal and wireshark.
> I would like to get certain type of packets (I can get the hex code
> for them), what is the best way to do this? Lets say I want to capture
> all events of `ping localhost`
You need python module "pypcap" or "pcapy" to capture the packet, and
the you can use Python to analyze it.
To decode the internet packet you can use "dpkt".
More information about the Python-list