From owner-svn-src-vendor@FreeBSD.ORG Thu Oct 28 16:22:14 2010 Return-Path: Delivered-To: svn-src-vendor@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 3BB56106564A; Thu, 28 Oct 2010 16:22:14 +0000 (UTC) (envelope-from rpaulo@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 25DDD8FC08; Thu, 28 Oct 2010 16:22:14 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id o9SGMEEP014318; Thu, 28 Oct 2010 16:22:14 GMT (envelope-from rpaulo@svn.freebsd.org) Received: (from rpaulo@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id o9SGMEI3014306; Thu, 28 Oct 2010 16:22:14 GMT (envelope-from rpaulo@svn.freebsd.org) Message-Id: <201010281622.o9SGMEI3014306@svn.freebsd.org> From: Rui Paulo Date: Thu, 28 Oct 2010 16:22:14 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-vendor@freebsd.org X-SVN-Group: vendor MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r214455 - in vendor/libpcap/dist: . ChmodBPF SUNOS4 Win32 Win32/Include Win32/Include/arpa Win32/Include/net Win32/Prj Win32/Src bpf/net lbl missing msdos net pcap X-BeenThere: svn-src-vendor@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the vendor work area tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 28 Oct 2010 16:22:14 -0000 Author: rpaulo Date: Thu Oct 28 16:22:13 2010 New Revision: 214455 URL: http://svn.freebsd.org/changeset/base/214455 Log: Update libpcap to 1.1.1. Changes: Thu. April 1, 2010. guy@alum.mit.edu. Summary for 1.1.1 libpcap release Update CHANGES to reflect more of the changes in 1.1.0. Fix build on RHEL5. Fix shared library build on AIX. Thu. March 11, 2010. ken@netfunctional.ca/guy@alum.mit.edu. Summary for 1.1.0 libpcap release Add SocketCAN capture support Add Myricom SNF API support Update Endace DAG and ERF support Add support for shared libraries on Solaris, HP-UX, and AIX Build, install, and un-install shared libraries by default; don't build/install shared libraries on platforms we don't support Fix building from a directory other than the source directory Fix compiler warnings and builds on some platforms Update config.guess and config.sub Support monitor mode on mac80211 devices on Linux Fix USB memory-mapped capturing on Linux; it requires a new DLT_ value On Linux, scan /sys/class/net for devices if we have it; scan it, or /proc/net/dev if we don't have /sys/class/net, even if we have getifaddrs(), as it'll find interfaces with no addresses Add limited support for reading pcap-ng files Fix BPF driver-loading error handling on AIX Support getting the full-length interface description on FreeBSD In the lexical analyzer, free up any addrinfo structure we got back from getaddrinfo(). Add support for BPF and libdlpi in OpenSolaris (and SXCE) Hyphenate "link-layer" everywhere Add /sys/kernel/debug/usb/usbmon to the list of usbmon locations In pcap_read_linux_mmap(), if there are no frames available, call poll() even if we're in non-blocking mode, so we pick up errors, and check for the errors in question. Note that poll() works on BPF devices is Snow Leopard If an ENXIO or ENETDOWN is received, it may mean the device has gone away. Deal with it. For BPF, raise the default capture buffer size to from 32k to 512k Support ps_ifdrop on Linux Added a bunch of #ifdef directives to make wpcap.dll (WinPcap) compile under cygwin. Changes to Linux mmapped captures. Fix bug where create_ring would fail for particular snaplen and buffer size combinations Update pcap-config so that it handles libpcap requiring additional libraries Add workaround for threadsafeness on Windows Add missing mapping for DLT_ENC <-> LINKTYPE_ENC DLT: Add DLT_CAN_SOCKETCAN DLT: Add Solaris ipnet Don't check for DLT_IPNET if it's not defined Add link-layer types for Fibre Channel FC-2 Add link-layer types for Wireless HART Add link-layer types for AOS Add link-layer types for DECT Autoconf fixes (AIX, HP-UX, OSF/1, Tru64 cleanups) Install headers unconditionally, and include vlan.h/bluetooth.h if enabled Autoconf fixes+cleanup Support enabling/disabling bluetooth (--{en,dis}able-bluetooth) Support disabling SITA support (--without-sita) Return -1 on failure to create packet ring (if supported but creation failed) Fix handling of 'any' device, so that it can be opened, and no longer attempt to open it in Monitor mode Add support for snapshot length for USB Memory-Mapped Interface Fix configure and build on recent Linux kernels Fix memory-mapped Linux capture to support pcap_next() and pcap_next_ex() Fixes for Linux USB capture DLT: Add DLT_LINUX_EVDEV DLT: Add DLT_GSMTAP_UM DLT: Add DLT_GSMTAP_ABIS Added: vendor/libpcap/dist/ChmodBPF/ vendor/libpcap/dist/ChmodBPF/ChmodBPF (contents, props changed) vendor/libpcap/dist/ChmodBPF/StartupParameters.plist vendor/libpcap/dist/README.Win32 vendor/libpcap/dist/README.aix vendor/libpcap/dist/README.dag vendor/libpcap/dist/README.hpux vendor/libpcap/dist/README.linux vendor/libpcap/dist/README.macosx vendor/libpcap/dist/README.septel vendor/libpcap/dist/README.sita vendor/libpcap/dist/README.tru64 vendor/libpcap/dist/SUNOS4/ vendor/libpcap/dist/SUNOS4/nit_if.o.sparc (contents, props changed) vendor/libpcap/dist/SUNOS4/nit_if.o.sun3 (contents, props changed) vendor/libpcap/dist/SUNOS4/nit_if.o.sun4c.4.0.3c (contents, props changed) vendor/libpcap/dist/Win32/ vendor/libpcap/dist/Win32/Include/ vendor/libpcap/dist/Win32/Include/Gnuc.h (contents, props changed) vendor/libpcap/dist/Win32/Include/addrinfo.h (contents, props changed) vendor/libpcap/dist/Win32/Include/arpa/ vendor/libpcap/dist/Win32/Include/arpa/nameser.h (contents, props changed) vendor/libpcap/dist/Win32/Include/bittypes.h (contents, props changed) vendor/libpcap/dist/Win32/Include/cdecl_ext.h (contents, props changed) vendor/libpcap/dist/Win32/Include/inetprivate.h (contents, props changed) vendor/libpcap/dist/Win32/Include/ip6_misc.h (contents, props changed) vendor/libpcap/dist/Win32/Include/net/ vendor/libpcap/dist/Win32/Include/net/if.h (contents, props changed) vendor/libpcap/dist/Win32/Include/net/netdb.h (contents, props changed) vendor/libpcap/dist/Win32/Include/net/paths.h (contents, props changed) vendor/libpcap/dist/Win32/Include/sockstorage.h (contents, props changed) vendor/libpcap/dist/Win32/Prj/ vendor/libpcap/dist/Win32/Prj/libpcap.dsp vendor/libpcap/dist/Win32/Prj/libpcap.dsw vendor/libpcap/dist/Win32/Src/ vendor/libpcap/dist/Win32/Src/ffs.c (contents, props changed) vendor/libpcap/dist/Win32/Src/gai_strerror.c (contents, props changed) vendor/libpcap/dist/Win32/Src/getaddrinfo.c (contents, props changed) vendor/libpcap/dist/Win32/Src/getnetbynm.c (contents, props changed) vendor/libpcap/dist/Win32/Src/getnetent.c (contents, props changed) vendor/libpcap/dist/Win32/Src/getopt.c (contents, props changed) vendor/libpcap/dist/Win32/Src/getservent.c (contents, props changed) vendor/libpcap/dist/Win32/Src/inet_aton.c (contents, props changed) vendor/libpcap/dist/Win32/Src/inet_net.c (contents, props changed) vendor/libpcap/dist/Win32/Src/inet_pton.c (contents, props changed) vendor/libpcap/dist/msdos/ vendor/libpcap/dist/msdos/bin2c.c (contents, props changed) vendor/libpcap/dist/msdos/common.dj vendor/libpcap/dist/msdos/makefile (contents, props changed) vendor/libpcap/dist/msdos/makefile.dj (contents, props changed) vendor/libpcap/dist/msdos/makefile.wc (contents, props changed) vendor/libpcap/dist/msdos/ndis2.c (contents, props changed) vendor/libpcap/dist/msdos/ndis2.h (contents, props changed) vendor/libpcap/dist/msdos/ndis_0.asm vendor/libpcap/dist/msdos/pkt_rx0.asm vendor/libpcap/dist/msdos/pkt_rx1.s (contents, props changed) vendor/libpcap/dist/msdos/pktdrvr.c (contents, props changed) vendor/libpcap/dist/msdos/pktdrvr.h (contents, props changed) vendor/libpcap/dist/msdos/readme.dos vendor/libpcap/dist/opentest.c (contents, props changed) vendor/libpcap/dist/org.tcpdump.chmod_bpf.plist vendor/libpcap/dist/pcap-can-linux.c (contents, props changed) vendor/libpcap/dist/pcap-can-linux.h (contents, props changed) vendor/libpcap/dist/pcap-common.c (contents, props changed) vendor/libpcap/dist/pcap-common.h (contents, props changed) vendor/libpcap/dist/pcap-snf.c (contents, props changed) vendor/libpcap/dist/pcap-snf.h (contents, props changed) vendor/libpcap/dist/pcap/ipnet.h (contents, props changed) vendor/libpcap/dist/selpolltest.c (contents, props changed) vendor/libpcap/dist/sf-pcap-ng.c (contents, props changed) vendor/libpcap/dist/sf-pcap-ng.h (contents, props changed) vendor/libpcap/dist/sf-pcap.c (contents, props changed) vendor/libpcap/dist/sf-pcap.h (contents, props changed) Deleted: vendor/libpcap/dist/acconfig.h vendor/libpcap/dist/net/bpf_filter.c Modified: vendor/libpcap/dist/CHANGES vendor/libpcap/dist/CREDITS vendor/libpcap/dist/INSTALL.txt vendor/libpcap/dist/Makefile.in vendor/libpcap/dist/README vendor/libpcap/dist/TODO vendor/libpcap/dist/VERSION vendor/libpcap/dist/aclocal.m4 vendor/libpcap/dist/arcnet.h vendor/libpcap/dist/atmuni31.h vendor/libpcap/dist/bpf/net/bpf_filter.c vendor/libpcap/dist/bpf_dump.c vendor/libpcap/dist/bpf_image.c vendor/libpcap/dist/config.guess vendor/libpcap/dist/config.h.in vendor/libpcap/dist/config.sub vendor/libpcap/dist/configure vendor/libpcap/dist/configure.in vendor/libpcap/dist/dlpisubs.c vendor/libpcap/dist/dlpisubs.h vendor/libpcap/dist/etherent.c vendor/libpcap/dist/ethertype.h vendor/libpcap/dist/fad-getad.c vendor/libpcap/dist/fad-gifc.c vendor/libpcap/dist/fad-glifc.c vendor/libpcap/dist/fad-null.c vendor/libpcap/dist/fad-win32.c vendor/libpcap/dist/filtertest.c vendor/libpcap/dist/gencode.c vendor/libpcap/dist/gencode.h vendor/libpcap/dist/grammar.y vendor/libpcap/dist/inet.c vendor/libpcap/dist/lbl/os-aix4.h vendor/libpcap/dist/lbl/os-hpux11.h vendor/libpcap/dist/lbl/os-osf4.h vendor/libpcap/dist/lbl/os-osf5.h vendor/libpcap/dist/lbl/os-solaris2.h vendor/libpcap/dist/lbl/os-sunos4.h vendor/libpcap/dist/lbl/os-ultrix4.h vendor/libpcap/dist/llc.h vendor/libpcap/dist/missing/snprintf.c vendor/libpcap/dist/nametoaddr.c vendor/libpcap/dist/nlpid.h vendor/libpcap/dist/optimize.c vendor/libpcap/dist/pcap-bpf.c vendor/libpcap/dist/pcap-bpf.h vendor/libpcap/dist/pcap-bt-linux.c vendor/libpcap/dist/pcap-bt-linux.h vendor/libpcap/dist/pcap-config.1 vendor/libpcap/dist/pcap-config.in vendor/libpcap/dist/pcap-dag.c vendor/libpcap/dist/pcap-dag.h vendor/libpcap/dist/pcap-dlpi.c vendor/libpcap/dist/pcap-dos.c vendor/libpcap/dist/pcap-dos.h vendor/libpcap/dist/pcap-enet.c vendor/libpcap/dist/pcap-filter.manmisc.in vendor/libpcap/dist/pcap-int.h vendor/libpcap/dist/pcap-libdlpi.c vendor/libpcap/dist/pcap-linktype.manmisc.in vendor/libpcap/dist/pcap-linux.c vendor/libpcap/dist/pcap-namedb.h vendor/libpcap/dist/pcap-nit.c vendor/libpcap/dist/pcap-null.c vendor/libpcap/dist/pcap-pf.c vendor/libpcap/dist/pcap-savefile.manfile.in vendor/libpcap/dist/pcap-septel.c vendor/libpcap/dist/pcap-septel.h vendor/libpcap/dist/pcap-sita.html vendor/libpcap/dist/pcap-snit.c vendor/libpcap/dist/pcap-snoop.c vendor/libpcap/dist/pcap-stdinc.h vendor/libpcap/dist/pcap-usb-linux.c vendor/libpcap/dist/pcap-usb-linux.h vendor/libpcap/dist/pcap-win32.c vendor/libpcap/dist/pcap.3pcap.in vendor/libpcap/dist/pcap.c vendor/libpcap/dist/pcap.h vendor/libpcap/dist/pcap/bluetooth.h vendor/libpcap/dist/pcap/bpf.h vendor/libpcap/dist/pcap/namedb.h vendor/libpcap/dist/pcap/pcap.h vendor/libpcap/dist/pcap/sll.h vendor/libpcap/dist/pcap/usb.h vendor/libpcap/dist/pcap/vlan.h vendor/libpcap/dist/pcap_activate.3pcap vendor/libpcap/dist/pcap_breakloop.3pcap vendor/libpcap/dist/pcap_can_set_rfmon.3pcap vendor/libpcap/dist/pcap_close.3pcap vendor/libpcap/dist/pcap_compile.3pcap.in vendor/libpcap/dist/pcap_create.3pcap vendor/libpcap/dist/pcap_datalink.3pcap.in vendor/libpcap/dist/pcap_datalink_name_to_val.3pcap vendor/libpcap/dist/pcap_datalink_val_to_name.3pcap vendor/libpcap/dist/pcap_dump.3pcap vendor/libpcap/dist/pcap_dump_close.3pcap vendor/libpcap/dist/pcap_dump_file.3pcap vendor/libpcap/dist/pcap_dump_flush.3pcap vendor/libpcap/dist/pcap_dump_ftell.3pcap vendor/libpcap/dist/pcap_dump_open.3pcap.in vendor/libpcap/dist/pcap_file.3pcap vendor/libpcap/dist/pcap_fileno.3pcap vendor/libpcap/dist/pcap_findalldevs.3pcap vendor/libpcap/dist/pcap_free_datalinks.3pcap vendor/libpcap/dist/pcap_freealldevs.3pcap vendor/libpcap/dist/pcap_freecode.3pcap vendor/libpcap/dist/pcap_get_selectable_fd.3pcap vendor/libpcap/dist/pcap_geterr.3pcap vendor/libpcap/dist/pcap_inject.3pcap vendor/libpcap/dist/pcap_is_swapped.3pcap vendor/libpcap/dist/pcap_lib_version.3pcap vendor/libpcap/dist/pcap_list_datalinks.3pcap.in vendor/libpcap/dist/pcap_lookupdev.3pcap vendor/libpcap/dist/pcap_lookupnet.3pcap vendor/libpcap/dist/pcap_loop.3pcap vendor/libpcap/dist/pcap_major_version.3pcap vendor/libpcap/dist/pcap_next_ex.3pcap vendor/libpcap/dist/pcap_offline_filter.3pcap vendor/libpcap/dist/pcap_open_dead.3pcap.in vendor/libpcap/dist/pcap_open_live.3pcap vendor/libpcap/dist/pcap_open_offline.3pcap.in vendor/libpcap/dist/pcap_set_buffer_size.3pcap vendor/libpcap/dist/pcap_set_datalink.3pcap vendor/libpcap/dist/pcap_set_promisc.3pcap vendor/libpcap/dist/pcap_set_rfmon.3pcap vendor/libpcap/dist/pcap_set_snaplen.3pcap vendor/libpcap/dist/pcap_set_timeout.3pcap vendor/libpcap/dist/pcap_setdirection.3pcap vendor/libpcap/dist/pcap_setfilter.3pcap vendor/libpcap/dist/pcap_setnonblock.3pcap vendor/libpcap/dist/pcap_snapshot.3pcap vendor/libpcap/dist/pcap_stats.3pcap vendor/libpcap/dist/pcap_statustostr.3pcap vendor/libpcap/dist/pcap_strerror.3pcap vendor/libpcap/dist/ppp.h vendor/libpcap/dist/runlex.sh vendor/libpcap/dist/savefile.c vendor/libpcap/dist/scanner.l vendor/libpcap/dist/sunatmpos.h Modified: vendor/libpcap/dist/CHANGES ============================================================================== --- vendor/libpcap/dist/CHANGES Thu Oct 28 15:43:14 2010 (r214454) +++ vendor/libpcap/dist/CHANGES Thu Oct 28 16:22:13 2010 (r214455) @@ -1,4 +1,77 @@ -@(#) $Header: /tcpdump/master/libpcap/CHANGES,v 1.67.2.4 2008-10-28 00:27:42 ken Exp $ (LBL) +Thu. April 1, 2010. guy@alum.mit.edu. +Summary for 1.1.1 libpcap release + Update CHANGES to reflect more of the changes in 1.1.0. + Fix build on RHEL5. + Fix shared library build on AIX. + +Thu. March 11, 2010. ken@netfunctional.ca/guy@alum.mit.edu. +Summary for 1.1.0 libpcap release + Add SocketCAN capture support + Add Myricom SNF API support + Update Endace DAG and ERF support + Add support for shared libraries on Solaris, HP-UX, and AIX + Build, install, and un-install shared libraries by default; + don't build/install shared libraries on platforms we don't support + Fix building from a directory other than the source directory + Fix compiler warnings and builds on some platforms + Update config.guess and config.sub + Support monitor mode on mac80211 devices on Linux + Fix USB memory-mapped capturing on Linux; it requires a new DLT_ + value + On Linux, scan /sys/class/net for devices if we have it; scan + it, or /proc/net/dev if we don't have /sys/class/net, even if + we have getifaddrs(), as it'll find interfaces with no + addresses + Add limited support for reading pcap-ng files + Fix BPF driver-loading error handling on AIX + Support getting the full-length interface description on FreeBSD + In the lexical analyzer, free up any addrinfo structure we got back + from getaddrinfo(). + Add support for BPF and libdlpi in OpenSolaris (and SXCE) + Hyphenate "link-layer" everywhere + Add /sys/kernel/debug/usb/usbmon to the list of usbmon locations + In pcap_read_linux_mmap(), if there are no frames available, call + poll() even if we're in non-blocking mode, so we pick up + errors, and check for the errors in question. + Note that poll() works on BPF devices is Snow Leopard + If an ENXIO or ENETDOWN is received, it may mean the device has + gone away. Deal with it. + For BPF, raise the default capture buffer size to from 32k to 512k + Support ps_ifdrop on Linux + Added a bunch of #ifdef directives to make wpcap.dll (WinPcap) compile + under cygwin. + Changes to Linux mmapped captures. + Fix bug where create_ring would fail for particular snaplen and + buffer size combinations + Update pcap-config so that it handles libpcap requiring + additional libraries + Add workaround for threadsafeness on Windows + Add missing mapping for DLT_ENC <-> LINKTYPE_ENC + DLT: Add DLT_CAN_SOCKETCAN + DLT: Add Solaris ipnet + Don't check for DLT_IPNET if it's not defined + Add link-layer types for Fibre Channel FC-2 + Add link-layer types for Wireless HART + Add link-layer types for AOS + Add link-layer types for DECT + Autoconf fixes (AIX, HP-UX, OSF/1, Tru64 cleanups) + Install headers unconditionally, and include vlan.h/bluetooth.h if + enabled + Autoconf fixes+cleanup + Support enabling/disabling bluetooth (--{en,dis}able-bluetooth) + Support disabling SITA support (--without-sita) + Return -1 on failure to create packet ring (if supported but + creation failed) + Fix handling of 'any' device, so that it can be opened, and no longer + attempt to open it in Monitor mode + Add support for snapshot length for USB Memory-Mapped Interface + Fix configure and build on recent Linux kernels + Fix memory-mapped Linux capture to support pcap_next() and + pcap_next_ex() + Fixes for Linux USB capture + DLT: Add DLT_LINUX_EVDEV + DLT: Add DLT_GSMTAP_UM + DLT: Add DLT_GSMTAP_ABIS Mon. October 27, 2008. ken@netfunctional.ca. Summary for 1.0.0 libpcap release Compile with IPv6 support by default @@ -12,7 +85,10 @@ Mon. October 27, 2008. ken@netfuncti Variable length 802.11 header support X2E data type support SITA ACN Interface support - see README.sita + Support for memory-mapped capture on Linux Support for zerocopy BPF on platforms that support it + Support for setting buffer size when opening devices + Support for setting monitor mode when opening 802.11 devices Better support for dealing with VLAN tagging/stripping on Linux Fix dynamic library support on OSX Return PCAP_ERROR_IFACE_NOT_UP if the interface isn't 'UP', so applications @@ -22,7 +98,7 @@ Mon. October 27, 2008. ken@netfuncti On Linux, ignore ENETDOWN so we can continue to capture packets if the interface goes down and comes back up again. On Linux, support new tpacket frame headers (2.6.27+) - On Mac OS X, add scripts for changing permissions on /dev/pbf* and launchd plist + On Mac OS X, add scripts for changing permissions on /dev/bpf* and launchd plist On Solaris, support 'passive mode' on systems that support it Fixes to autoconf and general build environment Man page reorganization + cleanup Modified: vendor/libpcap/dist/CREDITS ============================================================================== --- vendor/libpcap/dist/CREDITS Thu Oct 28 15:43:14 2010 (r214454) +++ vendor/libpcap/dist/CREDITS Thu Oct 28 16:22:13 2010 (r214455) @@ -10,9 +10,10 @@ The current maintainers: Additional people who have contributed patches: Alan Bawden + Albert Chin Alexander 'Leo' Bergolth Alexey Kuznetsov - Albert Chin + Alon Bar-Lev Andrew Brown Antti Kantee Arien Vijn @@ -23,24 +24,28 @@ Additional people who have contributed p Charles M. Hannum Chris G. Demetriou Chris Lightfoot + Chris Maynard Chris Pepper + Christian Bell Christian Peron Daniele Orlandi - Darren Reed + Darren Reed David Kaelbling David Young Dean Gaudet Don Ebright Dug Song + Dustin Spicuzza Eric Anderson Erik de Castro Lopo + Felix Obenhuber Florent Drouin Franz Schaefer Fulko Hew + Fumiyuki Shimizu Gianluca Varenni Gilbert Hoyek Gisle Vanem - Gisle Vanem Graeme Hewson Greg Stark Greg Troxel @@ -53,11 +58,13 @@ Additional people who have contributed p Jason R. Thorpe Javier Achirica Jean Tourrilhes + Jean-Louis Charton Jefferson Ogata Jesper Peterson Joerg Mayer John Bankier Jon Lindgren + Jon Smirl Juergen Schoenwaelder Jung-uk Kim Kazushi Sugyo @@ -67,19 +74,22 @@ Additional people who have contributed p Krzysztof Halasa Lorenzo Cavallaro Loris Degioanni - Love Hörnquist-Åstrand + Love Hörnquist-Ã…strand Luis Martin Garcia Maciej W. Rozycki Marcus Felipe Pereira Mark C. Brown Mark Pizzolato + Markus Mayer Martin Husemann + Márton Németh Matthew Luckie Max Laier Mike Frysinger Mike Kershaw Mike Wiacek Monroe Williams + N. Leiten Nicolas Dade Octavian Cerna Olaf Kirch @@ -93,15 +103,20 @@ Additional people who have contributed p Pawel Pokrywka Peter Fales Peter Jeremy + Peter Volkov Phil Wood Rafal Maszkowski Richard Stearn Rick Jones + Robert Edmonds + Roberto Mariani + Romain Francoise Sagun Shakya Scott Barron Scott Gifford Sebastian Krahmer + Sebastien Roy Sepherosa Ziehau Shaun Clowes Solomon Peachy @@ -109,12 +124,16 @@ Additional people who have contributed p Stephen Donnelly Takashi Yamamoto Tanaka Shin-ya + Tobias Poschwatta Tony Li Torsten Landschoff Uns Lider Uwe Girlich + Wesley Shields Xianjie Zhang + Xin Li Yen Yen Lim + Yvan Vanhullebus Yoann Vandoorselaere The original LBL crew: Added: vendor/libpcap/dist/ChmodBPF/ChmodBPF ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ vendor/libpcap/dist/ChmodBPF/ChmodBPF Thu Oct 28 16:22:13 2010 (r214455) @@ -0,0 +1,33 @@ +#! /bin/sh + +. /etc/rc.common + +StartService () +{ + # + # Unfortunately, Mac OS X's devfs is based on the old FreeBSD + # one, not the current one, so there's no way to configure it + # to create BPF devices with particular owners or groups. + # This startup item will make it owned by the admin group, + # with permissions rw-rw----, so that anybody in the admin + # group can use programs that capture or send raw packets. + # + # Change this as appropriate for your site, e.g. to make + # it owned by a particular user without changing the permissions, + # so only that user and the super-user can capture or send raw + # packets, or give it the permissions rw-r-----, so that + # only the super-user can send raw packets but anybody in the + # admin group can capture packets. + # + chgrp admin /dev/bpf* + chmod g+rw /dev/bpf* +} + +StopService () +{ + return 0; +} + +RestartService () { StartService; } + +RunService "$1" Added: vendor/libpcap/dist/ChmodBPF/StartupParameters.plist ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ vendor/libpcap/dist/ChmodBPF/StartupParameters.plist Thu Oct 28 16:22:13 2010 (r214455) @@ -0,0 +1,4 @@ +{ + Description = "Change BPF permissions"; + Provides = ("ChmodBPF"); +} Modified: vendor/libpcap/dist/INSTALL.txt ============================================================================== --- vendor/libpcap/dist/INSTALL.txt Thu Oct 28 15:43:14 2010 (r214454) +++ vendor/libpcap/dist/INSTALL.txt Thu Oct 28 16:22:13 2010 (r214455) @@ -1,4 +1,4 @@ -@(#) $Header: /tcpdump/master/libpcap/INSTALL.txt,v 1.21.2.8 2008-06-12 20:25:38 guy Exp $ (LBL) +@(#) $Header: /tcpdump/master/libpcap/INSTALL.txt,v 1.29 2008-06-12 20:21:51 guy Exp $ (LBL) To build libpcap, run "./configure" (a shell script). The configure script will determine your system attributes and generate an Modified: vendor/libpcap/dist/Makefile.in ============================================================================== --- vendor/libpcap/dist/Makefile.in Thu Oct 28 15:43:14 2010 (r214454) +++ vendor/libpcap/dist/Makefile.in Thu Oct 28 16:22:13 2010 (r214455) @@ -17,7 +17,7 @@ # WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED WARRANTIES OF # MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. # -# @(#) $Header: /tcpdump/master/libpcap/Makefile.in,v 1.108.2.28 2008-10-23 22:13:21 guy Exp $ (LBL) +# @(#) $Header: /tcpdump/master/libpcap/Makefile.in,v 1.142 2008-11-22 17:30:24 guy Exp $ (LBL) # # Various configurable paths (remember to edit Makefile.in, not Makefile) @@ -44,14 +44,17 @@ VPATH = @srcdir@ # You shouldn't need to edit anything below. # +LD = /usr/bin/ld CC = @CC@ CCOPT = @V_CCOPT@ INCLS = -I. @V_INCLS@ DEFS = @DEFS@ @V_DEFS@ -LIBS = @V_LIBS@ -DAGLIBS = @DAGLIBS@ -DEPLIBS = @DEPLIBS@ +ADDLOBJS = @ADDLOBJS@ +ADDLARCHIVEOBJS = @ADDLARCHIVEOBJS@ +LIBS = @LIBS@ +LDFLAGS = @LDFLAGS@ DYEXT = @DYEXT@ +V_RPATH_OPT = @V_RPATH_OPT@ PROG=libpcap # Standard CFLAGS @@ -77,12 +80,13 @@ YACC = @V_YACC@ @rm -f $@ $(CC) $(CFLAGS) -c $(srcdir)/$*.c -PSRC = pcap-@V_PCAP@.c @USB_SRC@ @BT_SRC@ +PSRC = pcap-@V_PCAP@.c @USB_SRC@ @BT_SRC@ @CAN_SRC@ FSRC = fad-@V_FINDALLDEVS@.c SSRC = @SSRC@ -CSRC = pcap.c inet.c gencode.c optimize.c nametoaddr.c \ - etherent.c savefile.c bpf_filter.c bpf_image.c bpf_dump.c -GENSRC = scanner.c grammar.c version.c +CSRC = pcap.c inet.c gencode.c optimize.c nametoaddr.c etherent.c \ + savefile.c sf-pcap.c sf-pcap-ng.c pcap-common.c \ + bpf_image.c bpf_dump.c +GENSRC = scanner.c grammar.c bpf_filter.c version.c LIBOBJS = @LIBOBJS@ SRC = $(PSRC) $(FSRC) $(CSRC) $(SSRC) $(GENSRC) @@ -90,8 +94,20 @@ SRC = $(PSRC) $(FSRC) $(CSRC) $(SSRC) $( # We would like to say "OBJ = $(SRC:.c=.o)" but Ultrix's make cannot # hack the extra indirection OBJ = $(PSRC:.c=.o) $(FSRC:.c=.o) $(CSRC:.c=.o) $(SSRC:.c=.o) $(GENSRC:.c=.o) $(LIBOBJS) -HDR = \ - acconfig.h \ +PUBHDR = \ + pcap.h \ + pcap-bpf.h \ + pcap-namedb.h \ + pcap/bpf.h \ + pcap/bluetooth.h \ + pcap/ipnet.h \ + pcap/namedb.h \ + pcap/pcap.h \ + pcap/sll.h \ + pcap/vlan.h \ + pcap/usb.h + +HDR = $(PUBHDR) \ arcnet.h \ atmuni31.h \ ethertype.h \ @@ -99,30 +115,23 @@ HDR = \ ieee80211.h \ llc.h \ nlpid.h \ - pcap/bluetooth.h \ - pcap/bpf.h \ - pcap/namedb.h \ - pcap/pcap.h \ - pcap/sll.h \ - pcap/usb.h \ - pcap/vlan.h \ - pcap.h \ + pcap-common.h \ pcap-int.h \ - pcap-namedb.h \ pcap-stdinc.h \ ppp.h \ + sf-pcap.h \ + sf-pcap-ng.h \ sunatmpos.h GENHDR = \ scanner.h tokdefs.h version.h -TAGHDR = \ - pcap-bpf.h - TAGFILES = \ - $(SRC) $(HDR) $(TAGHDR) + $(SRC) $(HDR) -CLEANFILES = $(OBJ) libpcap.a $(GENSRC) $(GENHDR) lex.yy.c +CLEANFILES = $(OBJ) libpcap.* filtertest findalldevstest selpolltest \ + opentest $(PROG)-`cat $(srcdir)/VERSION`.tar.gz $(GENSRC) $(GENHDR) \ + lex.yy.c pcap-config MAN1 = pcap-config.1 @@ -254,13 +263,14 @@ EXTRA_DIST = \ msdos/pktdrvr.c \ msdos/pktdrvr.h \ msdos/readme.dos \ - net/bpf_filter.c \ + opentest.c \ org.tcpdump.chmod_bpf.plist \ packaging/pcap.spec.in \ pcap-bpf.c \ - pcap-bpf.h \ pcap-bt-linux.c \ pcap-bt-linux.h \ + pcap-can-linux.c \ + pcap-can-linux.h \ pcap-config.in \ pcap-dag.c \ pcap-dag.h \ @@ -280,6 +290,8 @@ EXTRA_DIST = \ pcap-sita.h \ pcap-sita.c \ pcap-sita.html \ + pcap-snf.c \ + pcap-snf.h \ pcap-snit.c \ pcap-snoop.c \ pcap-usb-linux.c \ @@ -287,6 +299,7 @@ EXTRA_DIST = \ pcap-win32.c \ runlex.sh \ scanner.l \ + selpolltest.c \ Win32/Include/Gnuc.h \ Win32/Include/addrinfo.h \ Win32/Include/bittypes.h \ @@ -311,42 +324,94 @@ EXTRA_DIST = \ Win32/Src/inet_net.c \ Win32/Src/inet_pton.c -all: libpcap.a pcap-config +all: libpcap.a shared pcap-config libpcap.a: $(OBJ) @rm -f $@ - $(AR) rc $@ $(OBJ) $(LIBS) + ar rc $@ $(OBJ) $(ADDLARCHIVEOBJS) $(RANLIB) $@ shared: libpcap.$(DYEXT) -# -# XXX - this works with GNU ld, but won't necessarily work with native -# ld on, for example, various SVR4-flavored platforms, or Digital UNIX. -# libpcap.so: $(OBJ) @rm -f $@ - $(CC) -shared -Wl,-soname,$@.1 -o $@.`cat $(srcdir)/VERSION` $(OBJ) $(DAGLIBS) + VER=`cat $(srcdir)/VERSION`; \ + MAJOR_VER=`sed 's/\([0-9][0-9]*\)\..*/\1/' $(srcdir)/VERSION`; \ + @V_SHLIB_CMD@ @V_SHLIB_OPT@ @V_SONAME_OPT@$@.$$MAJOR_VER $(LDFLAGS) \ + -o $@.$$VER $(OBJ) $(ADDLOBJS) $(LIBS) # # The following rule succeeds, but the result is untested. # -# XXX - OS X installs the library as "libpcap.A.dylib", with that as the -# install_name, and sets the current version to 1 as well. VERSION -# might contain a not-purely-numeric version number, but -# -current_version requires a purely numeric version, so this won't -# work with top-of-tree builds. +# In Mac OS X, the libpcap dylib has the name "libpcap.A.dylib", with +# its full path as the install_name, and with the compatibility and +# current version both set to 1. The compatibility version is set to +# 1 so that programs built with a newer version of the library will run +# against older versions; multi-platform software probably will fail if +# it uses APIs added in the newer version, but Mac OS X-specific software +# will use weak linking and check at run time whether those APIs are +# available. +# +# We also use "A" as the major version, and 1 as the compatibility version, +# but set the current version to the value in VERSION, with any non-numeric +# stuff stripped off (the compatibility and current version must be of the +# form X[.Y[.Z]], with Y and Z possibly absent, and with all components +# numeric). # libpcap.dylib: $(OBJ) rm -f libpcap*.dylib - $(CC) -dynamiclib -undefined error -o libpcap.`cat $(srcdir)/VERSION`.dylib $(OBJ) \ - -install_name $(libdir)/libpcap.A.dylib \ - -compatibility_version 1 \ - -current_version `sed 's/[^0-9.].*$$//' $(srcdir)/VERSION` + VER=`cat $(srcdir)/VERSION`; \ + MAJOR_VER=A; \ + COMPAT_VER=1; \ + CURRENT_VER=`sed 's/[^0-9.].*$$//' $(srcdir)/VERSION`; \ + $(CC) -dynamiclib -undefined error $(LDFLAGS) \ + -o libpcap.$$VER.dylib $(OBJ) $(ADDLOBJS) $(LIBS) \ + -install_name $(libdir)/libpcap.$$MAJOR_VER.dylib \ + -compatibility_version $$COMPAT_VER \ + -current_version $$CURRENT_VER + +# +# The HP-UX linker manual says that the convention for a versioned library +# is libXXX.{number}, not libXXX.sl.{number}. That appears to be the case +# on at least one HP-UX 11.00 system; libXXX.sl is a symlink to +# libXXX.{number}. +# +# The manual also says "library-level versioning" (think "sonames") was +# added in HP-UX 10.0. +# +# XXX - this assumes we're using the HP linker, rather than the GNU +# linker, even with GCC. +# +libpcap.sl: $(OBJ) + @MAJOR_VER=`sed 's/\([0-9][0-9]*\)\..*/\1/' $(srcdir)/VERSION`; \ + rm -f libpcap.$$MAJOR_VER + MAJOR_VER=`sed 's/\([0-9][0-9]*\)\..*/\1/' $(srcdir)/VERSION`; \ + ld -b $(LDFLAGS) -o libpcap.$$MAJOR_VER +h libpcap.$$MAJOR_VER \ + $(OBJ) $(ADDLOBJS) $(LIBS) + +# +# AIX is different from everybody else. A shared library is an archive +# library with one or more shared-object components. We still build a +# normal static archive library on AIX, for the benefit of the traditional +# scheme of building libpcap and tcpdump in subdirectories of the +# same directory, with tcpdump statically linked with the libpcap +# in question, but we also build a shared library as "libpcap.shareda" +# and install *it*, rather than the static library, as "libpcap.a". +# +libpcap.shareda: $(OBJ) + @rm -f $@ shr.o + $(CC) @V_SHLIB_OPT@ -o shr.o $(OBJ) $(ADDLOBJS) $(LDFLAGS) $(LIBS) + ar rc $@ shr.o + +# +# For platforms that don't support shared libraries (or on which we +# don't support shared libraries). +# +libpcap.none: scanner.c: $(srcdir)/scanner.l @rm -f $@ - ./runlex.sh $(LEX) -o$@ $< + $(srcdir)/runlex.sh $(LEX) -o$@ $< scanner.o: scanner.c tokdefs.h $(CC) $(CFLAGS) -c scanner.c @@ -372,7 +437,13 @@ snprintf.o: $(srcdir)/missing/snprintf.c version.c: $(srcdir)/VERSION @rm -f $@ - sed -e 's/.*/char pcap_version[] = "&";/' $(srcdir)/VERSION > $@ + if grep GIT ${srcdir}/VERSION >/dev/null; then \ + read ver <${srcdir}/VERSION; \ + echo $$ver | tr -d '\012'; \ + date +_%Y_%m_%d; \ + else \ + cat ${srcdir}/VERSION; \ + fi | sed -e 's/.*/char pcap_version[] = "&";/' > $@ # # NOTE: this really is supposed to be static; importing a string @@ -383,7 +454,13 @@ version.c: $(srcdir)/VERSION # version.h: $(srcdir)/VERSION @rm -f $@ - sed -e 's/.*/static const char pcap_version_string[] = "libpcap version &";/' $(srcdir)/VERSION > $@ + if grep GIT ${srcdir}/VERSION >/dev/null; then \ + read ver <${srcdir}/VERSION; \ + echo $$ver | tr -d '\012'; \ + date +_%Y_%m_%d; \ + else \ + cat ${srcdir}/VERSION; \ + fi | sed -e 's/.*/static const char pcap_version_string[] = "libpcap version &";/' > $@ bpf_filter.c: $(srcdir)/bpf/net/bpf_filter.c rm -f bpf_filter.c @@ -395,12 +472,13 @@ bpf_filter.o: bpf_filter.c # # Generate the pcap-config script. # -pcap-config: pcap-config.in Makefile +pcap-config: $(srcdir)/pcap-config.in @rm -f $@ $@.tmp sed -e 's|@includedir[@]|$(includedir)|g' \ -e 's|@libdir[@]|$(libdir)|g' \ - -e 's|@DEPLIBS[@]|$(DEPLIBS)|g' \ - pcap-config.in >$@.tmp + -e 's|@LIBS[@]|$(LIBS)|g' \ + -e 's|@V_RPATH_OPT[@]|$(V_RPATH_OPT)|g' \ + $(srcdir)/pcap-config.in >$@.tmp mv $@.tmp $@ chmod a+x $@ @@ -408,16 +486,20 @@ pcap-config: pcap-config.in Makefile # Test programs - not built by default, and not installed. # filtertest: filtertest.c libpcap.a - $(CC) $(CFLAGS) -I. -L. -o filtertest filtertest.c libpcap.a + $(CC) $(CFLAGS) -I. -L. -o filtertest $(srcdir)/filtertest.c libpcap.a $(LIBS) findalldevstest: findalldevstest.c libpcap.a - $(CC) $(CFLAGS) -I. -L. -o findalldevstest findalldevstest.c libpcap.a + $(CC) $(CFLAGS) -I. -L. -o findalldevstest $(srcdir)/findalldevstest.c libpcap.a $(LIBS) + +selpolltest: selpolltest.c libpcap.a + $(CC) $(CFLAGS) -I. -L. -o selpolltest $(srcdir)/selpolltest.c libpcap.a $(LIBS) + +opentest: opentest.c libpcap.a + $(CC) $(CFLAGS) -I. -L. -o opentest $(srcdir)/opentest.c libpcap.a $(LIBS) -install: libpcap.a pcap-config +install: install-shared install-archive pcap-config [ -d $(DESTDIR)$(libdir) ] || \ (mkdir -p $(DESTDIR)$(libdir); chmod 755 $(DESTDIR)$(libdir)) - $(INSTALL_DATA) libpcap.a $(DESTDIR)$(libdir)/libpcap.a - $(RANLIB) $(DESTDIR)$(libdir)/libpcap.a [ -d $(DESTDIR)$(includedir) ] || \ (mkdir -p $(DESTDIR)$(includedir); chmod 755 $(DESTDIR)$(includedir)) [ -d $(DESTDIR)$(includedir)/pcap ] || \ @@ -430,91 +512,151 @@ install: libpcap.a pcap-config (mkdir -p $(DESTDIR)$(mandir)/man@MAN_FILE_FORMATS@; chmod 755 $(DESTDIR)$(mandir)/man@MAN_FILE_FORMATS@) [ -d $(DESTDIR)$(mandir)/man@MAN_MISC_INFO@ ] || \ (mkdir -p $(DESTDIR)$(mandir)/man@MAN_MISC_INFO@; chmod 755 $(DESTDIR)$(mandir)/man@MAN_MISC_INFO@) - $(INSTALL_DATA) $(srcdir)/pcap/pcap.h \ - $(DESTDIR)$(includedir)/pcap/pcap.h - $(INSTALL_DATA) $(srcdir)/pcap/bpf.h \ - $(DESTDIR)$(includedir)/pcap/bpf.h - $(INSTALL_DATA) $(srcdir)/pcap/namedb.h \ - $(DESTDIR)$(includedir)/pcap/namedb.h - $(INSTALL_DATA) $(srcdir)/pcap/sll.h \ - $(DESTDIR)$(includedir)/pcap/sll.h - $(INSTALL_DATA) $(srcdir)/pcap/usb.h \ - $(DESTDIR)$(includedir)/pcap/usb.h - $(INSTALL_DATA) $(srcdir)/pcap.h $(DESTDIR)$(includedir)/pcap.h - $(INSTALL_DATA) $(srcdir)/pcap-bpf.h \ - $(DESTDIR)$(includedir)/pcap-bpf.h - $(INSTALL_DATA) $(srcdir)/pcap-namedb.h \ - $(DESTDIR)$(includedir)/pcap-namedb.h + for i in $(PUBHDR); do \ + $(INSTALL_DATA) $(srcdir)/$$i \ + $(DESTDIR)$(includedir)/$$i; done + [ -d $(DESTDIR)$(bindir) ] || \ + (mkdir -p $(DESTDIR)$(bindir); chmod 755 $(DESTDIR)$(bindir)) $(INSTALL_PROGRAM) pcap-config $(DESTDIR)$(bindir)/pcap-config for i in $(MAN1); do \ $(INSTALL_DATA) $(srcdir)/$$i \ $(DESTDIR)$(mandir)/man1/$$i; done - for i in $(MAN3PCAP); do \ + for i in $(MAN3PCAP_NOEXPAND); do \ $(INSTALL_DATA) $(srcdir)/$$i \ $(DESTDIR)$(mandir)/man3/$$i; done + for i in $(MAN3PCAP_EXPAND:.in=); do \ + $(INSTALL_DATA) $$i \ + $(DESTDIR)$(mandir)/man3/$$i; done + rm -f $(DESTDIR)$(mandir)/man3/pcap_datalink_val_to_description.3pcap ln $(DESTDIR)$(mandir)/man3/pcap_datalink_val_to_name.3pcap \ $(DESTDIR)$(mandir)/man3/pcap_datalink_val_to_description.3pcap + rm -f $(DESTDIR)$(mandir)/man3/pcap_dump_fopen.3pcap ln $(DESTDIR)$(mandir)/man3/pcap_dump_open.3pcap \ $(DESTDIR)$(mandir)/man3/pcap_dump_fopen.3pcap + rm -f $(DESTDIR)$(mandir)/man3/pcap_perror.3pcap ln $(DESTDIR)$(mandir)/man3/pcap_geterr.3pcap \ $(DESTDIR)$(mandir)/man3/pcap_perror.3pcap + rm -f $(DESTDIR)$(mandir)/man3/pcap_sendpacket.3pcap ln $(DESTDIR)$(mandir)/man3/pcap_inject.3pcap \ $(DESTDIR)$(mandir)/man3/pcap_sendpacket.3pcap + rm -f $(DESTDIR)$(mandir)/man3/pcap_dispatch.3pcap ln $(DESTDIR)$(mandir)/man3/pcap_loop.3pcap \ $(DESTDIR)$(mandir)/man3/pcap_dispatch.3pcap + rm -f $(DESTDIR)$(mandir)/man3/pcap_minor_version.3pcap ln $(DESTDIR)$(mandir)/man3/pcap_major_version.3pcap \ $(DESTDIR)$(mandir)/man3/pcap_minor_version.3pcap + rm -f $(DESTDIR)$(mandir)/man3/pcap_next.3pcap ln $(DESTDIR)$(mandir)/man3/pcap_next_ex.3pcap \ $(DESTDIR)$(mandir)/man3/pcap_next.3pcap + rm -f $(DESTDIR)$(mandir)/man3/pcap_fopen_offline.3pcap ln $(DESTDIR)$(mandir)/man3/pcap_open_offline.3pcap \ $(DESTDIR)$(mandir)/man3/pcap_fopen_offline.3pcap + rm -f $(DESTDIR)$(mandir)/man3/pcap_getnonblock.3pcap ln $(DESTDIR)$(mandir)/man3/pcap_setnonblock.3pcap \ $(DESTDIR)$(mandir)/man3/pcap_getnonblock.3pcap for i in $(MANFILE); do \ - $(INSTALL_DATA) $(srcdir)/`echo $$i | sed 's/.manfile.in/.manfile/'` \ + $(INSTALL_DATA) `echo $$i | sed 's/.manfile.in/.manfile/'` \ $(DESTDIR)$(mandir)/man@MAN_FILE_FORMATS@/`echo $$i | sed 's/.manfile.in/.@MAN_FILE_FORMATS@/'`; done for i in $(MANMISC); do \ - $(INSTALL_DATA) $(srcdir)/`echo $$i | sed 's/.manmisc.in/.manmisc/'` \ + $(INSTALL_DATA) `echo $$i | sed 's/.manmisc.in/.manmisc/'` \ $(DESTDIR)$(mandir)/man@MAN_MISC_INFO@/`echo $$i | sed 's/.manmisc.in/.@MAN_MISC_INFO@/'`; done install-shared: install-shared-$(DYEXT) install-shared-so: libpcap.so - $(INSTALL_PROGRAM) libpcap.so.`cat VERSION` $(DESTDIR)$(libdir)/libpcap.so.`cat VERSION` + [ -d $(DESTDIR)$(libdir) ] || \ + (mkdir -p $(DESTDIR)$(libdir); chmod 755 $(DESTDIR)$(libdir)) + VER=`cat $(srcdir)/VERSION`; \ + MAJOR_VER=`sed 's/\([0-9][0-9]*\)\..*/\1/' $(srcdir)/VERSION`; \ + $(INSTALL_PROGRAM) libpcap.so.$$VER $(DESTDIR)$(libdir)/libpcap.so.$$VER; \ + ln -sf libpcap.so.$$VER $(DESTDIR)$(libdir)/libpcap.so.$$MAJOR_VER; \ + ln -sf libpcap.so.$$MAJOR_VER $(DESTDIR)$(libdir)/libpcap.so install-shared-dylib: libpcap.dylib - $(INSTALL_PROGRAM) libpcap.`cat VERSION`.dylib $(DESTDIR)$(libdir)/libpcap.`cat VERSION`.dylib - VER=`cat VERSION`; cd $(DESTDIR)$(libdir) && ln -sf libpcap.$$VER.dylib libpcap.A.dylib; ln -sf libpcap.A.dylib libpcap.dylib + [ -d $(DESTDIR)$(libdir) ] || \ + (mkdir -p $(DESTDIR)$(libdir); chmod 755 $(DESTDIR)$(libdir)) + VER=`cat $(srcdir)/VERSION`; \ + MAJOR_VER=A; \ + $(INSTALL_PROGRAM) libpcap.$$VER.dylib $(DESTDIR)$(libdir)/libpcap.$$VER.dylib; \ + ln -sf libpcap.$$VER.dylib $(DESTDIR)$(libdir)/libpcap.$$MAJOR_VER.dylib; \ + ln -sf libpcap.$$MAJOR_VER.dylib $(DESTDIR)$(libdir)/libpcap.dylib +install-shared-sl: libpcap.sl + [ -d $(DESTDIR)$(libdir) ] || \ + (mkdir -p $(DESTDIR)$(libdir); chmod 755 $(DESTDIR)$(libdir)) + MAJOR_VER=`sed 's/\([0-9][0-9]*\)\..*/\1/' $(srcdir)/VERSION`; \ + $(INSTALL_PROGRAM) libpcap.$$MAJOR_VER $(DESTDIR)$(libdir) + ln -sf libpcap.$$MAJOR_VER $(DESTDIR)$(libdir)/libpcap.sl +install-shared-shareda: libpcap.shareda + # + # AIX shared libraries are weird. They're archive libraries + # with one or more shared object components. + # + [ -d $(DESTDIR)$(libdir) ] || \ + (mkdir -p $(DESTDIR)$(libdir); chmod 755 $(DESTDIR)$(libdir)) + $(INSTALL_PROGRAM) libpcap.shareda $(DESTDIR)$(libdir)/libpcap.a +install-shared-none: -uninstall: +install-archive: install-archive-$(DYEXT) +install-archive-so install-archive-dylib install-archive-sl install-archive-none: libpcap.a + # + # Most platforms have separate suffixes for shared and + # archive libraries, so we install both. + # + [ -d $(DESTDIR)$(libdir) ] || \ + (mkdir -p $(DESTDIR)$(libdir); chmod 755 $(DESTDIR)$(libdir)) + $(INSTALL_DATA) libpcap.a $(DESTDIR)$(libdir)/libpcap.a + $(RANLIB) $(DESTDIR)$(libdir)/libpcap.a +install-archive-shareda: + # + # AIX, however, doesn't, so we don't install the archive + # library on AIX. + # + +uninstall: uninstall-shared rm -f $(DESTDIR)$(libdir)/libpcap.a - rm -f $(DESTDIR)$(includedir)/pcap/pcap.h - rm -f $(DESTDIR)$(includedir)/pcap/bpf.h - rm -f $(DESTDIR)$(includedir)/pcap/namedb.h - rm -f $(DESTDIR)$(includedir)/pcap/sll.h - rm -f $(DESTDIR)$(includedir)/pcap/usb.h + for i in $(PUBHDR); do \ + rm -f $(DESTDIR)$(includedir)/$$i; done -rmdir $(DESTDIR)$(includedir)/pcap - rm -f $(DESTDIR)$(includedir)/pcap.h - rm -f $(DESTDIR)$(includedir)/pcap-bpf.h - rm -f $(DESTDIR)$(includedir)/pcap-namedb.h + rm -f $(DESTDIR)/$(bindir)/pcap-config for i in $(MAN1); do \ rm -f $(DESTDIR)$(mandir)/man1/$$i; done for i in $(MAN3PCAP); do \ rm -f $(DESTDIR)$(mandir)/man3/$$i; done - rm -f $(DESTDIR)$(mandir)/man3/pcap_datalink_val_to_description.3pcap - rm -f $(DESTDIR)$(mandir)/man3/pcap_dump_fopen.3pcap - rm -f $(DESTDIR)$(mandir)/man3/pcap_perror.3pcap - rm -f $(DESTDIR)$(mandir)/man3/pcap_sendpacket.3pcap - rm -f $(DESTDIR)$(mandir)/man3/pcap_dispatch.3pcap - rm -f $(DESTDIR)$(mandir)/man3/pcap_minor_version.3pcap - rm -f $(DESTDIR)$(mandir)/man3/pcap_next.3pcap - rm -f $(DESTDIR)$(mandir)/man3/pcap_fopen_offline.3pcap - rm -f $(DESTDIR)$(mandir)/man3/pcap_getnonblock.3pcap + rm -f $(DESTDIR)$(mandir)/man3/pcap_datalink_val_to_description.3pcap + rm -f $(DESTDIR)$(mandir)/man3/pcap_dump_fopen.3pcap + rm -f $(DESTDIR)$(mandir)/man3/pcap_perror.3pcap + rm -f $(DESTDIR)$(mandir)/man3/pcap_sendpacket.3pcap + rm -f $(DESTDIR)$(mandir)/man3/pcap_dispatch.3pcap + rm -f $(DESTDIR)$(mandir)/man3/pcap_minor_version.3pcap + rm -f $(DESTDIR)$(mandir)/man3/pcap_next.3pcap + rm -f $(DESTDIR)$(mandir)/man3/pcap_fopen_offline.3pcap + rm -f $(DESTDIR)$(mandir)/man3/pcap_getnonblock.3pcap for i in $(MANFILE); do \ rm -f $(DESTDIR)$(mandir)/man@MAN_FILE_FORMATS@/`echo $$i | sed 's/.manfile.in/.@MAN_FILE_FORMATS@/'`; done for i in $(MANMISC); do \ rm -f $(DESTDIR)$(mandir)/man@MAN_MISC_INFO@/`echo $$i | sed 's/.manmisc.in/.@MAN_MISC_INFO@/'`; done +uninstall-shared: uninstall-shared-$(DYEXT) +uninstall-shared-so: + VER=`cat $(srcdir)/VERSION`; \ + MAJOR_VER=`sed 's/\([0-9][0-9]*\)\..*/\1/' $(srcdir)/VERSION`; \ + rm -f $(DESTDIR)$(libdir)/libpcap.so.$$VER; \ + rm -f $(DESTDIR)$(libdir)/libpcap.so.$$MAJOR_VER; \ + rm -f $(DESTDIR)$(libdir)/libpcap.so +uninstall-shared-dylib: + VER=`cat $(srcdir)/VERSION`; \ + MAJOR_VER=A; \ + rm -f $(DESTDIR)$(libdir)/libpcap.$$VER.dylib; \ + rm -f $(DESTDIR)$(libdir)/libpcap.$$MAJOR_VER.dylib; \ + rm -f $(DESTDIR)$(libdir)/libpcap.dylib +uninstall-shared-sl: + MAJOR_VER=`sed 's/\([0-9][0-9]*\)\..*/\1/' $(srcdir)/VERSION`; \ + rm -f $(DESTDIR)$(libdir)/libpcap.$$MAJOR_VER; \ + rm -f $(DESTDIR)$(libdir)/libpcap.sl +uninstall-shared-shareda: + rm -f $(DESTDIR)$(libdir)/libpcap.a +uninstall-shared-none: + clean: - rm -f $(CLEANFILES) libpcap*.dylib libpcap.so* + rm -f $(CLEANFILES) distclean: clean rm -f Makefile config.cache config.log config.status \ @@ -530,7 +672,7 @@ packaging/pcap.spec: packaging/pcap.spec RPMVERSION=`cat VERSION | sed s/-.*//g`; \ sed -e s/@VERSION@/$$RPMVERSION/ -e s/@NAME@/libpcap-`cat VERSION`/ $< > $@ -releasetar: +releasetar: @cwd=`pwd` ; dir=`basename $$cwd` ; name=$(PROG)-`cat VERSION` ; \ mkdir $$name; \ tar cf - $(CSRC) $(HDR) $(MAN1) $(MAN3PCAP_EXPAND) \ Modified: vendor/libpcap/dist/README ============================================================================== --- vendor/libpcap/dist/README Thu Oct 28 15:43:14 2010 (r214454) +++ vendor/libpcap/dist/README Thu Oct 28 16:22:13 2010 (r214455) @@ -1,19 +1,17 @@ -@(#) $Header: /tcpdump/master/libpcap/README,v 1.30.4.3 2008-10-17 10:39:20 ken Exp $ (LBL) +@(#) $Header: /tcpdump/master/libpcap/README,v 1.34 2008-12-14 19:44:14 guy Exp $ (LBL) -LIBPCAP 1.0.0 +LIBPCAP 1.x.y www.tcpdump.org Please send inquiries/comments/reports to: tcpdump-workers@lists.tcpdump.org -Anonymous CVS is available via: - cvs -d :pserver:tcpdump@cvs.tcpdump.org:/tcpdump/master login - (password "anoncvs") - cvs -d :pserver:tcpdump@cvs.tcpdump.org:/tcpdump/master checkout libpcap +Anonymous Git is available via: + git clone git://bpf.tcpdump.org/libpcap -Version 1.0.0 of LIBPCAP can be retrieved with the CVS tag "libpcap_1_0": - cvs -d :pserver:tcpdump@cvs.tcpdump.org:/tcpdump/master checkout -r libpcap_1_0 libpcap +Version 1.x.y of LIBPCAP can be retrieved with the CVS tag "libpcap_1_{x}rel{y}": + cvs -d :pserver:tcpdump@cvs.tcpdump.org:/tcpdump/master checkout -r libpcap_1_{x}rel{y} libpcap Please submit patches against the master copy to the libpcap project on sourceforge.net. @@ -80,10 +78,10 @@ information on configuring that option. Note to Linux distributions and *BSD systems that include libpcap: There's now a rule to make a shared library, which should work on Linux -and *BSD (and OS X). +and *BSD, among other platforms. It sets the soname of the library to "libpcap.so.1"; this is what it -should be, *NOT* libpcap.so.1.0 or libpcap.so.1.0.0 or something such as +should be, *NOT* libpcap.so.1.x or libpcap.so.1.x.y or something such as that. We've been maintaining binary compatibility between libpcap releases for Added: vendor/libpcap/dist/README.Win32 ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ vendor/libpcap/dist/README.Win32 Thu Oct 28 16:22:13 2010 (r214455) @@ -0,0 +1,46 @@ +Under Win32, libpcap is integrated in the WinPcap packet capture system. +WinPcap provides a framework that allows libpcap to capture the packets +under Windows 95, Windows 98, Windows ME, Windows NT 4, Windows 2000 +and Windows XP. +WinPcap binaries and source code can be found at http://winpcap.polito.it: +they include also a developer's pack with all the necessary to compile +libpcap-based applications under Windows. + +How to compile libpcap with Visual Studio +----------------------------------------- + +In order to compile libpcap you will need: + +- version 6 (or higher) of Microsoft Visual Studio +- The November 2001 (or later) edition of Microsoft Platform +Software Development Kit (SDK), that contains some necessary includes +for IPv6 support. You can download it from http://www.microsoft.com/sdk +- the latest WinPcap sources from http://winpcap.polito.it/install + +The WinPcap source code already contains a recent (usually the latest +stable) version of libpcap. If you need to compile a different one, +simply download it from www.tcpdump.org and copy the sources in the +winpcap\wpcap\libpcap folder of the WinPcap distribution. If you want to +compile a libpcap source retrieved from the tcpdump.org Git, you will +have to create the scanner and the grammar by hand (with lex and yacc) +or with the cygnus makefile, since The Visual Studio project is not able +to build them. + +Open the project file winpcap\wpcap\prj\wpcap.dsw with Visual Studio and +build wpcap.dll. wpcap.lib, the library file to link with the applications, +will be generated in winpcap\wpcap\lib\. wpcap.dll will be generated in +winpcap\wpcap\prj\release or winpcap\wpcap\prj\debug depending on the type +of binary that is being created. + +How to compile libpcap with Cygnus +---------------------------------- + +To build wpcap.dll, cd to the directory WPCAP/PRJ of the WinPcap source code +distribution and type "make". libwpcap.a, the library file to link with the +applications, will be generated in winpcap\wpcap\lib\. wpcap.dll will be +generated in winpcap\wpcap\prj. + +Remember, you CANNOT use the MSVC-generated .lib files with gcc, use +libwpcap.a instead. + +"make install" installs wpcap.dll in the Windows system folder. Added: vendor/libpcap/dist/README.aix ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ vendor/libpcap/dist/README.aix Thu Oct 28 16:22:13 2010 (r214455) @@ -0,0 +1,81 @@ +Using BPF: + +(1) AIX 4.x's version of BPF is undocumented and somewhat unstandard; the + current BPF support code includes changes that should work around + that; it appears to compile and work on at least one AIX 4.3.3 + machine. + + Note that the BPF driver and the "/dev/bpf" devices might not exist + on your machine; AIX's tcpdump loads the driver and creates the + devices if they don't already exist. Our libpcap should do the + same, and the configure script should detect that it's on an AIX + system and choose BPF even if the devices aren't there. + +(2) If libpcap doesn't compile on your machine when configured to use + BPF, or if the workarounds fail to make it work correctly, you + should send to tcpdump-workers@lists.tcpdump.org a detailed bug + report (if the compile fails, send us the compile error messages; + if it compiles but fails to work correctly, send us as detailed as + possible a description of the symptoms, including indications of the + network link-layer type being wrong or time stamps being wrong). + + If you fix the problems yourself, please submit a patch to + + http://sourceforge.net/projects/libpcap/ + + so we can incorporate them into the next release. + + If you don't fix the problems yourself, you can, as a workaround, + make libpcap use DLPI instead of BPF. + + This can be done by specifying the flag: + + --with-pcap=dlpi + + to the "configure" script for libpcap. + +If you use DLPI: + +(1) It is a good idea to have the latest version of the DLPI driver on + your system, since certain versions may be buggy and cause your AIX + system to crash. DLPI is included in the fileset bos.rte.tty. I + found that the DLPI driver that came with AIX 4.3.2 was buggy, and + had to upgrade to bos.rte.tty 4.3.2.4: + + lslpp -l bos.rte.tty + + bos.rte.tty 4.3.2.4 COMMITTED Base TTY Support and Commands + + Updates for AIX filesets can be obtained from: + ftp://service.software.ibm.com/aix/fixes/ + + These updates can be installed with the smit program. + +(2) After compiling libpcap, you need to make sure that the DLPI driver + is loaded. Type: + + strload -q -d dlpi + + If the result is: + + dlpi: yes + + then the DLPI driver is loaded correctly. + + If it is: + + dlpi: no + + Then you need to type: + + strload -f /etc/dlpi.conf + + Check again with strload -q -d dlpi that the dlpi driver is loaded. + + Alternatively, you can uncomment the lines for DLPI in + /etc/pse.conf and reboot the machine; this way DLPI will always + be loaded when you boot your system. + +(3) There appears to be a problem in the DLPI code in some versions of + AIX, causing a warning about DL_PROMISC_MULTI failing; this might + be responsible for DLPI not being able to capture outgoing packets. Added: vendor/libpcap/dist/README.dag ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ vendor/libpcap/dist/README.dag Thu Oct 28 16:22:13 2010 (r214455) @@ -0,0 +1,114 @@ + +The following instructions apply if you have a Linux or FreeBSD platform and +want libpcap to support the DAG range of passive network monitoring cards from +Endace (http://www.endace.com, see below for further contact details). + +1) Install and build the DAG software distribution by following the +instructions supplied with that package. Current Endace customers can download +the DAG software distibution from https://www.endace.com + +2) Configure libcap. To allow the 'configure' script to locate the DAG +software distribution use the '--with-dag' option: + + ./configure --with-dag=DIR + +Where DIR is the root of the DAG software distribution, for example +/var/src/dag. If the DAG software is correctly detected 'configure' will +report: + + checking whether we have DAG API... yes *** DIFF OUTPUT TRUNCATED AT 1000 LINES ***