dect
/
libpcap
Archived
13
0
Fork 0
Commit Graph

639 Commits

Author SHA1 Message Date
guy 1bd06dd0d5 Add support for Apple's IP-over-IEEE 1394 encapsulation.
Fix a comment.
2004-03-17 19:03:28 +00:00
risso fe6b7f8e33 Avoid a null pointer access in pcap_dump_open if fname is a read only file 2004-03-16 19:27:55 +00:00
guy ce798150ac Beef up some comments, and clean up some other comments. 2004-03-11 23:47:29 +00:00
guy 2f74e436ab Put the LINKTYPE_ values in numerical order, to make it easier to make
sure that all values from 100 to the current maximum value are in use;
put in comments to indicate for what purpose the reserved ones are
reserved.

Note in the "don't just grab a value and use it yourself" comment why
you shouldn't use values below 100 or above the maximum value you see in
the file.
2004-03-11 23:40:54 +00:00
guy bd53902d4a Don't rely on SA_LEN to check whether it's passed a null pointer (it
might be supplied by the OS, and the OS might supply a version that
doesn't check); instead, check for null pointers before doing anything
with the address at all.  This also means we don't supply a netmask if
the address is null; that makes sense, as a netmask makes no sense
without an address.
2004-03-11 23:04:24 +00:00
guy 9876992f2c Add support for 99 as a linktype in a capture file. 2004-03-11 19:56:45 +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 7dea26c4b6 Document "pcap_get_selectable_fd()" - and give some details on the stuff
you might have to do with that FD to work around the brokenness of
"select()"/"poll()" on most versions of most BSDs.
2004-02-28 02:51:26 +00:00
guy f61f1bb9a6 From Shaun Clowes: work around brokenness in the 32-bit compatibility
layer for Linux on IA-64.
2004-02-27 08:03:05 +00:00
hannes 673ea44790 assign DLT_ and LINKTYPE_ 164 to Juniper Networks Inc. 2004-02-11 22:06:58 +00:00
guy 7d3d1094ec AC_LIBOBJ takes the name of an object file without the extension (as the
extension is platform-dependent).
2004-02-09 06:28:19 +00:00
guy 333b8942de We have to define DLT_DOCSIS ourselves, as we include <net/bpf.h> to get
the OS's ioctl definitions, rather than including our own "pcap-bpf.h".
2004-02-09 06:24:42 +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 1c186556cd From Jesper Peterson: fix a couple of endianness problems. 2004-01-30 02:23:53 +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
risso 3d28325423 Added a couple of folders to the include path of Windows VisualC project, in order to properly compile libpcap with Dag support 2004-01-28 14:08:33 +00:00
risso cd98f8f525 Added support for Endace Dag cards under Windows 2004-01-28 14:06:20 +00:00
risso d1a175cf76 Added the definition of MOD_MON, required by WinPcap to work properly with some applications 2004-01-27 09:44:14 +00:00
guy 3c677e1380 Update the date. 2004-01-26 02:11:06 +00:00
guy 5d2a9d1922 Regenerate with autoconf 2.57. 2004-01-14 03:01:25 +00:00
guy c6925e0c52 Autoconf 2.5x won't let you modify LIBOBJS directly; use AC_LIBOBJ to
modify it.

AC_LIBOBJ isn't supported by pre-2.50 autoconf; require 2.50.
2004-01-14 03:00:36 +00:00
guy 1924b620dc Don't use a static variable for the accumulated statistics, accumulate
the statistics in "handle->md.stat", so that the statistics are
maintained correctly if more than one pcap_t is in use.
2004-01-14 01:56:10 +00:00
guy 963cacf276 Put in support for raw "link[N:M]" filtering for DOCSIS. 2004-01-14 01:09:03 +00:00
guy fab5c982f2 From Jesper Peterson:
- don't auto-detect HDLC DLT on serial links, use
	  "pcap_set_datalink()" to choose the link-layer header

	- for ATM, allow selecting SUNATM rather than the default
	  RFC1483 with "pcap_set_datalink()"

	- reformat and otherwise clean up the code.
2004-01-05 18:18:54 +00:00
hannes f2101dbb5d patch from Erik de Castro Lopo <erik.de.castro.lopo@sensorynetworks.com>:
In the Linux kernel the packet statistics are zeroed during each retrieval.
  In contrast, on FreeBSD, the packet statistics are retrived using
  ioctl(BIOCGSTATS):

  The patch adds a static variable to pcap_stats_linux() which
  holds a running total of the packet statistics so that the behaviour
  of pcap_stats() on Linux matches the behaviour of FreeBSD.
2004-01-02 11:25:26 +00:00
itojun 1b3a318d83 typo 2003-12-24 09:14:21 +00:00
itojun 08ef9a54d2 some getaddrinfo(3) can return multiple address against SOCK_STREAM (like tcp
adn sctp).  hardcode to tcp for now.  suz@kame
2003-12-24 08:27:04 +00:00
itojun 86c7fc47a5 TRUE/FALSE may not be defined 2003-12-24 08:26:24 +00:00
guy 6d75a65bb6 Give Takashi Yamamoto credit for the code generator and optimizer fixes. 2003-12-22 00:08:44 +00:00
guy ac7d685b85 "selectable_fd" doesn't make sense on Windows; we no longer set it on
Win32 in "savefile.c", so we no longer need to have it in the structure
on Win32.
2003-12-21 22:00:10 +00:00
guy 175b9d75e8 "selectable_fd" doesn't make sense on Windows. 2003-12-21 21:58:50 +00:00
risso 8e2c26124d Define HAVE_SNPRINTF and HAVE_VSNPRINTF under Windows.
A couple of fixes to the Windows project in order to avoid compilation problems.
2003-12-20 10:28:17 +00:00
risso 671d587acd Define the selectable_fd member of struct pcap in Windows. selectable_fd is needed under Windows for offline captures, if it's not defined, savefile.c refuses to compile. 2003-12-20 10:24:52 +00:00
guy a49d95a110 Add some DLT_ values for private use.
Put in a note indicating that new DLT_ values should *not* be allocated
- people should ask tcpdump-workers for values.
2003-12-20 02:38:23 +00:00
guy 619a9fe31b For devices that we have some reason to believe are real live Ethernet
devices, offer DLT_DOCSIS as one of the choices of link-layer type, and
support setting that type as meaning just "set libpcap's notion of the
link-layer type to DLT_DOCSIS" without telling the driver to use
DLT_DOCSIS.
2003-12-18 23:32:31 +00:00
guy 22a42b8996 Put in very minimal support for DLT_LINUX_IRDA filters. 2003-12-18 20:36:11 +00:00
guy 9aa42d6e5c On Mac OS X 10.3, including <sys/socket.h> eventually drags in a header
file that defines MASK, so when compiling the lexical analyzer, if INET6
is defined you get a redefinition warning.  Use NETMASK rather than MASK
for the token "mask".
2003-12-16 05:19:56 +00:00
guy 6d80740934 Add some missing entries, and fix an entry. 2003-12-15 02:04:14 +00:00
guy be484d29f8 Get rid of a trailing blank line from the previous checkin. 2003-12-15 01:53:39 +00:00
guy fccf57ae3d Add some missing files.
Sort the files/directories.
2003-12-15 01:52:20 +00:00
guy fcadc89577 From Albert Chin <china@thewrittenword.com>: on platforms that lack
"snprintf()", include one in libpcap with the name "pcap_snprintf()", so
applications don't have to supply their own "snprintf()" on those
platforms in order to use libpcap.
2003-12-15 01:35:03 +00:00
guy 026542c235 From Jesper Peterson: updates to handle future DAG API releases. 2003-12-10 09:30:57 +00:00
guy 808a1fd8e1 Reserve two DLT_ values for IBM's use. 2003-12-03 21:34:21 +00:00
guy 4f9b1a6238 Note that "pcap_breakloop()" won't break another thread out of a
blocking call to get packets.
2003-12-01 02:43:45 +00:00
guy 9c1b709295 Note that "ld -shared" is a GCCism. 2003-11-30 22:46:13 +00:00
guy 2fc0876600 Note that, for 32-bit PA-RISC, the shared library suffix is ".sl". 2003-11-30 22:42:25 +00:00
mcr 75ce5b9341 patches to make building RPMs and shared libraries easier. 2003-11-30 04:45:02 +00:00
guy b7a5a71b3a From Gisle Vanem: enter the packet-processing loop even if no packets
were read, so we check "p->break_loop"; that way, we can break out of
the loop even if we get no packets (because of a timeout).

Also, check "p->break_loop" before reading packets from the driver.
2003-11-30 02:31:04 +00:00
guy 42af591c50 When installing a filter:
first check whether BIOCVERSION works;

	then, if so, check whether the version is OK for us;

	then, if so, try to install the filter - if that succeeds, free
	up any userland filter we had installed, if any, and filter in
	the kernel, otherwise fail;

	otherwise, if we couldn't get the version or the version check
	failed, install a userland filter.

That way, we don't install kernel filters unless we know the kernel's
BPF interpreter is OK for us (rather than checking the version *after*
we've already installed the filter), and don't have to worry about that
filter being in the kernel (possibly with an inappropriate interpreter)
if we're filtering in userland.

Clean up the "version isn't OK" message (put in a newline at the end,
and put in "tcpdump:" at the beginning).
2003-11-22 00:32:25 +00:00