?? define.h
字號:
#ifndef _NET_MONITOR_KERNEL_DEFINE_H_
#define _NET_MONITOR_KERNEL_DEFINE_H_
#include "nb30.h"
typedef unsigned char byte;
typedef struct _ASTAT_
{
ADAPTER_STATUS adapt;
NAME_BUFFER NameBuff [30];
}ASTAT, * PASTAT;
//定義ip報頭
typedef struct _iphdr
{
byte ver_len; //版本4位,頭長度4位,報頭長度以32位為一個單位
byte type; //類型8位
byte length[2]; //總長度,16位,指出報文的以字節為單位的總長度
//報文長度不能超過65536個字接,否則認為報文遭到破壞
byte id[2]; //報文標示,用于多于一個報文16位
byte flag_offset[2];//標志,3位 數據塊偏移13位
byte time; //生存時間,8位
byte protocol; //協議,8位
byte crc_val[2]; //頭校驗和,16位
byte src_addr[4]; //源地址,32位
byte tar_addr[4]; //目標地址,32位
byte options[4]; //選項和填充,32位
}IP_HEADER;
typedef struct _tcphdr
{
byte source_port[2]; //發送端端口號,16位
byte dest_port[2]; //接收端端口號,16位
byte sequence_no[4]; //32位,標示消息端的數據位于全體數據塊的某一字節的數字
byte ack_no[4]; //32位,確認號,標示接收端對于發送端接收到數據塊數值
byte offset_reser_con[2];//數據偏移4位,預留6位,控制位6為
byte window[2]; //窗口16位
byte checksum[2]; //校驗碼,16位
byte urgen_pointer[2]; //16位,緊急數據指針
byte options[3]; //選祥和填充,32位
}TCP_HEADER;
#define SIO_RCVALL _WSAIOW(IOC_VENDOR,1)
#define IP_HDRINCL 2 /* header is included with data */
//參考資料 RFC 1700
#define PROTOCOL_ICMP 1 //ICMP
#define PROTOCOL_IGMP 2 //Internet Group Management
#define PROTOCOL_GGP 3 //Gateway-to-Gateway
#define PROTOCOL_IP 4 //IP in IP (encasulation)
#define PROTOCOL_ST 5 //Stream
#define PROTOCOL_TCP 6 //Transmission Control
#define PROTOCOL_UCL 7 //UCL
#define PROTOCOL_EGP 8 //Exterior Gateway Protocol
#define PROTOCOL_IGP 9 //any private interior gateway
#define PROTOCOL_BBN_RCC_MON 10 //BBN RCC Monitoring
#define PROTOCOL_NVP_II 11 //Network Voice Protocol
#define PROTOCOL_PUP 12 //PUP
#define PROTOCOL_ARGUS 13 //ARGUS
#define PROTOCOL_EMCON 14 //EMCON
#define PROTOCOL_XNET 15 //Cross Net Debugger
#define PROTOCOL_CHAOS 16 //Chaos
#define PROTOCOL_UDP 17 //User Datagram
#define PROTOCOL_MUX 18 //Multiplexing
#define PROTOCOL_DCN_MEAS 19 //DCN Measurement Subsystems
#define PROTOCOL_HMP 20 //Host Monitoring
#define PROTOCOL_PRM 21 //Packet Radio Measurement
#define PROTOCOL_XNS_IDP 22 //XEROX NS IDP
#define PROTOCOL_TRUNK_1 23 //Trunk-1
#define PROTOCOL_TRUNK_2 24 //Trunk-2
#define PROTOCOL_LEAF_1 25 //Leaf-1
#define PROTOCOL_LEAF_2 26 //Leaf-2
#define PROTOCOL_RDP 27 //Reliable Data Protocol
#define PROTOCOL_IRTP 28 //Internet Reliable Transaction
#define PROTOCOL_ISO_TP4 29 //ISO Transport Protocol Class
#define PROTOCOL_NETBLT 30 //Bulk Data Transfer Protocol
#define PROTOCOL_MFE_NSP 31 //MFE Network Services Protocol
#define PROTOCOL_MERIT_INP 32 //MERIT Internodal Protocol
#define PROTOCOL_SEP 33 //Sequential Exchange Protocol
#define PROTOCOL_3PC 34 //Third Party Connect Protocol
#define PROTOCOL_IDPR 35 //Inter-Domain Policy Routing Protocol
#define PROTOCOL_XTP 36 //XTP
#define PROTOCOL_DDP 37 //Datagram Delivery Protocol
#define PROTOCOL_IDPR_CMTP 38 //IDPR Control Message Transport Proto
#define PROTOCOL_TPTP 39 //TP++ Transport Protocol
#define PROTOCOL_IL 40 //IL Transport Protocol
#define PROTOCOL_SIP 41 //Simple Internet Protocol
#define PROTOCOL_SDRP 42 //Source Demand Routing Protocol
#define PROTOCOL_SIP_SR 43 //SIP Source Route
#define PROTOCOL_SIP_FRAG 44 //SIP Fragment
#define PROTOCOL_IDRP 45 //Inter-Domain Routing Protocol
#define PROTOCOL_RSVP 46 //IReservation Protocol
#define PROTOCOL_GRE 47 //General Routing Encapsulation
#define PROTOCOL_MHRP 48 //Mobile Host Routing Protocol
#define PROTOCOL_BNA 49 //BNA
#define PROTOCOL_SIPP_ESP 50 //SIPP Encap Security Payload
#define PROTOCOL_SIPP_AH 51 //SIPP Authentication Header
#define PROTOCOL_I_NLSP 52 //Integrated Net Layer Security
#define PROTOCOL_SWIPE 53 //IP with Encryption
#define PROTOCOL_NHRP 54 //NBMA Next Hop Resolution Protocol
#define PROTOCOL_AHIP 61 //any host internal protocol
#define PROTOCOL_CFTP 62 //CFTP
#define PROTOCOL_ALN 63 //any local network
#define PROTOCOL_SAT_EXPAK 64 //SATNET and Backroom EXPAK
#define PROTOCOL_KRYPTOLAN 65 //Kryptolan
#define PROTOCOL_RVD 66 //MIT Remote Virtual Disk Protocol
#define PROTOCOL_IPPC 67 //Internet Pluribus Packet Core
#define PROTOCOL_ADFS 68 //any distributed file system
#define PROTOCOL_SAT_MON 69 //SATNET Monitoring
#define PROTOCOL_VISA 70 //VISA Protocol
#define PROTOCOL_IPCV 71 //Internet Packet Core Utility
#define PROTOCOL_CPNX 72 //Computer Protocol Network Executive
#define PROTOCOL_CPHB 73 //Computer Protocol Heart Beat
#define PROTOCOL_WSN 74 //Wang Span Network
#define PROTOCOL_PVP 75 //Packet Video Protocol
#define PROTOCOL_BR_SAT_MON 76 //Backroom SATNET Monitoring
#define PROTOCOL_SUN_ND 77 //SUN ND PROTOCOL-Temporary
#define PROTOCOL_WB_MON 78 //WIDEBAND Monitoring
#define PROTOCOL_WB_EXPAK 79 //WIDEBAND EXPAK
#define PROTOCOL_ISO_IP 80 //ISO Internet Protocol
#define PROTOCOL_VMTP 81 //VMTP
#define PROTOCOL_SECURE_VMTP 82 //SECURE-VMTP
#define PROTOCOL_VINES 83 //VINES
#define PROTOCOL_TTP 84 //TTP
#define PROTOCOL_NSFNET_IGP 85 //NSFNET-IGP
#define PROTOCOL_DGP 86 // Dissimilar Gateway Protocol
#define PROTOCOL_TCF 87 //TCF
#define PROTOCOL_IGRP 88 //IGRP
#define PROTOCOL_OSPFIGP 89 //OSPFIGP
#define PROTOCOL_Sprite_RPC 90 //Sprite RPC Protocol
#define PROTOCOL_LARP 91 //Locus Address Resolution Protocol
#define PROTOCOL_MTP 92 //Multicast Transport Protocol
#define PROTOCOL_AX25 93 //AX.25 Frames
#define PROTOCOL_IPIP 94 //IP-within-IP Encapsulation Protocol
#define PROTOCOL_MICP 95 //Mobile Internetworking Control Pro.
#define PROTOCOL_SCC_SP 96 //Semaphore Communications Sec. Pro.
#define PROTOCOL_ETHERIP 97 //Ethernet-within-IP Encapsulation
#define PROTOCOL_ENCAP 98 //Encapsulation Header
#define PROTOCOL_APES 99 //any private encryption scheme
#define PROTOCOL_GMTP 100 //GMTP
#endif
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -