tcpdump mailing list archives
Re: Devices and adresses in libpcap
From: Eloy Paris <peloy () chapus net>
Date: Mon, 14 Apr 2008 16:03:37 -0400
Hola David, On Sun, Apr 13, 2008 at 08:11:30PM +0200, David Rosal wrote:
2008/4/13, Guy Harris <guy () alum mit edu>:What do you mean by "some attributes of pcap descriptors that are hidden in libpcap"?Be aware that the pcap_t structure is opaque, and subject to arbitrary changes from libpcap release to libpcap release. Yes I am aware of that, and I have taken it into account. Libpcap++ does not access any field of the pcap_t structure directly, but always using the pcap public API. I have not explained the idea well enough. I mean that in libpcap++, for instance, there's a function called Pcap::get_filter(), that can be used to retrieve the filter expression previously applied to the Pcap. This is not possible in libpcap, unless the user explicitly saves the filter expresion, which is what libpcap++ does internally. This is done without accessing any field of the pcap_t structure. More examples of this are get_promiscuous() and get_timeout() member functions of class PcapLive.
Seems to me like this is a useful wrapper; thanks for putting it together. Cheers, Eloy Paris.- - This is the tcpdump-workers list. Visit https://cod.sandelman.ca/ to unsubscribe.
Current thread:
- Devices and adresses in libpcap David Rosal (Apr 12)
- Re: Devices and adresses in libpcap Guy Harris (Apr 12)
- Re: Devices and adresses in libpcap David Rosal (Apr 13)
- Re: Devices and adresses in libpcap Giovanni Venturi (Apr 13)
- Re: Devices and adresses in libpcap David Rosal (Apr 13)
- Re: Devices and adresses in libpcap Guy Harris (Apr 13)
- Re: Devices and adresses in libpcap David Rosal (Apr 13)
- Re: Devices and adresses in libpcap Eloy Paris (Apr 14)
- Re: Devices and adresses in libpcap David Rosal (Apr 13)
- Re: Devices and adresses in libpcap Guy Harris (Apr 12)