亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? packet32.h

?? 控制臺輸出的winpcap抓包程序
?? H
?? 第 1 頁 / 共 2 頁
字號:
/*
 * Copyright (c) 1999 - 2005 NetGroup, Politecnico di Torino (Italy)
 * Copyright (c) 2005 - 2006 CACE Technologies, Davis (California)
 * All rights reserved.
 *
 * Redistribution and use in source and binary forms, with or without
 * modification, are permitted provided that the following conditions
 * are met:
 *
 * 1. Redistributions of source code must retain the above copyright
 * notice, this list of conditions and the following disclaimer.
 * 2. Redistributions in binary form must reproduce the above copyright
 * notice, this list of conditions and the following disclaimer in the
 * documentation and/or other materials provided with the distribution.
 * 3. Neither the name of the Politecnico di Torino, CACE Technologies 
 * nor the names of its contributors may be used to endorse or promote 
 * products derived from this software without specific prior written 
 * permission.
 *
 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
 * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
 * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
 * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
 * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
 * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
 * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 *
 */

/** @ingroup packetapi
 *  @{ 
 */

/** @defgroup packet32h Packet.dll definitions and data structures
 *  Packet32.h contains the data structures and the definitions used by packet.dll.
 *  The file is used both by the Win9x and the WinNTx versions of packet.dll, and can be included
 *  by the applications that use the functions of this library
 *  @{
 */

#ifndef __PACKET32
#define __PACKET32

#include <winsock2.h>

#include "devioctl.h"

#ifdef HAVE_AIRPCAP_API
#include <airpcap.h>
#else
#if !defined(AIRPCAP_HANDLE__EAE405F5_0171_9592_B3C2_C19EC426AD34__DEFINED_)
#define AIRPCAP_HANDLE__EAE405F5_0171_9592_B3C2_C19EC426AD34__DEFINED_
typedef struct _AirpcapHandle *PAirpcapHandle;
#endif /* AIRPCAP_HANDLE__EAE405F5_0171_9592_B3C2_C19EC426AD34__DEFINED_ */
#endif /* HAVE_AIRPCAP_API */

#ifdef HAVE_DAG_API
#include <dagc.h>
#endif /* HAVE_DAG_API */

// Working modes
#define PACKET_MODE_CAPT 0x0 ///< Capture mode
#define PACKET_MODE_STAT 0x1 ///< Statistical mode
#define PACKET_MODE_MON 0x2 ///< Monitoring mode
#define PACKET_MODE_DUMP 0x10 ///< Dump mode
#define PACKET_MODE_STAT_DUMP MODE_DUMP | MODE_STAT ///< Statistical dump Mode

// ioctls
#define FILE_DEVICE_PROTOCOL        0x8000

#define IOCTL_PROTOCOL_STATISTICS   CTL_CODE(FILE_DEVICE_PROTOCOL, 2 , METHOD_BUFFERED, FILE_ANY_ACCESS)
#define IOCTL_PROTOCOL_RESET        CTL_CODE(FILE_DEVICE_PROTOCOL, 3 , METHOD_BUFFERED, FILE_ANY_ACCESS)
#define IOCTL_PROTOCOL_READ         CTL_CODE(FILE_DEVICE_PROTOCOL, 4 , METHOD_BUFFERED, FILE_ANY_ACCESS)
#define IOCTL_PROTOCOL_WRITE        CTL_CODE(FILE_DEVICE_PROTOCOL, 5 , METHOD_BUFFERED, FILE_ANY_ACCESS)
#define IOCTL_PROTOCOL_MACNAME      CTL_CODE(FILE_DEVICE_PROTOCOL, 6 , METHOD_BUFFERED, FILE_ANY_ACCESS)
#define IOCTL_OPEN                  CTL_CODE(FILE_DEVICE_PROTOCOL, 7 , METHOD_BUFFERED, FILE_ANY_ACCESS)
#define IOCTL_CLOSE                 CTL_CODE(FILE_DEVICE_PROTOCOL, 8 , METHOD_BUFFERED, FILE_ANY_ACCESS)

#define	 pBIOCSETBUFFERSIZE 9592		///< IOCTL code: set kernel buffer size.
#define	 pBIOCSETF 9030					///< IOCTL code: set packet filtering program.
#define  pBIOCGSTATS 9031				///< IOCTL code: get the capture stats.
#define	 pBIOCSRTIMEOUT 7416			///< IOCTL code: set the read timeout.
#define	 pBIOCSMODE 7412				///< IOCTL code: set working mode.
#define	 pBIOCSWRITEREP 7413			///< IOCTL code: set number of physical repetions of every packet written by the app.
#define	 pBIOCSMINTOCOPY 7414			///< IOCTL code: set minimum amount of data in the kernel buffer that unlocks a read call.
#define	 pBIOCSETOID 2147483648U		///< IOCTL code: set an OID value.
#define	 pBIOCQUERYOID 2147483652U		///< IOCTL code: get an OID value.
#define	 pATTACHPROCESS 7117			///< IOCTL code: attach a process to the driver. Used in Win9x only.
#define	 pDETACHPROCESS 7118			///< IOCTL code: detach a process from the driver. Used in Win9x only.
#define  pBIOCSETDUMPFILENAME 9029		///< IOCTL code: set the name of a the file used by kernel dump mode.
#define  pBIOCEVNAME 7415				///< IOCTL code: get the name of the event that the driver signals when some data is present in the buffer.
#define  pBIOCSENDPACKETSNOSYNC 9032	///< IOCTL code: Send a buffer containing multiple packets to the network, ignoring the timestamps associated with the packets.
#define  pBIOCSENDPACKETSSYNC 9033		///< IOCTL code: Send a buffer containing multiple packets to the network, respecting the timestamps associated with the packets.
#define  pBIOCSETDUMPLIMITS 9034		///< IOCTL code: Set the dump file limits. See the PacketSetDumpLimits() function.
#define  pBIOCISDUMPENDED 7411			///< IOCTL code: Get the status of the kernel dump process. See the PacketIsDumpEnded() function.
#define  pBIOCISETLOBBEH 7410			///< IOCTL code: Set the loopback behavior of the driver with packets sent by itself: capture or drop.
#define  pBIOCSETEVENTHANDLE 7920		///< IOCTL code: Passes the read event HANDLE allocated by the user (packet.dll) to the kernel level driver.

#define  pBIOCSTIMEZONE 7471			///< IOCTL code: set time zone. Used in Win9x only.


/// Alignment macro. Defines the alignment size.
#define Packet_ALIGNMENT sizeof(int)
/// Alignment macro. Rounds up to the next even multiple of Packet_ALIGNMENT. 
#define Packet_WORDALIGN(x) (((x)+(Packet_ALIGNMENT-1))&~(Packet_ALIGNMENT-1))

#define NdisMediumNull	-1		///< Custom linktype: NDIS doesn't provide an equivalent
#define NdisMediumCHDLC	-2		///< Custom linktype: NDIS doesn't provide an equivalent
#define NdisMediumPPPSerial	-3	///< Custom linktype: NDIS doesn't provide an equivalent
#define NdisMediumBare80211	-4	///< Custom linktype: NDIS doesn't provide an equivalent
#define NdisMediumRadio80211	-5	///< Custom linktype: NDIS doesn't provide an equivalent

// Loopback behaviour definitions
#define NPF_DISABLE_LOOPBACK	1	///< Drop the packets sent by the NPF driver
#define NPF_ENABLE_LOOPBACK		2	///< Capture the packets sent by the NPF driver

/*!
  \brief Network type structure.

  This structure is used by the PacketGetNetType() function to return information on the current adapter's type and speed.
*/
typedef struct NetType
{
	UINT LinkType;	///< The MAC of the current network adapter (see function PacketGetNetType() for more information)
	ULONGLONG LinkSpeed;	///< The speed of the network in bits per second
}NetType;


//some definitions stolen from libpcap

#ifndef BPF_MAJOR_VERSION

/*!
  \brief A BPF pseudo-assembly program.

  The program will be injected in the kernel by the PacketSetBPF() function and applied to every incoming packet. 
*/
struct bpf_program 
{
	UINT bf_len;				///< Indicates the number of instructions of the program, i.e. the number of struct bpf_insn that will follow.
	struct bpf_insn *bf_insns;	///< A pointer to the first instruction of the program.
};

/*!
  \brief A single BPF pseudo-instruction.

  bpf_insn contains a single instruction for the BPF register-machine. It is used to send a filter program to the driver.
*/
struct bpf_insn 
{
	USHORT	code;		///< Instruction type and addressing mode.
	UCHAR 	jt;			///< Jump if true
	UCHAR 	jf;			///< Jump if false
	int k;				///< Generic field used for various purposes.
};

/*!
  \brief Structure that contains a couple of statistics values on the current capture.

  It is used by packet.dll to return statistics about a capture session.
*/
struct bpf_stat 
{
	UINT bs_recv;		///< Number of packets that the driver received from the network adapter 
						///< from the beginning of the current capture. This value includes the packets 
						///< lost by the driver.
	UINT bs_drop;		///< number of packets that the driver lost from the beginning of a capture. 
						///< Basically, a packet is lost when the the buffer of the driver is full. 
						///< In this situation the packet cannot be stored and the driver rejects it.
	UINT ps_ifdrop;		///< drops by interface. XXX not yet supported
	UINT bs_capt;		///< number of packets that pass the filter, find place in the kernel buffer and
						///< thus reach the application.
};

/*!
  \brief Packet header.

  This structure defines the header associated with every packet delivered to the application.
*/
struct bpf_hdr 
{
	struct timeval	bh_tstamp;	///< The timestamp associated with the captured packet. 
								///< It is stored in a TimeVal structure.
	UINT	bh_caplen;			///< Length of captured portion. The captured portion <b>can be different</b>
								///< from the original packet, because it is possible (with a proper filter)
								///< to instruct the driver to capture only a portion of the packets.
	UINT	bh_datalen;			///< Original length of packet
	USHORT		bh_hdrlen;		///< Length of bpf header (this struct plus alignment padding). In some cases,
								///< a padding could be added between the end of this structure and the packet
								///< data for performance reasons. This filed can be used to retrieve the actual data 
								///< of the packet.
};

/*!
  \brief Dump packet header.

  This structure defines the header associated with the packets in a buffer to be used with PacketSendPackets().
  It is simpler than the bpf_hdr, because it corresponds to the header associated by WinPcap and libpcap to a
  packet in a dump file. This makes straightforward sending WinPcap dump files to the network.

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
爽好多水快深点欧美视频| 91欧美一区二区| 一级中文字幕一区二区| 国产精品欧美一区喷水| 久久久噜噜噜久噜久久综合| 欧美一区二区三区免费大片| 欧美午夜精品久久久| 欧美亚洲动漫精品| 欧美日韩精品高清| 欧美一级片免费看| 91精品国产高清一区二区三区蜜臀| 欧洲精品一区二区三区在线观看| 日本久久精品电影| 在线不卡中文字幕播放| 精品国产乱码久久久久久久 | 成人性生交大片| 色吊一区二区三区| 中文字幕精品一区| 亚瑟在线精品视频| 洋洋av久久久久久久一区| 亚洲一二三级电影| 轻轻草成人在线| 国产精品每日更新| 亚洲一区二区三区视频在线 | 中文字幕在线免费不卡| 亚洲午夜私人影院| 成人免费不卡视频| 日韩久久免费av| 青椒成人免费视频| 国产精品456露脸| 在线观看国产精品网站| 欧美日韩国产123区| 精品国产乱码久久久久久免费| 国产亚洲欧美激情| 亚洲国产cao| 在线免费观看日本欧美| 国产视频一区不卡| 成人av网站免费观看| 中文字幕在线一区免费| 高清成人免费视频| 亚洲欧洲在线观看av| 91福利在线看| 亚洲一区二区不卡免费| 国产99久久久久| 精品国产91久久久久久久妲己| 蜜桃精品在线观看| 亚洲精品一区二区精华| 国内精品久久久久影院薰衣草 | caoporm超碰国产精品| 国产欧美日本一区二区三区| 乱一区二区av| 国产精品全国免费观看高清| 91无套直看片红桃| 天天色 色综合| 国产精品美女久久久久久久 | 精品国偷自产国产一区| 国产成人在线看| 一区二区三区不卡视频| 精品国产乱码久久久久久浪潮| 99re成人在线| 欧美a一区二区| 五月天一区二区三区| 亚洲免费观看高清完整版在线观看| 欧美日韩电影一区| 欧美一区二区三区白人| 欧美成人精品3d动漫h| 成人精品高清在线| 国内精品自线一区二区三区视频| 一区二区三区四区五区视频在线观看| 国产色产综合色产在线视频| 日韩免费在线观看| 久久在线免费观看| 欧美激情在线看| 国产精品三级av在线播放| 国产精品成人免费| 一区二区三区 在线观看视频| 亚洲乱码国产乱码精品精可以看 | 这里只有精品电影| 欧美sm美女调教| 国产精品不卡在线| 亚洲一区二区三区四区五区黄| 亚洲国产欧美在线| 国产精品自在在线| 日本韩国一区二区| 56国语精品自产拍在线观看| 欧美xxxx在线观看| 亚洲欧洲成人av每日更新| 亚洲3atv精品一区二区三区| 激情六月婷婷综合| 91论坛在线播放| 久久精品人人爽人人爽| 亚洲激情六月丁香| 97se亚洲国产综合自在线| 精品第一国产综合精品aⅴ| 亚洲一区在线观看免费| 99精品热视频| 国产精品乱人伦中文| 美日韩一级片在线观看| 91在线无精精品入口| 久久久精品免费观看| 久久精品国产精品亚洲精品| 91久久奴性调教| 亚洲天天做日日做天天谢日日欢 | 欧美日韩免费一区二区三区| 国产精品沙发午睡系列990531| 激情综合网av| 精品美女在线播放| 国产在线一区观看| 国产视频一区二区在线| 国产精品亚洲视频| 国产精品久久影院| 99在线精品免费| 一区二区三国产精华液| 精品视频一区二区三区免费| 亚洲男人的天堂在线观看| 91毛片在线观看| 免费高清成人在线| 国产亚洲美州欧州综合国| 99精品视频免费在线观看| 亚洲成人综合视频| 精品国产露脸精彩对白| 成人av在线网站| 日韩精品福利网| 国产精品久久久久一区二区三区 | 三级欧美在线一区| 国产丝袜美腿一区二区三区| 91香蕉视频黄| 成人一区二区视频| 麻豆久久久久久久| 中文字幕一区二区三区精华液| 欧美挠脚心视频网站| 岛国av在线一区| 狠狠色综合色综合网络| 亚洲狠狠丁香婷婷综合久久久| 欧美一区二区三区成人| 欧美丰满嫩嫩电影| 欧美日韩高清一区二区不卡| 91久久精品网| 欧美三片在线视频观看| 成人性视频网站| 国产精品77777| 国产一区二区看久久| 另类小说综合欧美亚洲| 蜜臀va亚洲va欧美va天堂 | 欧美草草影院在线视频| 2022国产精品视频| www国产精品av| 国产精品美女久久久久久2018| 欧美精品一区二区在线播放| 久久综合国产精品| 国产精品系列在线| 亚洲欧洲成人自拍| 亚洲精品亚洲人成人网| 午夜久久久久久电影| 麻豆成人在线观看| 91丝袜国产在线播放| 欧美日韩高清一区二区不卡| 精品国产乱码久久久久久浪潮| 国产精品福利一区二区三区| 中文字幕一区二区三区蜜月| 亚洲综合成人在线视频| 久久99热国产| 色综合久久中文字幕综合网| 欧美日韩中文字幕一区| av在线不卡网| 成人精品视频一区二区三区 | 国产精品一区2区| va亚洲va日韩不卡在线观看| 91精品国产综合久久国产大片| 精品不卡在线视频| 视频一区中文字幕| 91在线porny国产在线看| 精品国产乱码久久| 天天免费综合色| 色www精品视频在线观看| 国产亚洲欧美日韩日本| 麻豆91在线观看| 日韩一区二区三区三四区视频在线观看| 欧美国产一区二区在线观看| 亚洲欧洲99久久| 久久99在线观看| 日韩欧美亚洲国产另类| 日日夜夜免费精品视频| 欧美日韩mp4| 男人的天堂亚洲一区| 欧美一区二区三区视频免费播放| 日韩理论电影院| 欧美调教femdomvk| 一区二区三区91| 日韩欧美激情在线| 国产成人精品免费在线| 亚洲色图一区二区| 精品视频一区三区九区| 国精产品一区一区三区mba桃花| 精品日韩一区二区三区免费视频| 国产美女精品一区二区三区| 国产精品国产三级国产普通话三级| 高清国产一区二区| 午夜成人免费电影| 久久久精品天堂|