libpcap 库使用(二)

参考资料:

  http://www.tcpdump.org/manpages/pcap.3pcap.html

  分类介绍了该lib的函数

Opening a capture handle for reading

 

Selecting a link-layer header type for a live capture

Reading packets

Filters

Capture statistics

 

Opening a handle for writing captured packets

Writing packets

Injecting packets

Reporting errors

Getting library version information

 

总结:

  注意函数是在什么时候调用,create--->active--->capature。

  有些函数实在 create 之后,active 之前调用的,有些是在 active 之后 capature 之后调用的。

 

posted on 2019-04-02 17:28  rivsidn  阅读(269)  评论(0)    收藏  举报

导航