summaryrefslogtreecommitdiffstats
path: root/epan/dissectors/packet-fmp.h
blob: 3ec9aebb4df0ddfa2511f41812a867652c88d322 (plain)
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
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
/* packet-fmp.h
 * Defines for fmp dissection
 *
 * Wireshark - Network traffic analyzer
 * By Gerald Combs <gerald@wireshark.org>
 * Copyright 1998 Gerald Combs
 *
 *
 * SPDX-License-Identifier: GPL-2.0-or-later
 */

#ifndef PACKET_FMP_H
#define PACKET_FMP_H

#define FMP_PROGRAM	1001911
#define FMP_VERSION_3	 3



/*
 * FMP Procedures
 */
#define	FMP_SessionCreate	1
#define	FMP_HeartBeat		2
#define	FMP_Mount		3
#define	FMP_Open		4
#define	FMP_Close		5
#define	FMP_OpenGetMap		6
#define	FMP_OpenAllocSpace	7
#define	FMP_GetMap		8
#define	FMP_AllocSpace		9
#define	FMP_Flush		10
#define	FMP_CancelReq		11
#define	FMP_PlugIn		12
#define	FMP_SessionTerminate	13
#define	FMP_SessionCreateEx	14
#define FMP_ReportClientError   15
#define FMP_GetAttr		16
#define FMP_OpenGetAttr		17
#define FMP_FlushGetAttr 	18
#define FMP_OpenGetMapEx       	19
#define FMP_OpenAllocSpaceEx   	20
#define FMP_GetMapEx           	21
#define FMP_AllocSpaceEx       	22
#define FMP_FlushEx            	23
#define FMP_FlushGetAttrEx     	24
#define FMP_GetVolumeInfo      	25



/*
 * Volume Mgmt Capability
 */

#define	FMP_SERVER_BASED		0x01
#define	FMP_THIRD_PARTY			0x02
#define	FMP_CLIENT_BASED_DART		0x04
#define	FMP_CLIENT_BASED_SIMPLE		0x08
#define FMP_DISK_SIGNATURE		0x10
#define FMP_IPSTORAGE_BASED		0X20
#define FMP_HIERARCHICAL_VOLUME		0x40

/*
 * Flush Command Type
 */

#define FMP_COMMIT_SPECIFIED 0x01
#define FMP_RELEASE_SPECIFIED 0x02
#define FMP_RELEASE_ALL 0x04
#define FMP_CLOSE_FILE 0x08
#define FMP_UPDATE_TIME 0x10
#define FMP_ACCESS_TIME 0x20

#define FMP_PLUG_IN_ID_SZ 16

/*
 * FMP Notify Protocol
 */
#define FMP_TCP	0
#define FMP_UDP	1

/*
 * Capabilities
 */

#define FMP_CAP_REVOKE_HANDLE_LIST 0x0001
#define FMP_CAP_UNC_NAMES 0x0002
#define FMP_CAP_CIFSV2 0x0004


typedef enum  {
        FMP_CE_GENERIC = 1,
        FMP_CE_DISK_ERROR = 2
}clientErrorNum;


/*
 * FMP Reply Status
 */

typedef enum {
	FMP_OK = 0,
	FMP_IOERROR = 5,
	FMP_NOMEM = 12,
	FMP_NOACCESS = 13,
	FMP_INVALIDARG = 22,
	FMP_FSFULL = 28,
	FMP_QUEUE_FULL = 79,
	FMP_WRONG_MSG_NUM = 500,
	FMP_SESSION_LOST = 501,
	FMP_HOT_SESSION = 502,
	FMP_COLD_SESSION = 503,
	FMP_CLIENT_TERMINATED = 504,
	FMP_WRITER_LOST_BLK = 505,
	FMP_REQUEST_QUEUED = 506,
	FMP_FALL_BACK = 507,
	FMP_REQUEST_CANCELLED = 508,
	FMP_WRITER_ZEROED_BLK = 509,
	FMP_NOTIFY_ERROR = 510,
	FMP_WRONG_HANDLE = 511,
	FMP_DUPLICATE_OPEN = 512,
	FMP_PLUGIN_NOFUNC = 600
} fmpStat;


typedef enum {
	FMP_PATH = 0,
	FMP_NFS = 1,
	FMP_CIFS = 2,
	FMP_FMP = 3,
	FMP_FS_ONLY = 4,
	FMP_SHARE = 5,
	FMP_MOUNT = 6,
	FMP_CIFSV2  = 7,
	FMP_UNC     = 8
} nativeProtocol;


#define FMP_MAX_PATH_LEN	1024


/*
 * Encoding type for genString
 */

typedef enum {
	FMP_ASCII = 0,
	FMP_UTF8 = 1,
	FMP_UNICODE1 = 2
} encoding;

typedef enum  {
    FMP_DISK_IDENTIFIER_SIGNATURE = 0,
    FMP_DISK_IDENTIFIER_SERIAL = 1
} fmpDiskIdentifierType;

typedef enum  {
    FMP_VOLUME_DISK    = 0,
    FMP_VOLUME_SLICE   = 1,
    FMP_VOLUME_STRIPE  = 2,
    FMP_VOLUME_META    = 3
} fmpVolumeType;

/*
 * Extent States
 */
typedef enum {
       FMP_VALID_DATA = 0,
       FMP_INVALID_DATA = 1,
       FMP_NONE_DATA = 2
} extentState;


#define FMP_MAX_PATH_LEN       1024

/*
 * Query Command
 */
typedef enum {
        FMP_SCSI_INQUIRY = 0,
        FMP_DART_STAMP = 1
} queryCmd;


#define MAX_MSG_SIZE		256  /* For wireshark messages */

#endif