aboutsummaryrefslogtreecommitdiff
path: root/pcap-netfilter-linux.c
Commit message (Collapse)AuthorAgeFilesLines
* Make the code to set the type a bit clearer.Guy Harris2014-04-041-6/+5
| | | | | | | | | | | Make it if (case 1) type = type 1; else if (case 2) type = type 2; and indent it a bit more clearly.
* More findalldevs fixes.Guy Harris2013-09-291-3/+2
|
* Rename the "private" member of a pcap_t to avoid C++ issues.Guy Harris2013-08-071-2/+2
| | | | | "private" is a C++ keyword; rename the "private" member of a pcap_t to "priv" to avoid that, as per Gisle Vanem's suggestion.
* Move platform-dependent pcap_t data out of the pcap_t structure.Guy Harris2013-05-061-4/+13
| | | | | | | | | | | | | | | Put the private data right after the pcap_t structure, with a pointer to it in the pcap_t. The initial goal is to allow new pcap modules to be added without having to hack pcap-int.h. In the longer term, we may want to freeze the pcap_t structure, except possibly for adding new method pointers at the end, and provide an ABI for adding modules. We also put the stuff used by the read path at the beginning of the pcap_t structure, to try to keep it on the same set of cache lines.
* Add netfilter/nfqueue interface.Jakub Zawadzki2012-06-301-48/+201
| | | | It's almost like nflog but with different structures/constants.
* Fix compilation of pcap-netfilter.Jakub Zawadzki2012-06-301-1/+1
|
* Constify some variables.Guy Harris2012-06-111-1/+1
|
* Have non-interface modules take responsibility for identifying their devices.Guy Harris2012-06-111-2/+26
| | | | | | | | | | | | | | Have a table of routines to do pcap_create() for devices that aren't regular network interfaces. Try each of those in succession until one says "it's mine" (whether it succeeds or fails); if none do, do a pcap_create() for a regular interface. Have those routines do more stringent tests of the name - don't just accept any name that has a particular substring anywhere in it. That reduces the likelihood of a false match (as happened with the CANbus module when somebody renamed their Ethernet interface "canopy"). Have the table also include routines for pcap_findalldevs().
* Don't fail if netfilter isn't enabled in the kernel.Jiri Slaby2012-02-291-2/+2
| | | | | | Check for EPROTONOSUPPORT as well as EAFNOSUPPORT. Reviewed-By: Guy Harris <guy@alum.mit.edu>
* Put declarations of pcap-netfilter-linux.c in pcap-netfilter-linux.h.Guy Harris2011-12-081-0/+2
| | | | | That way, the same declarations are used in the file that defines the functions and the files that use them, so we actually do type checking.
* Support capturing raw NFLOG headers on netfilter devices.Jakub Zawadzki2011-08-301-21/+44
| | | | Reviewed-And-Tweaked-By: Guy Harris <guy@alum.mit.edu>
* Add support for capturing from Linux iptables NFLOG log groups.Jakub Zawadzki2011-06-161-0/+443
Reviewed-By: Guy Harris <guy@alum.mit.edu>