summaryrefslogtreecommitdiff
path: root/storage/iscsi/src/config.mof
blob: 4f758f8035c5ca39be495d37c3a18f77737b108e (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
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
//***************************************************************************
//
//  config.mof
// 
//  Module: iScsi Discovery api
//
//  Purpose: Definitions for configuring HBA cards
//
//  Copyright (c) 2001 Microsoft Corporation
//
//***************************************************************************

#define MODULE_HEADER \
"\n" \
"//***************************************************************************\n" \
"//\n" \
"//  iscsicfg.h\n" \
"// \n" \
"//  Module: iScsi Discovery api\n" \
"//\n" \
"//  Purpose: Header defining interface between user mode configuration\n" \
"//           apps and HBA driver miniport.\n" \
"//\n" \
"//  Copyright (c) 2001 Microsoft Corporation\n" \
"//\n" \
"//***************************************************************************\n\n" 

//
// Do not cause headers to be generated from common.mof
//
#define GENERATE_HEADER FALSE

//
// Include common definitions
//
#include "common.mof"



//
// TCP/IP configuration class, implement one instance for each port on
// your adapter
//
[
 WMI,
 guid("{7A2C6C2B-E5A5-49ad-AD68-133089ACD74D}"),
 Dynamic,
 Provider("wmiprov"),
 DisplayName("TCP/IP configuration") : amended,
 cpp_quote(MODULE_HEADER
           "#include <iscsidef.h>\n\n"
"//\n"
"//\n"
"// This class is required.\n"
"//\n"         
"// TCP/IP configuration class, implement one instance for each IP address on\n"
"// your adapter. For example, if you adapter supports 3 IP addresses then\n"
"// your adapter would implement 3 instances of this class.\n"
"//\n"
"// This class uses PDO instance names with 1 instance for each TCP/IP interface.\n"
"//\n"
          )
]
class MSiSCSI_TCPIPConfig
{
    [key]
    string InstanceName;
    
    boolean Active;

    [read, write,
     WmiDataId(1),
     DisplayName("Use Link Local Address") : amended,
     description("TRUE if the adapter should use an autogenerated and non routable (link local) address as its IP address.") : amended
    ]
    boolean UseLinkLocalAddress;

    [read, write,
     WmiDataId(2),
     displayName("DHCP Enabled") : amended,
     description("TRUE if the adapter should use DHCP to discovery its IP address information.") : amended
    ]
    boolean EnableDHCP;

    [read, write,
     WmiDataId(3),
     displayName("Use DHCP for DNS") : amended,
     description("TRUE if the adapter should use DHCP to discover DNS addresses.") : amended
    ]
    boolean UseDHCPForDNS;

    [read,
     WmiDataId(4),
     description("IP Versions supported **Add #defines**") : amended,
     BitValues{ "IPV4", "IPV6"},
     BitMap{"0x00000001", "0x00000002"}
    ]
    uint32 IPVersions;
    
    [read, write,
     WmiDataId(5),
     DisplayName("IP Address") : amended,
     description("IP address of the adapter") : amended
    ]
    ISCSI_IP_Address IpAddress;

    [read, write,
     WmiDataId(6),
     DisplayName("Default Gateway") : amended,
     Description("Static Default Gateway IP address") : amended
    ]
    ISCSI_IP_Address DefaultGateway;

    [read, write,
     WmiDataId(7),
     DisplayName("Subnet Mask") : amended,
     Description("Static Subnet Mask") : amended
    ]
    ISCSI_IP_Address SubnetMask;    

    [read, write,
     WmiDataId(8),
     DisplayName("Preferred DNS Server") : amended,
     Description("Preferred DNS Server") : amended
    ]
    ISCSI_IP_Address PreferredDNSServer;    

    [read, write,
     WmiDataId(9),
     DisplayName("Alternate DNS Server") : amended,
     Description("Alternate DNS Server") : amended
    ]
    ISCSI_IP_Address AlternateDNSServer;    

};

//
// NIC Port configuration class, implement one instance for each port on
// your adapter
//
[
 WMI,
 guid("{C75258E9-BE79-4a48-A23D-EEB6F8FB940C}"),
 Dynamic,
 DisplayName("NIC Port Configuration") : amended,
 Provider("wmiprov"),
cpp_quote(
"//\n"
"// This class is optional.\n"
"//\n"
"// NIC Port configuration class, implement one instance for each physical \n"
"// network interface port on your adapter.\n"
"//\n"
"// This class uses PDO instance names with 1 instance for each physical\n"
"// network interface port on your adapter.\n"
"//\n"
"\n"
"typedef enum \n"
"{\n"
"    ISCSI_NIC_LINKSTATE_DISCONNECTED = 0,\n"
"    ISCSI_NIC_LINKSTATE_CONNECTED = 1\n"
"} ISCSI_NIC_LINKSTATE, *PISCSI_NIC_LINKSTATE;\n"
)
]
class MSiSCSI_NICConfig
{
    [key]
    string InstanceName;
    
    boolean Active;

    [read,
     WmiDataId(1),
     DisplayName("Link Speed") : amended,
     Description("Speed of network link in megabits per second.") : amended
    ]
    uint32 LinkSpeed;

    [read,
     WmiDataId(2),
     DisplayName("Max Link Speed") : amended,
     Description("Maximum Speed of network link in megabits per second.") : amended
    ]
    uint32 MaxLinkSpeed;

    [read,
     WmiDataId(3),
     DisplayName("Link State") : amended,
     description("Link State **typedef**") : amended,
     Values{"Media Disconnected", "Media Connected"} : amended,
     ValueMap{"0", "1"}
    ]
    uint32 LinkState;
    
    [read,
     WmiDataId(4),
     DisplayName("Max Frame Size") : amended,
     description("Maximum frame size") : amended
    ]
    uint32 MaxFrameSize;
    
    [read,
     WmiDataId(5),
     DisplayName("MAC Address") : amended,
     description("Ethernet MAC Address") : amended
    ]
    uint8 MacAddress[6];

};

[WMI,
 guid("{53EF8D5F-36F3-4124-8B76-C6AD521A1021}"),
 Dynamic, Provider("wmiprov"),
 DisplayName("Boot device configuration") : amended,
 cpp_quote(
"//\n"
"// This class is optional.\n"
"//\n"
"// This class exposes the boot configuration if the adapter is configured to\n"
"// boot from an iSCSI disk.\n"          
"//\n"
"// This class uses PDO instance names with a single instance.\n"
"//\n"
         )        
]
class MSiSCSI_BootConfiguration
{
    [key]
    string InstanceName;
    
    boolean Active;

    [read,
     write,
     WmiDataId(1),
     Description("LUN on target to use as boot device.") : amended,
     DisplayName("Target LUN") : amended
    ]
    uint64 LUN;

    [ read, write,
     WmiDataId(2),
     SECURITY_FLAG_QUALIFIERS
    ]
    ISCSI_SECURITY_FLAGS SecurityFlags;

    [ read, write,
     WmiDataId(3),
     description("Size in bytes of Target Username.") : amended
    ] uint32 UsernameSize;

    [ read, write,
      WmiDataId(4),
      description("Size in bytes of Target Password.") : amended
    ] uint32 PasswordSize;
                     
    [ read, write,
     WmiDataId(5),
     description("If TRUE dynamically discover boot device.") : amended
    ]
    boolean DiscoverBootDevice;
    
    [ read, write,
      WmiDataId(6),
     MaxLen(MAX_ISCSI_NAME_LEN),
     description("The InitiatorNode specifies the iSCSI name of the initiator node to use for the connection. If empty, then the adapter can choose any initiator node name.") : amended
    ] string InitiatorNode;

    [ read, write,
     WmiDataId(7),
     MaxLen(MAX_ISCSI_NAME_LEN),
     description("TargetName specifies the iSCSI target name on which the boot device resides.") : amended
    ] string TargetName;

    [ read, write,
      WmiDataId(8),
     description("Target portal to use for connection to the target.") : amended
    ] ISCSI_TargetPortal TargetPortal;

    [read, write,
     WmiDataId(9),
     description("Options that affect how login is performed. See ISCSI_LoginOptions") : amended
    ] ISCSI_LoginOptions LoginOptions;
    
    [ read, write,
     WmiDataId(10),
     WmiSizeIs("UsernameSize"),
     description("**extra fields** Authentication Username, for CHAP this is the CHAP Name (CHAP_N) use when authenticating with the target. NOTE: This field is a variable length array, the field that follows this field starts immediately after the end of this field subject to appropriate padding.") : amended
    ] uint8 Username[];
    
    [ read, write,
     WmiDataId(11),
     WmiSizeIs("PasswordSize"),
     description("Authentication Password, for CHAP this is the shared secret to use when generating the response to the target challange. This field is a variable length array.") : amended
    ] uint8 Password[]; 
};


//
// Types of encryption supported
//
#define ENCRYPTION_TYPES_QUALIFIERS \
     Values {"No Encryption/Authentication", \
             "3DES HMAC/SHA1", \
             "AES-CTR/CBC-MAC with XCBC"} : amended, \
     ValueMap{ "0", "1", "2" }


[
 WMI,
 guid("{225B9D64-47A9-41c8-81CD-69BC02652D87}"),
 Dynamic,
 Provider("wmiprov"),
 DisplayName("Security Capabilities") : amended,
 cpp_quote(
"//\n"
"// This class is required if adapter supports IPSEC.\n"
"//\n"
"// This class exposes the security capabilities if the adapter \n"
"// supports IPSEC.\n"
"//\n"
"// This class uses PDO instance names with a single instance.\n"
"//\n"
"typedef enum {\n"
"    ISCSI_ENCRYPT_NONE = 0,\n"
"    ISCSI_ENCRYPT_3DES_HMAC_SHA1 = 1,\n"
"    ISCSI_ENCRYPT_AES_CTR = 2              \n"
"} ISCSI_ENCRYPTION_TYPES, *PISCSI_ENCRYPTION_TYPES;\n\n"
          )
]
class MSiSCSI_SecurityCapabilities
{
    [key]
    string InstanceName;
    
    boolean Active;

    [read,
    DisplayName("Protect iSCSI") : amended,
     WmiDataId(1),
     description("TRUE if the adapter can use IPSEC to protect iSCSI traffic.") : amended
    ]
    boolean ProtectiScsiTraffic;

    
    [read,
     WmiDataId(2),
     DisplayName("Protect iSNS") : amended,
     description("TRUE if the adapter can use IPSEC to protect iSNS traffic.") : amended
    ]
    boolean ProtectiSNSTraffic;
    
    [read,
     WmiDataId(3),
     DisplayName("Certificates Supported") : amended,
     description("TRUE if adapter supports certificates") : amended
    ]
    boolean CertificatesSupported;
    
    [read,
     WmiDataId(4),
     DisplayName("Encryption Types Available") : amended,
     description("Number of encryption types available.")
    ]
    uint32 EncryptionAvailableCount;
    
    [ read,
     WmiDataId(5),
     WmiSizeIs("EncryptionAvailableCount"),
     ENCRYPTION_TYPES_QUALIFIERS,
     DisplayName("Encryption Types") : amended,
     description("**typedef** Array of encryption types. This field is a variable length array.")
    ]
    uint32 EncryptionAvailable[];    
};


[WMI,
 guid("{45755098-4291-43df-9720-B58642DD63DF}"),
 Dynamic,
 Provider("wmiprov"),
 DisplayName("Discovery Configuration") : amended,
 cpp_quote(
"//\n"
"// This class is required.\n"
"//\n"
"// This class exposes the configuration capabilities for the adapter to be able to\n"
"// perform target discovery. An adapter needs to support target discovery\n"
"// if it is ever placed on a separate network from the PC NIC. Although\n"
"// the iSCSI Initiator service can use this class with any discovery mechanism\n"
"// the best results are obtained by using iSNS.\n"
"//\n"
"// This class uses PDO instance names with a single instance.\n"
"//\n"
          )
]
class MSiSCSI_DiscoveryConfig
{
    [key]
    string InstanceName;
    
    boolean Active;

    [WmiDataId(1),
     read, write,
     description("TRUE if adapter should perform target discovery via iSNS.") : amended
    ] boolean PerformiSNSDiscovery;

    [WmiDataId(2),
     read, write,
     description("TRUE if adapter should perform target discovery via SLP.") : amended
    ] boolean PerformSLPDiscovery;

    [WmiDataId(3),
     read, write,
     description("TRUE if adapter should perform automatic discovery of iSNS server.") : amended
    ] boolean AutomaticiSNSDiscovery;
    
    [WmiDataId(4),
     read, write,
     MaxLen(256),
     description("Default initiator name for registering with iSNS.") : amended
    ] string InitiatorName;
    
    [WmiDataId(5),
     read, write,    
     description("If AutomaticiSNSDiscovery is FALSE then this contains the fixed addresses of iSNS servers") : amended
    ] ISCSI_IP_Address iSNSServer;
    
};

[WMI,
 guid("{8EAEF9D8-C053-49d3-9205-65C703C2ECC1}"),
 Dynamic,
 Provider("wmiprov"),
 DisplayName("Radius Configuration") : amended,
 cpp_quote(
"//\n"
"// This class is required if adapter supports using RADIUS for CHAP authentication.\n"
"//\n"
"// This class exposes the configuration capabilities if the adapter able to\n"
"// use radius to perform CHAP authentication. Using RADIUS is encouraged\n"
"// since it allows centralized management of CHAP credentials.\n"
"//\n"
"// This class uses PDO instance names with a single instance.\n"
"//\n"
          )
]
class MSiSCSI_RADIUSConfig
{
    [key]
    string InstanceName;
    
    boolean Active;

    [WmiDataId(1),
     read, write,
     description("TRUE if adapter should use RADIUS for CHAP authentication") : amended
    ] boolean UseRADIUSForCHAP;

    [WmiDataId(2),
     read, write,
     description("Size in bytes of shared secret used to communicate with RADIUS servers") : amended
    ] uint32 SharedSecretSizeInBytes;

    [WmiDataId(3),
     read, write,    
     description("Fixed address of primary RADIUS server") : amended
    ] ISCSI_IP_Address RADIUSServer;

    [WmiDataId(4),
     read, write,    
     description("Fixed address of backup RADIUS server") : amended
    ] ISCSI_IP_Address BackupRADIUSServer;

    [WmiDataId(5),
     Description("Must be zero")
    ]
    uint32 Reserved;
    
    [WmiDataId(6),
     read, write,
     WmiSizeIs("SharedSecretSizeInBytes"),
     description("Shared secret for communicating with primary and backup RADIUS servers. This field is a variable length array.") : amended
    ] uint8 SharedSecret[];

};