-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathIPPacket.h
More file actions
41 lines (31 loc) · 715 Bytes
/
IPPacket.h
File metadata and controls
41 lines (31 loc) · 715 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
// IPPacket.h: interface for the CIPPacket class.
//
//////////////////////////////////////////////////////////////////////
#ifndef IPPACKET_H
#define IPPACKET_H
#pragma once
#include "common.h"
typedef struct tagIPHEADER
{
BYTE cbHeaderLen:4;
BYTE cbVersion:4;
BYTE cbTOS;
WORD wTotalLen;
WORD wPacketId;
WORD fMoreFragments:1;
WORD fNotFragment:1;
WORD fReserved:1;
WORD FragmentOffset:13;
BYTE cbTtl;
BYTE cbNextProtocol;
WORD wChecksum;
DWORD dwSourceIP;
DWORD dwDestIP;
} IPHEADER, *PIPHEADER;
class CIPPacket
{
public:
CIPPacket();
virtual ~CIPPacket();
};
#endif //IPPACKET_H