Merge "Snap for 11541002 from c925e13a31ff7fd475ab74cbf38bc6dafb26a5f9 to sdk-release" into sdk-release
tree: c637b1d320d9e3ae9eaf3f514a6957ee8bf0337b
  1. .github/
  2. ChmodBPF/
  3. cmake/
  4. doc/
  5. lbl/
  6. missing/
  7. msdos/
  8. pcap/
  9. rpcapd/
  10. testprogs/
  11. tests/
  12. .appveyor.yml
  13. .ci-coverity-scan-build.sh
  14. .cirrus.yml
  15. .gitattributes
  16. .gitignore
  17. .mailmap
  18. aclocal.m4
  19. Android.bp
  20. arcnet.h
  21. atmuni31.h
  22. bpf_dump.c
  23. bpf_filter.c
  24. bpf_image.c
  25. build.sh
  26. build_common.sh
  27. build_matrix.sh
  28. CHANGES
  29. charconv.c
  30. charconv.h
  31. chmod_bpf
  32. CleanSpec.mk
  33. cmake_uninstall.cmake.in
  34. cmakeconfig.h.in
  35. CMakeLists.txt
  36. config.guess
  37. config.h
  38. config.h.in
  39. config.sub
  40. configure
  41. configure.ac
  42. CONTRIBUTING.md
  43. CREDITS
  44. diag-control.h
  45. dlpisubs.c
  46. dlpisubs.h
  47. etherent.c
  48. ethertype.h
  49. extract.h
  50. fad-getad.c
  51. fad-gifc.c
  52. fad-glifc.c
  53. fmtutils.c
  54. fmtutils.h
  55. ftmacros.h
  56. gencode.c
  57. gencode.h
  58. grammar.c
  59. grammar.h
  60. grammar.y.in
  61. ieee80211.h
  62. install-sh
  63. INSTALL.md
  64. libpcap.pc.in
  65. LICENSE
  66. llc.h
  67. Makefile-devel-adds
  68. Makefile.in
  69. METADATA
  70. mkdep
  71. MODULE_LICENSE_BSD
  72. nametoaddr.c
  73. nametoaddr.h
  74. nlpid.h
  75. nomkdep
  76. NOTICE
  77. optimize.c
  78. optimize.h
  79. org.tcpdump.chmod_bpf.plist
  80. OWNERS
  81. pcap-airpcap.c
  82. pcap-airpcap.h
  83. pcap-bpf.c
  84. pcap-bpf.h
  85. pcap-bt-linux.c
  86. pcap-bt-linux.h
  87. pcap-bt-monitor-linux.c
  88. pcap-bt-monitor-linux.h
  89. pcap-common.c
  90. pcap-common.h
  91. pcap-config.1
  92. pcap-config.in
  93. pcap-dag.c
  94. pcap-dag.h
  95. pcap-dbus.c
  96. pcap-dbus.h
  97. pcap-dll.rc
  98. pcap-dlpi.c
  99. pcap-dos.c
  100. pcap-dos.h
  101. pcap-dpdk.c
  102. pcap-dpdk.h
  103. pcap-enet.c
  104. pcap-filter.manmisc.in
  105. pcap-haiku.cpp
  106. pcap-int.h
  107. pcap-libdlpi.c
  108. pcap-linktype.manmisc.in
  109. pcap-linux.c
  110. pcap-namedb.h
  111. pcap-netfilter-linux-android.c
  112. pcap-netfilter-linux-android.h
  113. pcap-netfilter-linux.c
  114. pcap-netfilter-linux.h
  115. pcap-netmap.c
  116. pcap-netmap.h
  117. pcap-new.c
  118. pcap-nit.c
  119. pcap-npf.c
  120. pcap-null.c
  121. pcap-pf.c
  122. pcap-rdmasniff.c
  123. pcap-rdmasniff.h
  124. pcap-rpcap-int.h
  125. pcap-rpcap.c
  126. pcap-rpcap.h
  127. pcap-savefile.manfile.in
  128. pcap-septel.c
  129. pcap-septel.h
  130. pcap-sita.c
  131. pcap-sita.h
  132. pcap-sita.html
  133. pcap-snf.c
  134. pcap-snf.h
  135. pcap-snit.c
  136. pcap-snoop.c
  137. pcap-tc.c
  138. pcap-tc.h
  139. pcap-tstamp.manmisc.in
  140. pcap-types.h
  141. pcap-usb-linux-common.c
  142. pcap-usb-linux-common.h
  143. pcap-usb-linux.c
  144. pcap-usb-linux.h
  145. pcap-util.c
  146. pcap-util.h
  147. pcap.3pcap.in
  148. pcap.c
  149. pcap.h
  150. pcap_activate.3pcap
  151. pcap_breakloop.3pcap
  152. pcap_can_set_rfmon.3pcap
  153. pcap_close.3pcap
  154. pcap_compile.3pcap.in
  155. pcap_create.3pcap
  156. pcap_datalink.3pcap.in
  157. pcap_datalink_name_to_val.3pcap
  158. pcap_datalink_val_to_name.3pcap
  159. pcap_dump.3pcap
  160. pcap_dump_close.3pcap
  161. pcap_dump_file.3pcap
  162. pcap_dump_flush.3pcap
  163. pcap_dump_ftell.3pcap
  164. pcap_dump_open.3pcap.in
  165. pcap_file.3pcap
  166. pcap_fileno.3pcap
  167. pcap_findalldevs.3pcap
  168. pcap_freecode.3pcap
  169. pcap_get_required_select_timeout.3pcap
  170. pcap_get_selectable_fd.3pcap
  171. pcap_get_tstamp_precision.3pcap.in
  172. pcap_geterr.3pcap
  173. pcap_init.3pcap
  174. pcap_inject.3pcap
  175. pcap_is_swapped.3pcap
  176. pcap_lib_version.3pcap
  177. pcap_list_datalinks.3pcap.in
  178. pcap_list_tstamp_types.3pcap.in
  179. pcap_lookupdev.3pcap
  180. pcap_lookupnet.3pcap
  181. pcap_loop.3pcap
  182. pcap_major_version.3pcap
  183. pcap_next_ex.3pcap
  184. pcap_offline_filter.3pcap
  185. pcap_open_dead.3pcap.in
  186. pcap_open_live.3pcap
  187. pcap_open_offline.3pcap.in
  188. pcap_set_buffer_size.3pcap
  189. pcap_set_datalink.3pcap
  190. pcap_set_immediate_mode.3pcap.in
  191. pcap_set_promisc.3pcap
  192. pcap_set_protocol_linux.3pcap
  193. pcap_set_rfmon.3pcap
  194. pcap_set_snaplen.3pcap
  195. pcap_set_timeout.3pcap
  196. pcap_set_tstamp_precision.3pcap.in
  197. pcap_set_tstamp_type.3pcap.in
  198. pcap_setdirection.3pcap
  199. pcap_setfilter.3pcap
  200. pcap_setnonblock.3pcap
  201. pcap_snapshot.3pcap
  202. pcap_stats.3pcap
  203. pcap_statustostr.3pcap
  204. pcap_strerror.3pcap
  205. pcap_tstamp_type_name_to_val.3pcap
  206. pcap_tstamp_type_val_to_name.3pcap
  207. pflog.h
  208. portability.h
  209. post_update.sh
  210. ppp.h
  211. README.md
  212. rpcap-protocol.c
  213. rpcap-protocol.h
  214. savefile.c
  215. scanner.c
  216. scanner.h
  217. scanner.l
  218. sf-pcap.c
  219. sf-pcap.h
  220. sf-pcapng.c
  221. sf-pcapng.h
  222. sockutils.c
  223. sockutils.h
  224. sslutils.c
  225. sslutils.h
  226. sunatmpos.h
  227. TODO
  228. varattrs.h
  229. VERSION
README.md

LIBPCAP 1.x.y by The Tcpdump Group

To report a security issue please send an e-mail to security@tcpdump.org.

To report bugs and other problems, contribute patches, request a feature, provide generic feedback etc please see the guidelines for contributing.

The documentation directory has README files about specific operating systems and options.

Anonymous Git is available via:

https://github.com/the-tcpdump-group/libpcap.git

This directory contains source code for libpcap, a system-independent interface for user-level packet capture. libpcap provides a portable framework for low-level network monitoring. Applications include network statistics collection, security monitoring, network debugging, etc. Since almost every system vendor provides a different interface for packet capture, and since we‘ve developed several tools that require this functionality, we’ve created this system-independent API to ease in porting and to alleviate the need for several system-dependent packet capture modules in each application.

formerly from	Lawrence Berkeley National Laboratory
		Network Research Group <libpcap@ee.lbl.gov>
		ftp://ftp.ee.lbl.gov/old/libpcap-0.4a7.tar.Z

Support for particular platforms and BPF

For some platforms there are README.{system} files that discuss issues with the OS‘s interface for packet capture on those platforms, such as how to enable support for that interface in the OS, if it’s not built in by default.

The libpcap interface supports a filtering mechanism based on the architecture in the BSD packet filter. BPF is described in the 1993 Winter Usenix paper ``The BSD Packet Filter: A New Architecture for User-level Packet Capture'' (compressed PostScript, gzipped PostScript, PDF).

Although most packet capture interfaces support in-kernel filtering, libpcap utilizes in-kernel filtering only for the BPF interface. On systems that don't have BPF, all packets are read into user-space and the BPF filters are evaluated in the libpcap library, incurring added overhead (especially, for selective filters). Ideally, libpcap would translate BPF filters into a filter program that is compatible with the underlying kernel subsystem, but this is not yet implemented.

BPF is standard in 4.4BSD, BSD/OS, NetBSD, FreeBSD, OpenBSD, DragonFly BSD, macOS, and Solaris 11; an older, modified and undocumented version is standard in AIX. {DEC OSF/1, Digital UNIX, Tru64 UNIX} uses the packetfilter interface but has been extended to accept BPF filters (which libpcap utilizes).

Linux has a number of BPF based systems, and libpcap does not support any of the eBPF mechanisms as yet, although it supports many of the memory mapped receive mechanisms. See the Linux-specific README for more information.

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, among other platforms.

It sets the soname of the library to libpcap.so.1; this is what it 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 quite a while; there’s no reason to tie a binary linked with libpcap to a particular release of libpcap.