mirror of
https://github.com/holub/mame
synced 2025-04-28 19:14:55 +03:00
207 lines
35 KiB
HTML
207 lines
35 KiB
HTML
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
<html xmlns="http://www.w3.org/1999/xhtml">
|
|
<head>
|
|
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
|
|
<title>WinPcap: pcap.h Source File</title>
|
|
<link href="tabs.css" rel="stylesheet" type="text/css"/>
|
|
<link href="style.css" rel="stylesheet" type="text/css"/>
|
|
</head>
|
|
<body>
|
|
<!-- Generated by Doxygen 1.6.1 -->
|
|
<div class="navigation" id="top">
|
|
<div class="tabs">
|
|
<ul>
|
|
<li><a href="main.html"><span>Main Page</span></a></li>
|
|
<li><a href="pages.html"><span>Related Pages</span></a></li>
|
|
<li><a href="modules.html"><span>Modules</span></a></li>
|
|
<li><a href="annotated.html"><span>Data Structures</span></a></li>
|
|
<li class="current"><a href="files.html"><span>Files</span></a></li>
|
|
</ul>
|
|
</div>
|
|
<div class="tabs">
|
|
<ul>
|
|
<li><a href="files.html"><span>File List</span></a></li>
|
|
<li><a href="globals.html"><span>Globals</span></a></li>
|
|
</ul>
|
|
</div>
|
|
<h1>pcap.h</h1><a href="funcs_2pcap_8h.html">Go to the documentation of this file.</a><div class="fragment"><pre class="fragment"><a name="l00001"></a>00001
|
|
<a name="l00017"></a>00017 <span class="comment">//\{ </span>
|
|
<a name="l00018"></a>00018
|
|
<a name="l00027"></a><a class="code" href="group__wpcapfunc.html#gabcba231c099919ecd9300d7160b19878">00027</a> <span class="keyword">typedef</span> void (*<a class="code" href="group__wpcapfunc.html#gabcba231c099919ecd9300d7160b19878" title="Prototype of the callback function that receives the packets.">pcap_handler</a>)(u_char *user, <span class="keyword">const</span> <span class="keyword">struct </span><a class="code" href="structpcap__pkthdr.html" title="Header of a packet in the dump file.">pcap_pkthdr</a> *pkt_header,
|
|
<a name="l00028"></a>00028 <span class="keyword">const</span> u_char *pkt_data);
|
|
<a name="l00029"></a>00029
|
|
<a name="l00063"></a>00063 <a class="code" href="group__wpcap__def.html#ga4711d025f83503ce692efa5e45ec60a7" title="Descriptor of an open capture instance. This structure is opaque to the user, that...">pcap_t</a> *<a class="code" href="group__wpcapfunc.html#gaae6abe06e15c87b803f69773822beca8" title="Open a live capture from the network.">pcap_open_live</a>(<span class="keyword">const</span> <span class="keywordtype">char</span> *device, <span class="keywordtype">int</span> snaplen, <span class="keywordtype">int</span> promisc, <span class="keywordtype">int</span> to_ms, <span class="keywordtype">char</span> *ebuf);
|
|
<a name="l00064"></a>00064
|
|
<a name="l00065"></a>00065
|
|
<a name="l00075"></a>00075 <a class="code" href="group__wpcap__def.html#ga4711d025f83503ce692efa5e45ec60a7" title="Descriptor of an open capture instance. This structure is opaque to the user, that...">pcap_t</a> *<a class="code" href="group__wpcapfunc.html#ga6445eeb76f2757b9fa088b276eea2845" title="Create a pcap_t structure without starting a capture.">pcap_open_dead</a>(<span class="keywordtype">int</span> linktype, <span class="keywordtype">int</span> snaplen);
|
|
<a name="l00076"></a>00076
|
|
<a name="l00077"></a>00077
|
|
<a name="l00091"></a>00091 <a class="code" href="group__wpcap__def.html#ga4711d025f83503ce692efa5e45ec60a7" title="Descriptor of an open capture instance. This structure is opaque to the user, that...">pcap_t</a> *<a class="code" href="group__wpcapfunc.html#ga91078168a13de8848df2b7b83d1f5b69" title="Open a savefile in the tcpdump/libpcap format to read packets.">pcap_open_offline</a>(<span class="keyword">const</span> <span class="keywordtype">char</span> *fname, <span class="keywordtype">char</span> *errbuf);
|
|
<a name="l00092"></a>00092
|
|
<a name="l00105"></a>00105 <a class="code" href="group__wpcap__def.html#gab8c7858aa3a7e3158d9d58cb113a2ae8" title="libpcap savefile descriptor.">pcap_dumper_t</a> *<a class="code" href="group__wpcapfunc.html#ga9506c33d580fdb5e5c288dba0f8a085c" title="Open a file to write packets.">pcap_dump_open</a>(<a class="code" href="group__wpcap__def.html#ga4711d025f83503ce692efa5e45ec60a7" title="Descriptor of an open capture instance. This structure is opaque to the user, that...">pcap_t</a> *p, <span class="keyword">const</span> <span class="keywordtype">char</span> *fname);
|
|
<a name="l00106"></a>00106
|
|
<a name="l00124"></a>00124 <span class="keywordtype">int</span> <a class="code" href="group__wpcapfunc.html#ga3f212141c80b59aad8ac535bb0178275" title="Switch between blocking and nonblocking mode.">pcap_setnonblock</a>(<a class="code" href="group__wpcap__def.html#ga4711d025f83503ce692efa5e45ec60a7" title="Descriptor of an open capture instance. This structure is opaque to the user, that...">pcap_t</a> *p, <span class="keywordtype">int</span> nonblock, <span class="keywordtype">char</span> *errbuf);
|
|
<a name="l00125"></a>00125
|
|
<a name="l00126"></a>00126
|
|
<a name="l00136"></a>00136 <span class="keywordtype">int</span> <a class="code" href="group__wpcapfunc.html#gab25dc0bfe06545b86be4103bf010708e" title="Get the &quot;non-blocking&quot; state of an interface.">pcap_getnonblock</a>(<a class="code" href="group__wpcap__def.html#ga4711d025f83503ce692efa5e45ec60a7" title="Descriptor of an open capture instance. This structure is opaque to the user, that...">pcap_t</a> *p, <span class="keywordtype">char</span> *errbuf);
|
|
<a name="l00137"></a>00137
|
|
<a name="l00153"></a>00153 <span class="keywordtype">int</span> <a class="code" href="group__wpcapfunc.html#ga7b128eaeef627b408f6a6e2a2f5eb45d" title="Construct a list of network devices that can be opened with pcap_open_live().">pcap_findalldevs</a>(<a class="code" href="structpcap__if.html" title="Item in a list of interfaces, used by pcap_findalldevs().">pcap_if_t</a> **alldevsp, <span class="keywordtype">char</span> *errbuf);
|
|
<a name="l00154"></a>00154
|
|
<a name="l00161"></a>00161 <span class="keywordtype">void</span> <a class="code" href="group__wpcapfunc.html#ga346b4b0b7fd1cda4abb9a39f767dbeb1" title="Free an interface list returned by pcap_findalldevs().">pcap_freealldevs</a>(<a class="code" href="structpcap__if.html" title="Item in a list of interfaces, used by pcap_findalldevs().">pcap_if_t</a> *alldevsp);
|
|
<a name="l00162"></a>00162
|
|
<a name="l00173"></a>00173 <span class="keywordtype">char</span> *<a class="code" href="group__wpcapfunc.html#gaed295fc9fd86434372e8a8316f1270b1" title="Return the first valid device in the system.">pcap_lookupdev</a>(<span class="keywordtype">char</span> *errbuf);
|
|
<a name="l00174"></a>00174
|
|
<a name="l00175"></a>00175
|
|
<a name="l00187"></a>00187 <span class="keywordtype">int</span> <a class="code" href="group__wpcapfunc.html#gaa35276d0fa530c51a455f298fa1ec453" title="Return the subnet and netmask of an interface.">pcap_lookupnet</a>(<span class="keyword">const</span> <span class="keywordtype">char</span> *device, <a class="code" href="group__wpcap__def.html#ga37fdbc8313e90fb2041203a2e40cd482" title="32-bit unsigned integer">bpf_u_int32</a> *netp, <a class="code" href="group__wpcap__def.html#ga37fdbc8313e90fb2041203a2e40cd482" title="32-bit unsigned integer">bpf_u_int32</a> *maskp, <span class="keywordtype">char</span> *errbuf);
|
|
<a name="l00188"></a>00188
|
|
<a name="l00227"></a>00227 <span class="keywordtype">int</span> <a class="code" href="group__wpcapfunc.html#ga60ce104cdf28420d3361cd36d15be44c" title="Collect a group of packets.">pcap_dispatch</a>(<a class="code" href="group__wpcap__def.html#ga4711d025f83503ce692efa5e45ec60a7" title="Descriptor of an open capture instance. This structure is opaque to the user, that...">pcap_t</a> *p, <span class="keywordtype">int</span> cnt, <a class="code" href="group__wpcapfunc.html#gabcba231c099919ecd9300d7160b19878" title="Prototype of the callback function that receives the packets.">pcap_handler</a> callback, u_char *user);
|
|
<a name="l00228"></a>00228
|
|
<a name="l00229"></a>00229
|
|
<a name="l00244"></a>00244 <span class="keywordtype">int</span> <a class="code" href="group__wpcapfunc.html#ga6bcb7c5c59d76ec16b8a699da136b5de" title="Collect a group of packets.">pcap_loop</a>(<a class="code" href="group__wpcap__def.html#ga4711d025f83503ce692efa5e45ec60a7" title="Descriptor of an open capture instance. This structure is opaque to the user, that...">pcap_t</a> *p, <span class="keywordtype">int</span> cnt, <a class="code" href="group__wpcapfunc.html#gabcba231c099919ecd9300d7160b19878" title="Prototype of the callback function that receives the packets.">pcap_handler</a> callback, u_char *user);
|
|
<a name="l00245"></a>00245
|
|
<a name="l00246"></a>00246
|
|
<a name="l00261"></a>00261 u_char *<a class="code" href="group__wpcapfunc.html#gadf60257f650aaf869671e0a163611fc3" title="Return the next available packet.">pcap_next</a>(<a class="code" href="group__wpcap__def.html#ga4711d025f83503ce692efa5e45ec60a7" title="Descriptor of an open capture instance. This structure is opaque to the user, that...">pcap_t</a> *p, <span class="keyword">struct</span> <a class="code" href="structpcap__pkthdr.html" title="Header of a packet in the dump file.">pcap_pkthdr</a> *h);
|
|
<a name="l00262"></a>00262
|
|
<a name="l00279"></a>00279 <span class="keywordtype">int</span> <a class="code" href="group__wpcapfunc.html#ga439439c2eae61161dc1efb1e03a81133" title="Read a packet from an interface or from an offline capture.">pcap_next_ex</a>(<a class="code" href="group__wpcap__def.html#ga4711d025f83503ce692efa5e45ec60a7" title="Descriptor of an open capture instance. This structure is opaque to the user, that...">pcap_t</a> *p, <span class="keyword">struct</span> <a class="code" href="structpcap__pkthdr.html" title="Header of a packet in the dump file.">pcap_pkthdr</a> **pkt_header, <span class="keyword">const</span> u_char **pkt_data);
|
|
<a name="l00280"></a>00280
|
|
<a name="l00302"></a>00302 <span class="keywordtype">void</span> <a class="code" href="group__wpcapfunc.html#gae0dc50910fabbd375fab8a1352a6cf33" title="set a flag that will force pcap_dispatch() or pcap_loop() to return rather than looping...">pcap_breakloop</a>(<a class="code" href="group__wpcap__def.html#ga4711d025f83503ce692efa5e45ec60a7" title="Descriptor of an open capture instance. This structure is opaque to the user, that...">pcap_t</a> *);
|
|
<a name="l00303"></a>00303
|
|
<a name="l00315"></a>00315 <span class="keywordtype">int</span> <a class="code" href="group__wpcapfunc.html#ga51dbda0f1ab9da2cfe49d657486d50b2" title="Send a raw packet.">pcap_sendpacket</a>(<a class="code" href="group__wpcap__def.html#ga4711d025f83503ce692efa5e45ec60a7" title="Descriptor of an open capture instance. This structure is opaque to the user, that...">pcap_t</a> *p, u_char *buf, <span class="keywordtype">int</span> size);
|
|
<a name="l00316"></a>00316
|
|
<a name="l00327"></a>00327 <span class="keywordtype">void</span> <a class="code" href="group__wpcapfunc.html#ga659439bf5aa3988b5a92d31990fbf437" title="Save a packet to disk.">pcap_dump</a>(u_char *user, <span class="keyword">const</span> <span class="keyword">struct</span> <a class="code" href="structpcap__pkthdr.html" title="Header of a packet in the dump file.">pcap_pkthdr</a> *h, <span class="keyword">const</span> u_char *sp);
|
|
<a name="l00328"></a>00328
|
|
<a name="l00337"></a>00337 <span class="keywordtype">long</span> <a class="code" href="group__wpcapfunc.html#ga50de34b8b3298f76c66c82b7ca3f84de" title="Return the file position for a &quot;savefile&quot;.">pcap_dump_ftell</a>(<a class="code" href="group__wpcap__def.html#gab8c7858aa3a7e3158d9d58cb113a2ae8" title="libpcap savefile descriptor.">pcap_dumper_t</a> *);
|
|
<a name="l00338"></a>00338
|
|
<a name="l00357"></a>00357 <span class="keywordtype">int</span> <a class="code" href="group__wpcapfunc.html#ga363bdc6f6b39b4979ddcf15ecb830c5c" title="Compile a packet filter, converting an high level filtering expression (see Filtering...">pcap_compile</a>(<a class="code" href="group__wpcap__def.html#ga4711d025f83503ce692efa5e45ec60a7" title="Descriptor of an open capture instance. This structure is opaque to the user, that...">pcap_t</a> *p, <span class="keyword">struct</span> bpf_program *fp, <span class="keywordtype">char</span> *str, <span class="keywordtype">int</span> optimize, <a class="code" href="group__wpcap__def.html#ga37fdbc8313e90fb2041203a2e40cd482" title="32-bit unsigned integer">bpf_u_int32</a> netmask);
|
|
<a name="l00358"></a>00358
|
|
<a name="l00378"></a>00378 <span class="keywordtype">int</span> <a class="code" href="group__wpcapfunc.html#ga8325b202dad14a00609db8372722ae4e" title="Compile a packet filter without the need of opening an adapter. This function converts...">pcap_compile_nopcap</a>(<span class="keywordtype">int</span> snaplen_arg, <span class="keywordtype">int</span> linktype_arg, <span class="keyword">struct</span> bpf_program *program, <span class="keywordtype">char</span> *buf, <span class="keywordtype">int</span> optimize, <a class="code" href="group__wpcap__def.html#ga37fdbc8313e90fb2041203a2e40cd482" title="32-bit unsigned integer">bpf_u_int32</a> mask);
|
|
<a name="l00379"></a>00379
|
|
<a name="l00380"></a>00380
|
|
<a name="l00391"></a>00391 <span class="keywordtype">int</span> <a class="code" href="group__wpcapfunc.html#gaf5f9cfe85dad0967ff607e5159b1ba61" title="Associate a filter to a capture.">pcap_setfilter</a>(<a class="code" href="group__wpcap__def.html#ga4711d025f83503ce692efa5e45ec60a7" title="Descriptor of an open capture instance. This structure is opaque to the user, that...">pcap_t</a> *p, <span class="keyword">struct</span> bpf_program *fp);
|
|
<a name="l00392"></a>00392
|
|
<a name="l00393"></a>00393
|
|
<a name="l00404"></a>00404 <span class="keywordtype">void</span> <a class="code" href="group__wpcapfunc.html#ga9e0a5aad1a5dc79d85f1edfcebe0ac13" title="Free a filter.">pcap_freecode</a>(<span class="keyword">struct</span> bpf_program *fp);
|
|
<a name="l00405"></a>00405
|
|
<a name="l00485"></a>00485 <span class="keywordtype">int</span> <a class="code" href="group__wpcapfunc.html#ga64c019f851f7da6892d51cca15f12ace" title="Return the link layer of an adapter.">pcap_datalink</a>(<a class="code" href="group__wpcap__def.html#ga4711d025f83503ce692efa5e45ec60a7" title="Descriptor of an open capture instance. This structure is opaque to the user, that...">pcap_t</a> *p);
|
|
<a name="l00486"></a>00486
|
|
<a name="l00496"></a>00496 <span class="keywordtype">int</span> <a class="code" href="group__wpcapfunc.html#ga64e482360b0ed7d65fce1db23d56b921" title="list datalinks">pcap_list_datalinks</a>(<a class="code" href="group__wpcap__def.html#ga4711d025f83503ce692efa5e45ec60a7" title="Descriptor of an open capture instance. This structure is opaque to the user, that...">pcap_t</a> *p, <span class="keywordtype">int</span> **dlt_buf);
|
|
<a name="l00497"></a>00497
|
|
<a name="l00500"></a>00500 <span class="keywordtype">int</span> <a class="code" href="group__wpcapfunc.html#ga9588b99ac118cf827873d9e941eb6c77" title="Set the current data link type of the pcap descriptor to the type specified by dlt...">pcap_set_datalink</a>(<a class="code" href="group__wpcap__def.html#ga4711d025f83503ce692efa5e45ec60a7" title="Descriptor of an open capture instance. This structure is opaque to the user, that...">pcap_t</a> *p, <span class="keywordtype">int</span> dlt);
|
|
<a name="l00501"></a>00501
|
|
<a name="l00506"></a>00506 <span class="keywordtype">int</span> <a class="code" href="group__wpcapfunc.html#ga440b2f0757acd4804588933324909207" title="Translates a data link type name, which is a DLT_ name with the DLT_ removed, to...">pcap_datalink_name_to_val</a>(<span class="keyword">const</span> <span class="keywordtype">char</span> *name);
|
|
<a name="l00507"></a>00507
|
|
<a name="l00511"></a>00511 <span class="keyword">const</span> <span class="keywordtype">char</span> *<a class="code" href="group__wpcapfunc.html#gad45c16d494577f1886704af8f31ed442" title="Translates a data link type value to the corresponding data link type name. NULL...">pcap_datalink_val_to_name</a>(<span class="keywordtype">int</span> dlt);
|
|
<a name="l00512"></a>00512
|
|
<a name="l00516"></a>00516 <span class="keyword">const</span> <span class="keywordtype">char</span> *<a class="code" href="group__wpcapfunc.html#ga3f142cd0694b49357e4a73371db71411" title="Translates a data link type value to a short description of that data link type....">pcap_datalink_val_to_description</a>(<span class="keywordtype">int</span> dlt);
|
|
<a name="l00517"></a>00517
|
|
<a name="l00518"></a>00518
|
|
<a name="l00526"></a>00526 <span class="keywordtype">int</span> <a class="code" href="group__wpcapfunc.html#gae5c6e9768e89a6b82f9d720f37e6ab97" title="Return the dimension of the packet portion (in bytes) that is delivered to the application...">pcap_snapshot</a>(<a class="code" href="group__wpcap__def.html#ga4711d025f83503ce692efa5e45ec60a7" title="Descriptor of an open capture instance. This structure is opaque to the user, that...">pcap_t</a> *p);
|
|
<a name="l00527"></a>00527
|
|
<a name="l00528"></a>00528
|
|
<a name="l00532"></a>00532 <span class="keywordtype">int</span> <a class="code" href="group__wpcapfunc.html#gaba4941e09e5e03ba39841de4b1d5d6a4" title="returns true if the current savefile uses a different byte order than the current...">pcap_is_swapped</a>(<a class="code" href="group__wpcap__def.html#ga4711d025f83503ce692efa5e45ec60a7" title="Descriptor of an open capture instance. This structure is opaque to the user, that...">pcap_t</a> *p);
|
|
<a name="l00533"></a>00533
|
|
<a name="l00534"></a>00534
|
|
<a name="l00539"></a>00539 <span class="keywordtype">int</span> <a class="code" href="group__wpcapfunc.html#ga39dfb05149b443cc25b8febc455ca753" title="return the major version number of the pcap library used to write the savefile.">pcap_major_version</a>(<a class="code" href="group__wpcap__def.html#ga4711d025f83503ce692efa5e45ec60a7" title="Descriptor of an open capture instance. This structure is opaque to the user, that...">pcap_t</a> *p);
|
|
<a name="l00540"></a>00540
|
|
<a name="l00541"></a>00541
|
|
<a name="l00546"></a>00546 <span class="keywordtype">int</span> <a class="code" href="group__wpcapfunc.html#gac7a9dd9cd040ee500221cf35dfb49248" title="return the minor version number of the pcap library used to write the savefile.">pcap_minor_version</a>(<a class="code" href="group__wpcap__def.html#ga4711d025f83503ce692efa5e45ec60a7" title="Descriptor of an open capture instance. This structure is opaque to the user, that...">pcap_t</a> *p);
|
|
<a name="l00547"></a>00547
|
|
<a name="l00562"></a>00562 FILE *<a class="code" href="group__wpcapfunc.html#ga4c9f5690b99fb2af1f8904403f7da06b" title="Return the standard stream of an offline capture.">pcap_file</a>(<a class="code" href="group__wpcap__def.html#ga4711d025f83503ce692efa5e45ec60a7" title="Descriptor of an open capture instance. This structure is opaque to the user, that...">pcap_t</a> *p);
|
|
<a name="l00563"></a>00563
|
|
<a name="l00578"></a>00578 <span class="keywordtype">int</span> <a class="code" href="group__wpcapfunc.html#gabbd74d8c3ce1bcbccc76129ac38f4549" title="Return statistics on current capture.">pcap_stats</a>(<a class="code" href="group__wpcap__def.html#ga4711d025f83503ce692efa5e45ec60a7" title="Descriptor of an open capture instance. This structure is opaque to the user, that...">pcap_t</a> *p, <span class="keyword">struct</span> <a class="code" href="structpcap__stat.html" title="Structure that keeps statistical values on an interface.">pcap_stat</a> *ps);
|
|
<a name="l00579"></a>00579
|
|
<a name="l00584"></a>00584 <span class="keywordtype">void</span> <a class="code" href="group__wpcapfunc.html#gac3b6784c6c2623b93b22f6f219bd470e" title="print the text of the last pcap library error on stderr, prefixed by prefix.">pcap_perror</a>(<a class="code" href="group__wpcap__def.html#ga4711d025f83503ce692efa5e45ec60a7" title="Descriptor of an open capture instance. This structure is opaque to the user, that...">pcap_t</a> *p, <span class="keywordtype">char</span> *prefix);
|
|
<a name="l00585"></a>00585
|
|
<a name="l00586"></a>00586
|
|
<a name="l00596"></a>00596 <span class="keywordtype">char</span> *<a class="code" href="group__wpcapfunc.html#ga81305cb154e4497e95bbb9b708631a3a" title="return the error text pertaining to the last pcap library error.">pcap_geterr</a>(<a class="code" href="group__wpcap__def.html#ga4711d025f83503ce692efa5e45ec60a7" title="Descriptor of an open capture instance. This structure is opaque to the user, that...">pcap_t</a> *p);
|
|
<a name="l00597"></a>00597
|
|
<a name="l00598"></a>00598
|
|
<a name="l00604"></a>00604 <span class="keywordtype">char</span> *<a class="code" href="group__wpcapfunc.html#gafac2067e8f66f5a5a87f19f5e2b5ad4f" title="Provided in case strerror() isn&#39;t available.">pcap_strerror</a>(<span class="keywordtype">int</span> error);
|
|
<a name="l00605"></a>00605
|
|
<a name="l00610"></a>00610 <span class="keyword">const</span> <span class="keywordtype">char</span> *<a class="code" href="group__wpcapfunc.html#ga2d92cec9ff55906b5b6fb883e4bd72f4" title="Returns a pointer to a string giving information about the version of the libpcap...">pcap_lib_version</a>(<span class="keywordtype">void</span>);
|
|
<a name="l00611"></a>00611
|
|
<a name="l00617"></a>00617 <span class="keywordtype">void</span> <a class="code" href="group__wpcapfunc.html#gaa45a5e1a4ba9925bb3586dcbeec78560" title="close the files associated with p and deallocates resources.">pcap_close</a>(<a class="code" href="group__wpcap__def.html#ga4711d025f83503ce692efa5e45ec60a7" title="Descriptor of an open capture instance. This structure is opaque to the user, that...">pcap_t</a> *p);
|
|
<a name="l00618"></a>00618
|
|
<a name="l00620"></a>00620 FILE *<a class="code" href="group__wpcapfunc.html#ga8dac02f297422ff2ab5983d1e30c58b6" title="return the standard I/O stream of the &#39;savefile&#39; opened by pcap_dump_open()...">pcap_dump_file</a>(<a class="code" href="group__wpcap__def.html#gab8c7858aa3a7e3158d9d58cb113a2ae8" title="libpcap savefile descriptor.">pcap_dumper_t</a> *p);
|
|
<a name="l00621"></a>00621
|
|
<a name="l00626"></a>00626 <span class="keywordtype">int</span> <a class="code" href="group__wpcapfunc.html#ga90404ae3dcffcd3bbe78f8b187a88984" title="Flushes the output buffer to the ``savefile,&#39;&#39; so that any packets written...">pcap_dump_flush</a>(<a class="code" href="group__wpcap__def.html#gab8c7858aa3a7e3158d9d58cb113a2ae8" title="libpcap savefile descriptor.">pcap_dumper_t</a> *p);
|
|
<a name="l00627"></a>00627
|
|
<a name="l00632"></a>00632 <span class="keywordtype">void</span> <a class="code" href="group__wpcapfunc.html#ga3897795c1e9fb10571092febae964ef0" title="Closes a savefile.">pcap_dump_close</a>(<a class="code" href="group__wpcap__def.html#gab8c7858aa3a7e3158d9d58cb113a2ae8" title="libpcap savefile descriptor.">pcap_dumper_t</a> *p);
|
|
<a name="l00633"></a>00633
|
|
<a name="l00634"></a>00634 <span class="comment">//\}</span>
|
|
<a name="l00635"></a>00635 <span class="comment">// End of Unix-compatible functions</span>
|
|
<a name="l00636"></a>00636
|
|
<a name="l00637"></a>00637
|
|
<a name="l00638"></a>00638
|
|
<a name="l00639"></a>00639
|
|
<a name="l00640"></a>00640
|
|
<a name="l00641"></a>00641
|
|
<a name="l00642"></a>00642
|
|
<a name="l00649"></a>00649 <span class="comment">//\{ </span>
|
|
<a name="l00650"></a>00650
|
|
<a name="l00667"></a>00667 <a class="code" href="Win32-Extensions_8h.html#aadfdcc0e37082d8f6b28a43ec9a0bccf">PAirpcapHandle</a> <a class="code" href="group__wpcapfunc.html#ga4c8f8d1b9238c74faa156494a6b98670" title="Returns the AirPcap handler associated with an adapter. This handler can be used...">pcap_get_airpcap_handle</a>(<a class="code" href="group__wpcap__def.html#ga4711d025f83503ce692efa5e45ec60a7" title="Descriptor of an open capture instance. This structure is opaque to the user, that...">pcap_t</a> *p);
|
|
<a name="l00668"></a>00668
|
|
<a name="l00686"></a>00686 <span class="keywordtype">int</span> <a class="code" href="group__wpcapfunc.html#gae92f11bfb001c19b2d0fbcd6821d222a" title="Returns if a given filter applies to an offline packet.">pcap_offline_filter</a>(<span class="keyword">struct</span> bpf_program *prog, <span class="keyword">const</span> <span class="keyword">struct</span> <a class="code" href="structpcap__pkthdr.html" title="Header of a packet in the dump file.">pcap_pkthdr</a> *header, <span class="keyword">const</span> u_char *pkt_data);
|
|
<a name="l00687"></a>00687
|
|
<a name="l00712"></a>00712 <span class="keywordtype">int</span> <a class="code" href="group__wpcapfunc.html#gaedef54159d918b22a7de8e75b8a3ef4d" title="Save a capture to file.">pcap_live_dump</a>(<a class="code" href="group__wpcap__def.html#ga4711d025f83503ce692efa5e45ec60a7" title="Descriptor of an open capture instance. This structure is opaque to the user, that...">pcap_t</a> *p, <span class="keywordtype">char</span> *filename, <span class="keywordtype">int</span> maxsize, <span class="keywordtype">int</span> maxpacks);
|
|
<a name="l00713"></a>00713
|
|
<a name="l00714"></a>00714
|
|
<a name="l00731"></a>00731 <span class="keywordtype">int</span> <a class="code" href="group__wpcapfunc.html#gafe8a334f3a7ae2dc7f52e96523da39be" title="Return the status of the kernel dump process, i.e. tells if one of the limits defined...">pcap_live_dump_ended</a>(<a class="code" href="group__wpcap__def.html#ga4711d025f83503ce692efa5e45ec60a7" title="Descriptor of an open capture instance. This structure is opaque to the user, that...">pcap_t</a> *p, <span class="keywordtype">int</span> sync);
|
|
<a name="l00732"></a>00732
|
|
<a name="l00733"></a>00733
|
|
<a name="l00757"></a>00757 <span class="keyword">struct </span><a class="code" href="structpcap__stat.html" title="Structure that keeps statistical values on an interface.">pcap_stat</a> *<a class="code" href="group__wpcapfunc.html#ga8050f7829956aabd243cc32b3cfabbd6" title="Return statistics on current capture.">pcap_stats_ex</a>(<a class="code" href="group__wpcap__def.html#ga4711d025f83503ce692efa5e45ec60a7" title="Descriptor of an open capture instance. This structure is opaque to the user, that...">pcap_t</a> *p, <span class="keywordtype">int</span> *pcap_stat_size);
|
|
<a name="l00758"></a>00758
|
|
<a name="l00768"></a>00768 <span class="keywordtype">int</span> <a class="code" href="group__wpcapfunc.html#ga124bde25ccd9e39017ff2abec2dda623" title="Set the size of the kernel buffer associated with an adapter.">pcap_setbuff</a>(<a class="code" href="group__wpcap__def.html#ga4711d025f83503ce692efa5e45ec60a7" title="Descriptor of an open capture instance. This structure is opaque to the user, that...">pcap_t</a> *p, <span class="keywordtype">int</span> dim);
|
|
<a name="l00769"></a>00769
|
|
<a name="l00770"></a>00770
|
|
<a name="l00777"></a>00777 <span class="keywordtype">int</span> <a class="code" href="group__wpcapfunc.html#gaef07ef49d3c75644f3fd34518e2fe720" title="Set the working mode of the interface p to mode.">pcap_setmode</a>(<a class="code" href="group__wpcap__def.html#ga4711d025f83503ce692efa5e45ec60a7" title="Descriptor of an open capture instance. This structure is opaque to the user, that...">pcap_t</a> *p, <span class="keywordtype">int</span> mode);
|
|
<a name="l00778"></a>00778
|
|
<a name="l00779"></a>00779
|
|
<a name="l00793"></a>00793 <span class="keywordtype">int</span> <a class="code" href="group__wpcapfunc.html#gab14ceacbf1c2f63026416dd73f80dc0d" title="Set the minumum amount of data received by the kernel in a single call.">pcap_setmintocopy</a>(<a class="code" href="group__wpcap__def.html#ga4711d025f83503ce692efa5e45ec60a7" title="Descriptor of an open capture instance. This structure is opaque to the user, that...">pcap_t</a> *p, <span class="keywordtype">int</span> size);
|
|
<a name="l00794"></a>00794
|
|
<a name="l00795"></a>00795
|
|
<a name="l00796"></a>00796
|
|
<a name="l00806"></a>00806 HANDLE <a class="code" href="group__wpcapfunc.html#ga2c415e9192c7b18a81a02300ae6f2c02" title="Return the handle of the event associated with the interface p.">pcap_getevent</a>(<a class="code" href="group__wpcap__def.html#ga4711d025f83503ce692efa5e45ec60a7" title="Descriptor of an open capture instance. This structure is opaque to the user, that...">pcap_t</a> *p);
|
|
<a name="l00807"></a>00807
|
|
<a name="l00820"></a>00820 <a class="code" href="structpcap__send__queue.html" title="A queue of raw packets that will be sent to the network with pcap_sendqueue_transmit()...">pcap_send_queue</a>* <a class="code" href="group__wpcapfunc.html#gab940e69631b7cc7f2232a69ea02b86d9" title="Allocate a send queue.">pcap_sendqueue_alloc</a>(u_int memsize);
|
|
<a name="l00821"></a>00821
|
|
<a name="l00828"></a>00828 <span class="keywordtype">void</span> <a class="code" href="group__wpcapfunc.html#ga72624f7a9932cc2124abf661001e0aa4" title="Destroy a send queue.">pcap_sendqueue_destroy</a>(<a class="code" href="structpcap__send__queue.html" title="A queue of raw packets that will be sent to the network with pcap_sendqueue_transmit()...">pcap_send_queue</a>* queue);
|
|
<a name="l00829"></a>00829
|
|
<a name="l00844"></a>00844 <span class="keywordtype">int</span> <a class="code" href="group__wpcapfunc.html#ga4c57ea320d71dbfe55c5665af9db1297" title="Add a packet to a send queue.">pcap_sendqueue_queue</a>(<a class="code" href="structpcap__send__queue.html" title="A queue of raw packets that will be sent to the network with pcap_sendqueue_transmit()...">pcap_send_queue</a>* queue, <span class="keyword">const</span> <span class="keyword">struct</span> <a class="code" href="structpcap__pkthdr.html" title="Header of a packet in the dump file.">pcap_pkthdr</a> *pkt_header, <span class="keyword">const</span> u_char *pkt_data);
|
|
<a name="l00845"></a>00845
|
|
<a name="l00846"></a>00846
|
|
<a name="l00870"></a>00870 u_int <a class="code" href="group__wpcapfunc.html#gaa4d55eb047a1cccc0e28397ce04ee097" title="Send a queue of raw packets to the network.">pcap_sendqueue_transmit</a>(<a class="code" href="group__wpcap__def.html#ga4711d025f83503ce692efa5e45ec60a7" title="Descriptor of an open capture instance. This structure is opaque to the user, that...">pcap_t</a> *p, <a class="code" href="structpcap__send__queue.html" title="A queue of raw packets that will be sent to the network with pcap_sendqueue_transmit()...">pcap_send_queue</a>* queue, <span class="keywordtype">int</span> sync);
|
|
<a name="l00871"></a>00871
|
|
<a name="l00872"></a>00872
|
|
<a name="l00935"></a>00935 <span class="keywordtype">int</span> <a class="code" href="group__wpcapfunc.html#ga98f36e62c95c6ad81eaa8b2bbeb8f16e" title="Create a list of network devices that can be opened with pcap_open().">pcap_findalldevs_ex</a>(<span class="keywordtype">char</span> *source, <span class="keyword">struct</span> <a class="code" href="structpcap__rmtauth.html" title="This structure keeps the information needed to autheticate the user on a remote machine...">pcap_rmtauth</a> *auth, <a class="code" href="structpcap__if.html" title="Item in a list of interfaces, used by pcap_findalldevs().">pcap_if_t</a> **alldevs, <span class="keywordtype">char</span> *errbuf);
|
|
<a name="l00936"></a>00936
|
|
<a name="l00937"></a>00937
|
|
<a name="l00981"></a>00981 <span class="keywordtype">int</span> <a class="code" href="group__wpcapfunc.html#gaa3111e10f930a9772a32a922b26948b0" title="Accept a set of strings (host name, port, ...), and it returns the complete source...">pcap_createsrcstr</a>(<span class="keywordtype">char</span> *source, <span class="keywordtype">int</span> type, <span class="keyword">const</span> <span class="keywordtype">char</span> *<a class="code" href="wpcap__remote_8htm.html#a3c46d79c790748a5942fb43baa6b3073">host</a>, <span class="keyword">const</span> <span class="keywordtype">char</span> *port, <span class="keyword">const</span> <span class="keywordtype">char</span> *name, <span class="keywordtype">char</span> *errbuf);
|
|
<a name="l00982"></a>00982
|
|
<a name="l00983"></a>00983
|
|
<a name="l01039"></a>01039 <span class="keywordtype">int</span> <a class="code" href="group__wpcapfunc.html#ga090e0afd3f463b4b60a64c47eddc1ba2" title="Parse the source string and returns the pieces in which the source can be split.">pcap_parsesrcstr</a>(<span class="keyword">const</span> <span class="keywordtype">char</span> *source, <span class="keywordtype">int</span> *type, <span class="keywordtype">char</span> *<a class="code" href="wpcap__remote_8htm.html#a3c46d79c790748a5942fb43baa6b3073">host</a>, <span class="keywordtype">char</span> *port, <span class="keywordtype">char</span> *name, <span class="keywordtype">char</span> *errbuf);
|
|
<a name="l01040"></a>01040
|
|
<a name="l01106"></a>01106 <a class="code" href="group__wpcap__def.html#ga4711d025f83503ce692efa5e45ec60a7" title="Descriptor of an open capture instance. This structure is opaque to the user, that...">pcap_t</a> *<a class="code" href="group__wpcapfunc.html#ga2b64c7b6490090d1d37088794f1f1791" title="Open a generic source in order to capture / send (WinPcap only) traffic.">pcap_open</a>(<span class="keyword">const</span> <span class="keywordtype">char</span> *source, <span class="keywordtype">int</span> snaplen, <span class="keywordtype">int</span> flags, <span class="keywordtype">int</span> read_timeout, <span class="keyword">struct</span> <a class="code" href="structpcap__rmtauth.html" title="This structure keeps the information needed to autheticate the user on a remote machine...">pcap_rmtauth</a> *auth, <span class="keywordtype">char</span> *errbuf);
|
|
<a name="l01107"></a>01107
|
|
<a name="l01123"></a>01123 <span class="keyword">struct </span><a class="code" href="structpcap__samp.html" title="This structure defines the information related to sampling.">pcap_samp</a> *<a class="code" href="group__wpcapfunc.html#ga84c7d55f5b0e7d545b38d6b8e7bde005" title="Define a sampling method for packet capture.">pcap_setsampling</a>(<a class="code" href="group__wpcap__def.html#ga4711d025f83503ce692efa5e45ec60a7" title="Descriptor of an open capture instance. This structure is opaque to the user, that...">pcap_t</a> *p);
|
|
<a name="l01124"></a>01124
|
|
<a name="l01184"></a>01184 SOCKET <a class="code" href="group__wpcapfunc.html#ga5495943cc8262db57f726e2a23f837dd" title="Block until a network connection is accepted (active mode only).">pcap_remoteact_accept</a>(<span class="keyword">const</span> <span class="keywordtype">char</span> *address, <span class="keyword">const</span> <span class="keywordtype">char</span> *port, <span class="keyword">const</span> <span class="keywordtype">char</span> *hostlist, <span class="keywordtype">char</span> *connectinghost, <span class="keyword">struct</span> <a class="code" href="structpcap__rmtauth.html" title="This structure keeps the information needed to autheticate the user on a remote machine...">pcap_rmtauth</a> *auth, <span class="keywordtype">char</span> *errbuf);
|
|
<a name="l01185"></a>01185
|
|
<a name="l01202"></a>01202 <span class="keywordtype">int</span> <a class="code" href="group__wpcapfunc.html#ga6a84e03497f946d61c440696e57e2c95" title="Drop an active connection (active mode only).">pcap_remoteact_close</a>(<span class="keyword">const</span> <span class="keywordtype">char</span> *<a class="code" href="wpcap__remote_8htm.html#a3c46d79c790748a5942fb43baa6b3073">host</a>, <span class="keywordtype">char</span> *errbuf);
|
|
<a name="l01203"></a>01203
|
|
<a name="l01222"></a>01222 <span class="keywordtype">void</span> <a class="code" href="group__wpcapfunc.html#ga7b022e0a67f5ff62fd13df5c688d6d82" title="Clean the socket that is currently used in waiting active connections.">pcap_remoteact_cleanup</a>();
|
|
<a name="l01223"></a>01223
|
|
<a name="l01244"></a>01244 <span class="keywordtype">int</span> <a class="code" href="group__wpcapfunc.html#ga7ee8f666bff537aa457b7c05651cf815" title="Return the hostname of the host that have an active connection with us (active mode...">pcap_remoteact_list</a>(<span class="keywordtype">char</span> *hostlist, <span class="keywordtype">char</span> sep, <span class="keywordtype">int</span> size, <span class="keywordtype">char</span> *errbuf);
|
|
<a name="l01245"></a>01245
|
|
<a name="l01246"></a>01246 <span class="comment">//\}</span>
|
|
<a name="l01247"></a>01247 <span class="comment">// End of Windows-specific extensions</span>
|
|
<a name="l01248"></a>01248
|
|
<a name="l01249"></a>01249
|
|
<a name="l01250"></a>01250
|
|
</pre></div></div>
|
|
|
|
<hr>
|
|
<p align="right"><img border="0" src="winpcap_small.gif" align="absbottom" width="91" height="27">
|
|
documentation. Copyright (c) 2002-2005 Politecnico di Torino. Copyright (c) 2005-2009
|
|
CACE Technologies. All rights reserved.</p>
|