dect
/
libpcap
Archived
13
0
Fork 0
Commit Graph

126 Commits

Author SHA1 Message Date
guy c1401d4725 The DLT_LINUX_PPP_WITHDIRECTION is also used for pppd on some BSDs, so
rename it again to DLT_PPP_PPPD, and rename other #defines to match.

Add backwards-compatibility #defines of DLT_PPP_WITH_DIRECTION and
DLT_LINUX_PPP_WITHDIRECTION for software that used them.
2005-02-08 19:52:18 +00:00
guy d9e0597103 Rename DLT_PPP_WITHDIRECTION to DLT_LINUX_PPP_WITHDIRECTION, as it's a
Linux-specific mechanism, and rename other #defines accordingly.  Give
more details about it in comments.
2005-01-31 01:47:27 +00:00
hannes b82f83587c add support for DLT_JUNIPER_{MLFR,MLPPP) 2005-01-25 22:38:23 +00:00
hannes 6e18a333d2 add gencode support for Juniper ML/LS PIC DLT_ 2005-01-12 09:02:55 +00:00
guy f8a76d1d76 From Gisle Vanem: MS-DOS support. 2004-12-18 08:52:08 +00:00
guy 8ab85b3b53 From Gisle Vanem: there's no need to include <sys/time.h> in
"gencode.c", as "pcap.h" includes it.
2004-12-17 20:16:44 +00:00
guy 3573dfdacc Put the FDDI padding (if any) into the pcap_t structure on platforms
that require it, and make pcap_fddipad private to the code generator, as
that's the only place that needs it (ideally, all *its* state should be
local as well).  This makes opening an FDDI device, on platforms where
the padding is supplied as part of the packet, and opening other types
of devices or opening savefiles in the same program work better, as you
don't have to be sure you compile the filter for a given pcap_t before
opening the next pcap_t.
2004-12-15 00:25:08 +00:00
guy 1ab36e08d7 Fix a comment.
Clean up white space.
2004-11-06 22:57:28 +00:00
guy a1e08cec1e Move the code to generate code to check for a particular linktype in the
Linux cooked header into a routine of its own.
2004-11-06 22:45:17 +00:00
hannes 3bcf07168c add support for DLT_JUNIPER_ATM1 (137) and DLT_JUNIPER_ATM2 (135) 2004-10-19 15:55:28 +00:00
guy 2ae5a9fc8c From Nicolas Dade <ndade@nsd.dyndns.org>: the VLAN tag is in the lower
12 bits of the VLAN field - check only those bits, not the priority or
CFI flag.
2004-08-27 07:37:10 +00:00
hannes 4017783b36 add support for another PPP variant as per request from Karsten Keil <kkeil@suse.de>
the first byte (0xff) of the PPP header (0xff03) is tweaked to accomodate
the direction 0x00 = IN, 0x01 = OUT

the DLT_ supports the libpcap tokens "inbound" and "outbound"
2004-08-18 14:25:01 +00:00
guy fa90431b10 Catch the case in "gen_mpls()" where "orig_nl" isn't -1, meaning
somebody's already used "vlan" or "mpls".
2004-07-15 00:08:06 +00:00
hannes 4ce3baf349 bugfix: MPLS compare all (masked)32bits instead of just 16 2004-06-16 08:29:33 +00:00
hannes 405ab1a931 add baseline support for MPLS protocol and per-label filtering 2004-06-16 08:20:28 +00:00
guy 1cd8c13e62 From Brian Ginsbach: squelch some compiler warnings. 2004-04-07 18:43:29 +00:00
guy 0a56a3721a Get rid of long-vs-int problem in a printf format (sometimes sizeof is
an int, sometime's it's a long).
2004-03-29 21:04:31 +00:00
fenner 8177eec7d9 Handle the new OpenBSD pf format (DLT 117), which is now being used
by other systems as they adopt pf.
Don't bother trying to be backwards compatible with DLT 17.
2004-03-28 20:27:12 +00:00
guy 1bd06dd0d5 Add support for Apple's IP-over-IEEE 1394 encapsulation.
Fix a comment.
2004-03-17 19:03:28 +00:00
guy 8842b61d2f Add support for DLT_ value 99, as used by the Axent Raptor
firewall/Symantec Enterprise Firewall.  Thanks, Axent/Symantec, for not
asking us for a DLT_ value and not telling us about the link-layer type.
2004-03-11 09:13:11 +00:00
guy 34379f5c0e For now, support "link[N:M]" filtering, but nothing else, for
DLT_IEEE802_11_RADIO (rather than supporting nothing, which keeps most
capture programs from working at all, as they set an empty filter if no
filter was explicitly supplied).
2004-01-31 01:54:43 +00:00
guy 7ac8a0a75b DLT_IEEE802_11_RADIO is used for the BSD radio header; add a new
DLT_IEEE802_11_RADIO_AVS for future use with the AVS radio header.

Fix a comment.

Put in reserved LINKTYPE_USERn values corresponding to the reserved
DLT_USERn values.
2004-01-29 10:36:43 +00:00
guy 28d3e917c0 Add stuff from the FreeBSD gencode.c to a comment. 2004-01-29 10:25:19 +00:00
guy 963cacf276 Put in support for raw "link[N:M]" filtering for DOCSIS. 2004-01-14 01:09:03 +00:00
guy 22a42b8996 Put in very minimal support for DLT_LINUX_IRDA filters. 2003-12-18 20:36:11 +00:00
guy 30e89f192a Add _U_ to "rcsid[]" definitions, to eliminate "unused variable"
warnings from newer versions of GCC.
2003-11-15 23:23:57 +00:00
guy e7bf9c5777 Squelch signed vs. unsigned comparison warnings. 2003-08-18 22:09:30 +00:00
hannes 4ed4d62d8f bogus generation of PSNP codepoint for CSNP PDUs 2003-07-29 08:53:51 +00:00
guy 2e69dd906a The value pointed to by "gen_pf_ifname()"'s argument isn't modified, so
make it a const pointer.

Cast the interface name in the "gen_bcmp()" call in "gen_pf_ifname()" to
squelch a compiler warning.
2003-05-02 08:37:43 +00:00
guy 4175af1a53 Add support for "link broadcast" and "link multicast" for RFC 2625
IP-over-FC.

Clean up some error messages.
2003-03-28 08:09:48 +00:00
guy 23d8b7205b Add support for OpenBSD DLT_PFLOG.
Get rid of bogus newline in BPF error string.
2003-03-11 06:23:52 +00:00
guy 786403c0a7 Add support for OpenBSD DLT_ENC - and map it to a value of 109, as its
value in OpenBSD, 13, is Yet Another DLT_ Value That Other OSes Use For
Their Own Purposes.
2003-03-08 08:42:13 +00:00
guy 8c2a3a235c From clodder@acm.org, via OpenBSD: add a check for memory allocation
failure.
2003-03-08 08:23:47 +00:00
guy 4244b90c15 Unfortunately, there is no direction flag for DLT_PPP. 2003-02-14 07:48:25 +00:00
guy 6efec806a4 For DLT_ATM_RFC1483, the network-layer header starts 8 bytes from the
beginning of the packet if the packet has an 802.2+SNAP header (3 bytes
802.2, 5 bytes SNAP), and 3 bytes from the beginning of the packet if it
has only an 802.2 header, just as is the case for DLT_ATM_CLIP, so go
back to handling them both with the same case.

Restore some comments asking whether we need to check the SSAP when
testing the 802.2 header for protocol types.

Clean up white space.

RFC 1188, RFC 1042, and RFCs 1483 and 2225 specify that SNAP
encapsulation is used for IP, not LLC encapsulation with LLCSAP_IP and,
in fact, that's what most if not all IP traffic over FDDI, 802 networks,
and LLC-encapsulated ATM use; go back to treating those link-layer types
the same way other link-layer types are handled.
2003-02-05 01:53:29 +00:00
guy 2d1ac3b4d5 From Peter Fales <peter@fales-lorenz.net>: support for Linux ARCNET,
which supplies different headers from BSD ARCNET, and fixes to the
ARCNET code generator (the protocol ID field is 1 byte, so the values
for it shouldn't be byte-swapped).

Whitespace cleanups.

The "NetBSD-style" ARCNET headers are used in other BSDs as well, so
just call them "BSD-style".
2003-01-23 07:24:51 +00:00
guy 656dd0eafa Add gencode support for DLT_IEEE802_11_RADIO. 2002-12-12 07:04:17 +00:00
hannes bd4881668c add BPF_ filters for misc. IS-IS PDU Types 2002-12-06 00:01:33 +00:00
hannes 531a7bbb14 fixed BPF generation of OSI over {CHDLC and ATM-LLC} frames 2002-12-04 21:40:13 +00:00
guy d1d0fe1d98 Add support for RFC 2625 IP-over-Fibre Channel, mapping all the Linux
ARPHRD_FC* types to it.
2002-10-18 08:46:13 +00:00
guy 2a22d604c4 Make "lane" behave like "vlan", i.e. have it tweak the interpretation
of packet headers so that, in all expressions after it, the tests assume
LANE encapsulation of packets.  (We also assume the emulated LAN is an
Ethernet LAN, rather than a Token Ring LAN.)

Allow ATM tests to be combined with non-ATM tests in expressions, so
that you can do, for example, "lane and icmp".
2002-08-11 18:27:13 +00:00
guy 6c3e3a0f27 Redo the code generation for 802.11 MAC address tests to reorder the
tests so that better code is generated.
2002-08-08 11:07:27 +00:00
guy 32bfe40547 Token Ring multicasts are handled the same way other 802.x multicasts
are handled, with an I/G bit at the bottom (when handed to the host) of
the first byte of the destination address.
2002-08-08 09:09:58 +00:00
guy 949aa751a1 Add support for operations that test 802.11 SA or DA fields, and for
"wlan" as an alias for "link".
2002-08-08 08:22:45 +00:00
guy a08f7e4faa Support the "inbound" and "outbound" qualifiers on Linux cooked
captures.
2002-08-06 07:35:46 +00:00
guy f3c313fdbd Fix a typo in a comment. 2002-08-06 06:13:20 +00:00
guy 68634dadde Get rid of probably-unnecessary includes of <net/if.h>. 2002-08-05 07:59:43 +00:00
guy bf6b573fc3 Include "IP6_misc.h" even on UNIX if __MINGW32__ is defined, as had
been the case before the previous checkin.
2002-08-02 05:53:53 +00:00
guy 309e386870 Use <pcap-stdinc.h> only on Windows; on UNIX, selectively include, in
each source file, only the headers that file needs, and all the headers
it needs in order to compile on various platforms and not to get any
avoidable compiler warnings on those platforms (as well as any
incomplete structure definitions needed to avoid those warnings).

That also means that <pcap.h> doesn't include <pcap-stdinc.h> on UNIX;
we don't want it to include <pcap-stdinc.h>, at least on UNIX, as doing
so

	1) would mean we'd have to install that, so that programs can
	   build with libpcap

and

	2) would mean that programs including <pcap.h> would drag in a
	   bunch of header files that they don't need.

Put a newline at the end of "inet.c" - the Sun C compiler doesn't like
it if the last line doesn't end with a newline.
2002-08-02 03:44:19 +00:00
risso 6831542ec7 Added support for Win32, based on WinPcap. 2002-08-01 08:33:01 +00:00