s4-srvsvc-idl: adapt some more formating changes from s3 idl.
[ira/wip.git] / source4 / librpc / idl / srvsvc.idl
1 #include "idl_types.h"
2
3 /*
4   srvsvc interface definitions
5 */
6 import "security.idl", "svcctl.idl";
7
8 [ uuid("4b324fc8-1670-01d3-1278-5a47bf6ee188"),
9   version(3.0),
10   endpoint("ncacn_np:[\\pipe\\srvsvc]", "ncacn_ip_tcp:", "ncalrpc:"),
11   pointer_default(unique),
12   helpstring("Server Service")
13 ] interface srvsvc
14 {
15         typedef bitmap svcctl_ServerType svcctl_ServerType;
16         typedef bitmap security_secinfo security_secinfo;
17
18 /**************************/
19 /* srvsvc_NetCharDev      */
20 /**************************/
21         typedef struct {
22                 [string,charset(UTF16)] uint16 *device;
23         } srvsvc_NetCharDevInfo0;
24
25         typedef struct {
26                 uint32 count;
27                 [size_is(count)] srvsvc_NetCharDevInfo0 *array;
28         } srvsvc_NetCharDevCtr0;
29
30         typedef struct {
31                 [string,charset(UTF16)] uint16 *device;
32                 uint32 status;
33                 [string,charset(UTF16)] uint16 *user;
34                 uint32 time;
35         } srvsvc_NetCharDevInfo1;
36
37         typedef struct {
38                 uint32 count;
39                 [size_is(count)] srvsvc_NetCharDevInfo1 *array;
40         } srvsvc_NetCharDevCtr1;
41
42         typedef union {
43                 [case(0)] srvsvc_NetCharDevInfo0 *info0;
44                 [case(1)] srvsvc_NetCharDevInfo1 *info1;
45                 [default] ;
46         } srvsvc_NetCharDevInfo;
47
48         typedef union {
49                 [case(0)] srvsvc_NetCharDevCtr0 *ctr0;
50                 [case(1)] srvsvc_NetCharDevCtr1 *ctr1;
51                 [default] ;
52         } srvsvc_NetCharDevCtr;
53
54         /******************/
55         /* Function: 0x00 */
56         WERROR srvsvc_NetCharDevEnum(
57                 [in,unique]   [string,charset(UTF16)] uint16 *server_unc,
58                 [in,out]   uint32 level,
59                 [in,out,switch_is(level)]   srvsvc_NetCharDevCtr ctr,
60                 [in]   uint32 max_buffer,
61                 [out]   uint32 totalentries,
62                 [in,out,unique]   uint32 *resume_handle
63                 );
64
65         /******************/
66         /* Function: 0x01 */
67         WERROR srvsvc_NetCharDevGetInfo(
68                 [in,unique] [string,charset(UTF16)] uint16 *server_unc,
69                 [in]   [string,charset(UTF16)] uint16 device_name[],
70                 [in]   uint32 level,
71                 [out,switch_is(level)]   srvsvc_NetCharDevInfo info
72                 );
73
74         /******************/
75         /* Function: 0x02 */
76         WERROR srvsvc_NetCharDevControl(
77                 [in,unique] [string,charset(UTF16)] uint16 *server_unc,
78                 [in]   [string,charset(UTF16)] uint16 device_name[],
79                 [in]   uint32 opcode
80                 );
81
82 /**************************/
83 /* srvsvc_NetCharDevQ     */
84 /**************************/
85         typedef struct {
86                 [string,charset(UTF16)] uint16 *device;
87         } srvsvc_NetCharDevQInfo0;
88
89         typedef struct {
90                 uint32 count;
91                 [size_is(count)] srvsvc_NetCharDevQInfo0 *array;
92         } srvsvc_NetCharDevQCtr0;
93
94         typedef struct {
95                 [string,charset(UTF16)] uint16 *device;
96                 uint32 priority;
97                 [string,charset(UTF16)] uint16 *devices;
98                 uint32 users;
99                 uint32 num_ahead;
100         } srvsvc_NetCharDevQInfo1;
101
102         typedef struct {
103                 uint32 count;
104                 [size_is(count)] srvsvc_NetCharDevQInfo1 *array;
105         } srvsvc_NetCharDevQCtr1;
106
107         typedef union {
108                 [case(0)] srvsvc_NetCharDevQInfo0 *info0;
109                 [case(1)] srvsvc_NetCharDevQInfo1 *info1;
110                 [default] ;
111         } srvsvc_NetCharDevQInfo;
112
113         typedef union {
114                 [case(0)] srvsvc_NetCharDevQCtr0 *ctr0;
115                 [case(1)] srvsvc_NetCharDevQCtr1 *ctr1;
116                 [default] ;
117         } srvsvc_NetCharDevQCtr;
118
119         /******************/
120         /* Function: 0x03 */
121         WERROR srvsvc_NetCharDevQEnum(
122                 [in,unique]   [string,charset(UTF16)] uint16 *server_unc,
123                 [in,unique]   [string,charset(UTF16)] uint16 *user,
124                 [in,out]   uint32 level,
125                 [in,out,switch_is(level)]   srvsvc_NetCharDevQCtr ctr,
126                 [in]   uint32 max_buffer,
127                 [out]   uint32 totalentries,
128                 [in,out,unique]   uint32 *resume_handle
129                 );
130
131         /******************/
132         /* Function: 0x04 */
133         WERROR srvsvc_NetCharDevQGetInfo(
134                 [in,unique] [string,charset(UTF16)] uint16 *server_unc,
135                 [in]   [string,charset(UTF16)] uint16 queue_name[],
136                 [in]   [string,charset(UTF16)] uint16 user[],
137                 [in]   uint32 level,
138                 [out,switch_is(level)]   srvsvc_NetCharDevQInfo info
139                 );
140
141         /******************/
142         /* Function: 0x05 */
143         WERROR srvsvc_NetCharDevQSetInfo(
144                 [in,unique]   [string,charset(UTF16)] uint16 *server_unc,
145                 [in]   [string,charset(UTF16)] uint16 queue_name[],
146                 [in]   uint32 level,
147                 [in,switch_is(level)]   srvsvc_NetCharDevQInfo info,
148                 [in,out,unique]   uint32 *parm_error
149                 );
150
151         /******************/
152         /* Function: 0x06 */
153         WERROR srvsvc_NetCharDevQPurge(
154                 [in,unique] [string,charset(UTF16)] uint16 *server_unc,
155                 [in]   [string,charset(UTF16)] uint16 queue_name[]
156                 );
157
158         /******************/
159         /* Function: 0x07 */
160         WERROR srvsvc_NetCharDevQPurgeSelf(
161                 [in,unique] [string,charset(UTF16)] uint16 *server_unc,
162                 [in]   [string,charset(UTF16)] uint16 queue_name[],
163                 [in]   [string,charset(UTF16)] uint16 computer_name[]
164                 );
165
166 /**************************/
167 /* srvsvc_NetConn         */
168 /**************************/
169         typedef struct {
170                 uint32 conn_id;
171         } srvsvc_NetConnInfo0;
172
173         typedef struct {
174                 uint32 count;
175                 [size_is(count)] srvsvc_NetConnInfo0 *array;
176         } srvsvc_NetConnCtr0;
177
178         typedef struct {
179                 uint32 conn_id;
180                 uint32 conn_type;
181                 uint32 num_open;
182                 uint32 num_users;
183                 uint32 conn_time;
184                 [string,charset(UTF16)] uint16 *user;
185                 [string,charset(UTF16)] uint16 *share;
186         } srvsvc_NetConnInfo1;
187
188         typedef struct {
189                 uint32 count;
190                 [size_is(count)] srvsvc_NetConnInfo1 *array;
191         } srvsvc_NetConnCtr1;
192
193         typedef union {
194                 [case(0)] srvsvc_NetConnCtr0 *ctr0;
195                 [case(1)] srvsvc_NetConnCtr1 *ctr1;
196                 [default] ;
197         } srvsvc_NetConnCtr;
198
199         typedef struct {
200                 uint32 level;
201                 [switch_is(level)] srvsvc_NetConnCtr ctr;
202         } srvsvc_NetConnInfoCtr;
203
204         /******************/
205         /* Function: 0x08 */
206         WERROR srvsvc_NetConnEnum(
207                 [in,unique]   [string,charset(UTF16)] uint16 *server_unc,
208                 [in,unique]   [string,charset(UTF16)] uint16 *path,
209                 [in,out]   uint32 level,
210                 [in,out,switch_is(level)]   srvsvc_NetConnCtr ctr,
211                 [in]   uint32 max_buffer,
212                 [out]   uint32 totalentries,
213                 [in,out,unique]   uint32 *resume_handle
214                 );
215
216 /**************************/
217 /* srvsvc_NetFile         */
218 /**************************/
219         typedef struct {
220                 uint32 fid;
221         } srvsvc_NetFileInfo2;
222
223         typedef struct {
224                 uint32 count;
225                 [size_is(count)] srvsvc_NetFileInfo2 *array;
226         } srvsvc_NetFileCtr2;
227
228         typedef struct {
229                 uint32 fid;
230                 uint32 permissions;
231                 uint32 num_locks;
232                 [string,charset(UTF16)] uint16 *path;
233                 [string,charset(UTF16)] uint16 *user;
234         } srvsvc_NetFileInfo3;
235
236         typedef struct {
237                 uint32 count;
238                 [size_is(count)] srvsvc_NetFileInfo3 *array;
239         } srvsvc_NetFileCtr3;
240
241         typedef union {
242                 [case(2)] srvsvc_NetFileInfo2 *info2;
243                 [case(3)] srvsvc_NetFileInfo3 *info3;
244                 [default] ;
245         } srvsvc_NetFileInfo;
246
247         typedef union {
248                 [case(2)] srvsvc_NetFileCtr2 *ctr2;
249                 [case(3)] srvsvc_NetFileCtr3 *ctr3;
250                 [default] ;
251         } srvsvc_NetFileCtr;
252
253         typedef struct {
254                 uint32 level;
255                 [switch_is(level)] srvsvc_NetFileCtr ctr;
256         } srvsvc_NetFileInfoCtr;
257
258         /******************/
259         /* Function: 0x09 */
260         WERROR srvsvc_NetFileEnum(
261                 [in,unique]   [string,charset(UTF16)] uint16 *server_unc,
262                 [in,unique]   [string,charset(UTF16)] uint16 *path,
263                 [in,unique]   [string,charset(UTF16)] uint16 *user,
264                 [in,out]   uint32 level,
265                 [in,out,switch_is(level)]   srvsvc_NetFileCtr ctr,
266                 [in]   uint32 max_buffer,
267                 [out]   uint32 totalentries,
268                 [in,out,unique]   uint32 *resume_handle
269                 );
270
271         /******************/
272         /* Function: 0x0a */
273         WERROR srvsvc_NetFileGetInfo(
274                 [in,unique]   [string,charset(UTF16)] uint16 *server_unc,
275                 [in]   uint32 fid,
276                 [in]   uint32 level,
277                 [out,switch_is(level)]   srvsvc_NetFileInfo info
278                 );
279
280         /******************/
281         /* Function: 0x0b */
282         WERROR srvsvc_NetFileClose(
283                 [in,unique]   [string,charset(UTF16)] uint16 *server_unc,
284                 [in]   uint32 fid       
285                 );
286
287 /**************************/
288 /* srvsvc_NetSess         */
289 /**************************/
290         typedef struct {
291                 [string,charset(UTF16)] uint16 *client;
292         } srvsvc_NetSessInfo0;
293
294         typedef struct {
295                 uint32 count;
296                 [size_is(count)] srvsvc_NetSessInfo0 *array;
297         } srvsvc_NetSessCtr0;
298
299         typedef struct {
300                 [string,charset(UTF16)] uint16 *client;
301                 [string,charset(UTF16)] uint16 *user;
302                 uint32 num_open;
303                 uint32 time;
304                 uint32 idle_time;
305                 uint32 user_flags;
306         } srvsvc_NetSessInfo1;
307
308         typedef struct {
309                 uint32 count;
310                 [size_is(count)] srvsvc_NetSessInfo1 *array;
311         } srvsvc_NetSessCtr1;
312
313         typedef struct {
314                 [string,charset(UTF16)] uint16 *client;
315                 [string,charset(UTF16)] uint16 *user;
316                 uint32 num_open;
317                 uint32 time;
318                 uint32 idle_time;
319                 uint32 user_flags;
320                 [string,charset(UTF16)] uint16 *client_type;
321         } srvsvc_NetSessInfo2;
322
323         typedef struct {
324                 uint32 count;
325                 [size_is(count)] srvsvc_NetSessInfo2 *array;
326         } srvsvc_NetSessCtr2;
327
328         typedef struct {
329                 [string,charset(UTF16)] uint16 *client;
330                 [string,charset(UTF16)] uint16 *user;
331                 uint32 time;
332                 uint32 idle_time;
333         } srvsvc_NetSessInfo10;
334
335         typedef struct {
336                 uint32 count;
337                 [size_is(count)] srvsvc_NetSessInfo10 *array;
338         } srvsvc_NetSessCtr10;
339
340         typedef struct {
341                 [string,charset(UTF16)] uint16 *client;
342                 [string,charset(UTF16)] uint16 *user;
343                 uint32 num_open;
344                 uint32 time;
345                 uint32 idle_time;
346                 uint32 user_flags;
347                 [string,charset(UTF16)] uint16 *client_type;
348                 [string,charset(UTF16)] uint16 *transport;
349         } srvsvc_NetSessInfo502;
350
351         typedef struct {
352                 uint32 count;
353                 [size_is(count)] srvsvc_NetSessInfo502 *array;
354         } srvsvc_NetSessCtr502;
355
356         typedef union {
357                 [case(0)] srvsvc_NetSessCtr0 *ctr0;
358                 [case(1)] srvsvc_NetSessCtr1 *ctr1;
359                 [case(2)] srvsvc_NetSessCtr2 *ctr2;
360                 [case(10)] srvsvc_NetSessCtr10 *ctr10;
361                 [case(502)] srvsvc_NetSessCtr502 *ctr502;
362                 [default] ;
363         } srvsvc_NetSessCtr;
364
365         /******************/
366         /* Function: 0x0c */
367
368         typedef struct {
369                 uint32 level;
370                 [switch_is(level)] srvsvc_NetSessCtr ctr;
371         } srvsvc_NetSessInfoCtr;
372
373         WERROR srvsvc_NetSessEnum(
374                 [in,unique]   [string,charset(UTF16)] uint16 *server_unc,
375                 [in,unique]   [string,charset(UTF16)] uint16 *client,
376                 [in,unique]   [string,charset(UTF16)] uint16 *user,
377                 [in,out]   uint32 level,
378                 [in,out,switch_is(level)]   srvsvc_NetSessCtr ctr,
379                 [in]   uint32 max_buffer,
380                 [out]   uint32 totalentries,
381                 [in,out,unique]   uint32 *resume_handle
382                 );
383
384         /******************/
385         /* Function: 0x0d */
386         WERROR srvsvc_NetSessDel(
387                 [in,unique]   [string,charset(UTF16)] uint16 *server_unc,
388                 [in,unique]   [string,charset(UTF16)] uint16 *client,
389                 [in,unique]   [string,charset(UTF16)] uint16 *user
390                 );
391
392 /**************************/
393 /* srvsvc_NetShare        */
394 /**************************/
395
396         /* share types */
397         const uint32 STYPE_TEMPORARY = 0x40000000; /* share is a temporary one */
398         const uint32 STYPE_HIDDEN    = 0x80000000; /* share is a hidden one */
399
400         typedef [v1_enum, flag(NDR_PAHEX)] enum {
401                 STYPE_DISKTREE = 0,
402                 STYPE_DISKTREE_TEMPORARY = STYPE_DISKTREE|STYPE_TEMPORARY,
403                 STYPE_DISKTREE_HIDDEN    = STYPE_DISKTREE|STYPE_HIDDEN,
404                 STYPE_PRINTQ   = 1,
405                 STYPE_PRINTQ_TEMPORARY = STYPE_PRINTQ|STYPE_TEMPORARY,
406                 STYPE_PRINTQ_HIDDEN    = STYPE_PRINTQ|STYPE_HIDDEN,
407                 STYPE_DEVICE   = 2,     /* Serial device */
408                 STYPE_DEVICE_TEMPORARY = STYPE_DEVICE|STYPE_TEMPORARY,
409                 STYPE_DEVICE_HIDDEN    = STYPE_DEVICE|STYPE_HIDDEN,
410                 STYPE_IPC      = 3,     /* Interprocess communication (IPC) */
411                 STYPE_IPC_TEMPORARY = STYPE_IPC|STYPE_TEMPORARY,
412                 STYPE_IPC_HIDDEN    = STYPE_IPC|STYPE_HIDDEN
413         } srvsvc_ShareType;
414
415         typedef struct {
416                 [string,charset(UTF16)] uint16 *name;
417         } srvsvc_NetShareInfo0;
418
419         typedef struct {
420                 uint32 count;
421                 [size_is(count)] srvsvc_NetShareInfo0 *array;
422         } srvsvc_NetShareCtr0;
423
424         typedef struct {
425                 [string,charset(UTF16)] uint16 *name;
426                 srvsvc_ShareType type;
427                 [string,charset(UTF16)] uint16 *comment;
428         } srvsvc_NetShareInfo1;
429
430         typedef struct {
431                 uint32 count;
432                 [size_is(count)] srvsvc_NetShareInfo1 *array;
433         } srvsvc_NetShareCtr1;
434
435         typedef struct {
436                 [string,charset(UTF16)] uint16 *name;
437                 srvsvc_ShareType type;
438                 [string,charset(UTF16)] uint16 *comment;
439                 uint32 permissions;
440                 uint32 max_users;
441                 uint32 current_users;
442                 [string,charset(UTF16)] uint16 *path;
443                 [string,charset(UTF16)] uint16 *password;
444         } srvsvc_NetShareInfo2;
445
446         typedef struct {
447                 uint32 count;
448                 [size_is(count)] srvsvc_NetShareInfo2 *array;
449         } srvsvc_NetShareCtr2;
450
451         typedef struct {
452                 [string,charset(UTF16)] uint16 *name;
453                 srvsvc_ShareType type;
454                 [string,charset(UTF16)] uint16 *comment;
455                 uint32 csc_policy;
456         } srvsvc_NetShareInfo501;
457
458         typedef struct {
459                 uint32 count;
460                 [size_is(count)] srvsvc_NetShareInfo501 *array;
461         } srvsvc_NetShareCtr501;
462
463         typedef struct {
464                 [string,charset(UTF16)] uint16 *name;
465                 srvsvc_ShareType type;
466                 [string,charset(UTF16)] uint16 *comment;
467                 uint32 permissions;
468                 int32 max_users;
469                 uint32 current_users;
470                 [string,charset(UTF16)] uint16 *path;
471                 [string,charset(UTF16)] uint16 *password;
472                 /* maybe here is a struct sec_desc_buf following */
473                 uint32 unknown;
474                 [subcontext(4)] security_descriptor *sd;
475         } srvsvc_NetShareInfo502;
476
477         typedef struct {
478                 uint32 count;
479                 [size_is(count)] srvsvc_NetShareInfo502 *array;
480         } srvsvc_NetShareCtr502;
481
482         typedef struct {
483                 [string,charset(UTF16)] uint16 *comment;
484         } srvsvc_NetShareInfo1004;
485
486         typedef struct {
487                 uint32 count;
488                 [size_is(count)] srvsvc_NetShareInfo1004 *array;
489         } srvsvc_NetShareCtr1004;
490
491         typedef bitmap {
492                 SHARE_1005_IN_DFS               = 0x00000001,
493                 SHARE_1005_DFS_ROOT             = 0x00000002
494         } NetShareInfo1005Flags;
495         
496         const uint32 SHARE_1005_CSC_POLICY_MASK = 0x00000030;
497         const uint32 SHARE_1005_CSC_POLICY_SHIFT = 4;
498
499         typedef struct {
500                 NetShareInfo1005Flags dfs_flags;
501         } srvsvc_NetShareInfo1005;
502
503         typedef struct {
504                 uint32 count;
505                 [size_is(count)] srvsvc_NetShareInfo1005 *array;
506         } srvsvc_NetShareCtr1005;
507
508         typedef struct {
509                 int32 max_users;
510         } srvsvc_NetShareInfo1006;
511
512         typedef struct {
513                 uint32 count;
514                 [size_is(count)] srvsvc_NetShareInfo1006 *array;
515         } srvsvc_NetShareCtr1006;
516
517         typedef struct {
518                 uint32 flags;
519                 [string,charset(UTF16)] uint16 *alternate_directory_name;
520         } srvsvc_NetShareInfo1007;
521
522         typedef struct {
523                 uint32 count;
524                 [size_is(count)] srvsvc_NetShareInfo1007 *array;
525         } srvsvc_NetShareCtr1007;
526
527         typedef struct {
528                 uint32 count;
529                 [size_is(count)] sec_desc_buf *array;
530         } srvsvc_NetShareCtr1501;
531
532         typedef union {
533                 [case(0)] srvsvc_NetShareInfo0 *info0;
534                 [case(1)] srvsvc_NetShareInfo1 *info1;
535                 [case(2)] srvsvc_NetShareInfo2 *info2;
536                 [case(501)] srvsvc_NetShareInfo501 *info501;
537                 [case(502)] srvsvc_NetShareInfo502 *info502;
538                 [case(1004)] srvsvc_NetShareInfo1004 *info1004;
539                 [case(1005)] srvsvc_NetShareInfo1005 *info1005;
540                 [case(1006)] srvsvc_NetShareInfo1006 *info1006;
541                 [case(1007)] srvsvc_NetShareInfo1007 *info1007;
542                 [case(1501)] sec_desc_buf *info1501;
543                 [default] ;
544         } srvsvc_NetShareInfo;
545
546         typedef union {
547                 [case(0)] srvsvc_NetShareCtr0 *ctr0;
548                 [case(1)] srvsvc_NetShareCtr1 *ctr1;
549                 [case(2)] srvsvc_NetShareCtr2 *ctr2;
550                 [case(501)] srvsvc_NetShareCtr501 *ctr501;
551                 [case(502)] srvsvc_NetShareCtr502 *ctr502;
552                 [case(1004)] srvsvc_NetShareCtr1004 *ctr1004;
553                 [case(1005)] srvsvc_NetShareCtr1005 *ctr1005;
554                 [case(1006)] srvsvc_NetShareCtr1006 *ctr1006;
555                 [case(1007)] srvsvc_NetShareCtr1007 *ctr1007;
556                 [case(1501)] srvsvc_NetShareCtr1501 *ctr1501;
557                 [default] ;
558         } srvsvc_NetShareCtr;
559
560         typedef struct {
561                 uint32 level;
562                 [switch_is(level)] srvsvc_NetShareCtr ctr;
563         } srvsvc_NetShareInfoCtr;
564
565         /******************/
566         /* Function: 0x0e */
567         WERROR srvsvc_NetShareAdd(
568                 [in,unique]   [string,charset(UTF16)] uint16 *server_unc,
569                 [in]   uint32 level,
570                 [in,switch_is(level)] srvsvc_NetShareInfo info,
571                 [in,out,unique]   uint32 *parm_error
572                 );
573
574         /******************/
575         /* Function: 0x0f */
576         WERROR srvsvc_NetShareEnumAll (
577                 [in,unique]   [string,charset(UTF16)] uint16 *server_unc,
578                 [in,out]   uint32 level,
579                 [in,out,switch_is(level)] srvsvc_NetShareCtr ctr,
580                 [in]   uint32 max_buffer,
581                 [out]  uint32 totalentries,
582                 [in,out,unique]   uint32 *resume_handle
583                 );
584
585         /******************/
586         /* Function: 0x10 */
587         WERROR srvsvc_NetShareGetInfo(
588                 [in,unique]   [string,charset(UTF16)] uint16 *server_unc,
589                 [in]   [string,charset(UTF16)] uint16 share_name[],
590                 [in]   uint32 level,
591                 [out,switch_is(level)] srvsvc_NetShareInfo info
592                 );
593
594         /******************/
595         /* Function: 0x11 */
596         WERROR srvsvc_NetShareSetInfo(
597                 [in,unique]   [string,charset(UTF16)] uint16 *server_unc,
598                 [in]   [string,charset(UTF16)] uint16 share_name[],
599                 [in]   uint32 level,
600                 [in,switch_is(level)] srvsvc_NetShareInfo info,
601                 [in,out,unique]   uint32 *parm_error
602                 );
603
604         /******************/
605         /* Function: 0x12 */
606         WERROR srvsvc_NetShareDel(
607                 [in,unique]   [string,charset(UTF16)] uint16 *server_unc,
608                 [in]   [string,charset(UTF16)] uint16 share_name[],
609                 [in]   uint32 reserved
610                 );
611
612         /******************/
613         /* Function: 0x13 */
614         WERROR srvsvc_NetShareDelSticky(
615                 [in,unique]   [string,charset(UTF16)] uint16 *server_unc,
616                 [in]   [string,charset(UTF16)] uint16 share_name[],
617                 [in]   uint32 reserved
618                 );
619         
620         /******************/
621         /* Function: 0x14 */
622         WERROR srvsvc_NetShareCheck(
623                 [in,unique]   [string,charset(UTF16)] uint16 *server_unc,
624                 [in]   [string,charset(UTF16)] uint16 device_name[],
625                 [out]  srvsvc_ShareType type
626                 );
627
628 /**************************/
629 /* srvsvc_NetSrv          */
630 /**************************/
631         typedef [public,v1_enum] enum {
632                 PLATFORM_ID_DOS = 300,
633                 PLATFORM_ID_OS2 = 400,
634                 PLATFORM_ID_NT  = 500,
635                 PLATFORM_ID_OSF = 600,
636                 PLATFORM_ID_VMS = 700
637         } srvsvc_PlatformId;
638
639         typedef struct {
640                 srvsvc_PlatformId platform_id;
641                 [string,charset(UTF16)] uint16 *server_name;
642         } srvsvc_NetSrvInfo100;
643
644         typedef struct {
645                 srvsvc_PlatformId platform_id;
646                 [string,charset(UTF16)] uint16 *server_name;
647                 uint32 version_major;
648                 uint32 version_minor;
649                 svcctl_ServerType server_type;
650                 [string,charset(UTF16)] uint16 *comment;
651         } srvsvc_NetSrvInfo101;
652
653         typedef struct {
654                 srvsvc_PlatformId platform_id;
655                 [string,charset(UTF16)] uint16 *server_name;
656                 uint32 version_major;
657                 uint32 version_minor;
658                 svcctl_ServerType server_type;
659                 [string,charset(UTF16)] uint16 *comment;
660                 uint32 users;
661                 uint32 disc;
662                 uint32 hidden;
663                 uint32 announce;
664                 uint32 anndelta;
665                 uint32 licenses;
666                 [string,charset(UTF16)] uint16 *userpath;
667         } srvsvc_NetSrvInfo102;
668
669         typedef struct {
670                 uint32 ulist_mtime;
671                 uint32 glist_mtime;
672                 uint32 alist_mtime;
673                 [string,charset(UTF16)] uint16 *alerts;
674                 uint32 security;
675                 uint32 numadmin;
676                 uint32 lanmask;
677                 [string,charset(UTF16)] uint16 *guestaccount;
678                 uint32 chdevs;
679                 uint32 chdevqs;
680                 uint32 chdevjobs;
681                 uint32 connections;
682                 uint32 shares;
683                 uint32 openfiles;
684                 uint32 sessopen;
685                 uint32 sesssvc;
686                 uint32 sessreqs;
687                 uint32 opensearch;
688                 uint32 activelocks;
689                 uint32 sizereqbufs;
690                 uint32 numbigbufs;
691                 uint32 numfiletasks;
692                 uint32 alertsched;
693                 uint32 erroralert;
694                 uint32 logonalert;
695                 uint32 accessalert;
696                 uint32 diskalert;
697                 uint32 netioalert;
698                 uint32 maxaudits;
699                 [string,charset(UTF16)] uint16 *srvheuristics;
700         } srvsvc_NetSrvInfo402;
701
702         typedef struct {
703                 uint32 ulist_mtime;
704                 uint32 glist_mtime;
705                 uint32 alist_mtime;
706                 [string,charset(UTF16)] uint16 *alerts;
707                 uint32 security;
708                 uint32 numadmin;
709                 uint32 lanmask;
710                 [string,charset(UTF16)] uint16 *guestaccount;
711                 uint32 chdevs;
712                 uint32 chdevqs;
713                 uint32 chdevjobs;
714                 uint32 connections;
715                 uint32 shares;
716                 uint32 openfiles;
717                 uint32 sessopen;
718                 uint32 sesssvc;
719                 uint32 sessreqs;
720                 uint32 opensearch;
721                 uint32 activelocks;
722                 uint32 sizereqbufs;
723                 uint32 numbigbufs;
724                 uint32 numfiletasks;
725                 uint32 alertsched;
726                 uint32 eroralert;
727                 uint32 logonalert;
728                 uint32 accessalert;
729                 uint32 diskalert;
730                 uint32 netioalert;
731                 uint32 maxaudits;
732                 [string,charset(UTF16)] uint16 *srvheuristics;
733                 uint32 auditedevents;
734                 uint32 auditprofile;
735                 [string,charset(UTF16)] uint16 *autopath;
736         } srvsvc_NetSrvInfo403;
737
738         typedef struct {
739                 uint32 sessopen;
740                 uint32 sesssvc;
741                 uint32 opensearch;
742                 uint32 sizereqbufs;
743                 uint32 initworkitems;
744                 uint32 maxworkitems;
745                 uint32 rawworkitems;
746                 uint32 irpstacksize;
747                 uint32 maxrawbuflen;
748                 uint32 sessusers;
749                 uint32 sessconns;
750                 uint32 maxpagedmemoryusage;
751                 uint32 maxnonpagedmemoryusage;
752                 uint32 enablesoftcompat;
753                 uint32 enableforcedlogoff;
754                 uint32 timesource;
755                 uint32 acceptdownlevelapis;
756                 uint32 lmannounce;
757         } srvsvc_NetSrvInfo502;
758
759         typedef struct{
760                 uint32 sessopen;
761                 uint32 sesssvc;
762                 uint32 opensearch;
763                 uint32 sizereqbufs;
764                 uint32 initworkitems;
765                 uint32 maxworkitems;
766                 uint32 rawworkitems;
767                 uint32 irpstacksize;
768                 uint32 maxrawbuflen;
769                 uint32 sessusers;
770                 uint32 sessconns;
771                 uint32 maxpagedmemoryusage;
772                 uint32 maxnonpagedmemoryusage;
773                 uint32 enablesoftcompat;
774                 uint32 enableforcedlogoff;
775                 uint32 timesource;
776                 uint32 acceptdownlevelapis;
777                 uint32 lmannounce;
778                 [string,charset(UTF16)] uint16 *domain;
779                 uint32 maxcopyreadlen;
780                 uint32 maxcopywritelen;
781                 uint32 minkeepsearch;
782                 uint32 maxkeepsearch;
783                 uint32 minkeepcomplsearch;
784                 uint32 maxkeepcomplsearch;
785                 uint32 threadcountadd;
786                 uint32 numlockthreads;
787                 uint32 scavtimeout;
788                 uint32 minrcvqueue;
789                 uint32 minfreeworkitems;
790                 uint32 xactmemsize;
791                 uint32 threadpriority;
792                 uint32 maxmpxct;
793                 uint32 oplockbreakwait;
794                 uint32 oplockbreakresponsewait;
795                 uint32 enableoplocks;
796                 uint32 enableoplockforceclose;
797                 uint32 enablefcbopens;
798                 uint32 enableraw;
799                 uint32 enablesharednetdrives;
800                 uint32 minfreeconnections;
801                 uint32 maxfreeconnections;
802         } srvsvc_NetSrvInfo503;
803
804         typedef struct{
805                 uint32 sessopen;
806                 uint32 sesssvc;
807                 uint32 opensearch;
808                 uint32 sizereqbufs;
809                 uint32 initworkitems;
810                 uint32 maxworkitems;
811                 uint32 rawworkitems;
812                 uint32 irpstacksize;
813                 uint32 maxrawbuflen;
814                 uint32 sessusers;
815                 uint32 sessconns;
816                 uint32 maxpagedmemoryusage;
817                 uint32 maxnonpagedmemoryusage;
818                 uint32 enablesoftcompat;
819                 uint32 enableforcedlogoff;
820                 uint32 timesource;
821                 uint32 acceptdownlevelapis;
822                 uint32 lmannounce;
823                 [string,charset(UTF16)] uint16 *domain;
824                 uint32 maxcopyreadlen;
825                 uint32 maxcopywritelen;
826                 uint32 minkeepsearch;
827                 uint32 minkeepcomplsearch;
828                 uint32 maxkeepcomplsearch;
829                 uint32 threadcountadd;
830                 uint32 numlockthreads;
831                 uint32 scavtimeout;
832                 uint32 minrcvqueue;
833                 uint32 minfreeworkitems;
834                 uint32 xactmemsize;
835                 uint32 threadpriority;
836                 uint32 maxmpxct;
837                 uint32 oplockbreakwait;
838                 uint32 oplockbreakresponsewait;
839                 uint32 enableoplocks;
840                 uint32 enableoplockforceclose;
841                 uint32 enablefcbopens;
842                 uint32 enableraw;
843                 uint32 enablesharednetdrives;
844                 uint32 minfreeconnections;
845                 uint32 maxfreeconnections;
846                 uint32 initsesstable;
847                 uint32 initconntable;
848                 uint32 initfiletable;
849                 uint32 initsearchtable;
850                 uint32 alertsched;
851                 uint32 errortreshold;
852                 uint32 networkerrortreshold;
853                 uint32 diskspacetreshold;
854                 uint32 reserved;
855                 uint32 maxlinkdelay;
856                 uint32 minlinkthroughput;
857                 uint32 linkinfovalidtime;
858                 uint32 scavqosinfoupdatetime;
859                 uint32 maxworkitemidletime;
860         } srvsvc_NetSrvInfo599;
861
862         typedef struct{
863                 [string,charset(UTF16)] uint16 *comment;
864         } srvsvc_NetSrvInfo1005;
865
866         typedef struct{
867                 uint32 disc;
868         } srvsvc_NetSrvInfo1010;
869
870         typedef struct{
871                 uint32 hidden;
872         } srvsvc_NetSrvInfo1016;
873
874         typedef struct{
875                 uint32 announce;
876         } srvsvc_NetSrvInfo1017;
877
878         typedef struct{
879                 uint32 anndelta;
880         } srvsvc_NetSrvInfo1018;
881
882         typedef struct{
883                 uint32 users;
884         } srvsvc_NetSrvInfo1107;
885
886         typedef struct{
887                 uint32 sessopens;
888         } srvsvc_NetSrvInfo1501;
889
890         typedef struct{
891                 uint32 sessvcs;
892         } srvsvc_NetSrvInfo1502;
893
894         typedef struct{
895                 uint32 opensearch;
896         } srvsvc_NetSrvInfo1503;
897
898         typedef struct{
899                 uint32 maxworkitems;
900         } srvsvc_NetSrvInfo1506;
901
902         typedef struct{
903                 uint32 maxrawbuflen;
904         } srvsvc_NetSrvInfo1509;
905
906         typedef struct{
907                 uint32 sessusers;
908         } srvsvc_NetSrvInfo1510;
909
910         typedef struct{
911                 uint32 sesscons;
912         } srvsvc_NetSrvInfo1511;
913
914         typedef struct{
915                 uint32 maxnonpagedmemoryusage;
916         } srvsvc_NetSrvInfo1512;
917
918         typedef struct{
919                 uint32 maxpagedmemoryusage;
920         } srvsvc_NetSrvInfo1513;
921
922         typedef struct{
923                 uint32 enablesoftcompat;
924         } srvsvc_NetSrvInfo1514;
925
926         typedef struct{
927                 uint32 enableforcedlogoff;
928         } srvsvc_NetSrvInfo1515;
929
930         typedef struct{
931                 uint32 timesource;
932         } srvsvc_NetSrvInfo1516;
933
934         typedef struct{
935                 uint32 lmannounce;
936         } srvsvc_NetSrvInfo1518;
937
938         typedef struct{
939                 uint32 maxcopyreadlen;
940         } srvsvc_NetSrvInfo1520;
941
942         typedef struct{
943                 uint32 maxcopywritelen;
944         } srvsvc_NetSrvInfo1521;
945
946         typedef struct{
947                 uint32 minkeepsearch;
948         } srvsvc_NetSrvInfo1522;
949
950         typedef struct{
951                 uint32 maxkeepsearch;
952         } srvsvc_NetSrvInfo1523;
953
954         typedef struct{
955                 uint32 minkeepcomplsearch;
956         } srvsvc_NetSrvInfo1524;
957
958         typedef struct{
959                 uint32 maxkeepcomplsearch;
960         } srvsvc_NetSrvInfo1525;
961
962         typedef struct{
963                 uint32 scavtimeout;
964         } srvsvc_NetSrvInfo1528;
965
966         typedef struct{
967                 uint32 minrcvqueue;
968         } srvsvc_NetSrvInfo1529;
969
970         typedef struct{
971                 uint32 minfreeworkitems;
972         } srvsvc_NetSrvInfo1530;
973
974         typedef struct{
975                 uint32 maxmpxct;
976         } srvsvc_NetSrvInfo1533;
977
978         typedef struct{
979                 uint32 oplockbreakwait;
980         } srvsvc_NetSrvInfo1534;
981
982         typedef struct{
983                 uint32 oplockbreakresponsewait;
984         } srvsvc_NetSrvInfo1535;
985
986         typedef struct{
987                 uint32 enableoplocks;
988         } srvsvc_NetSrvInfo1536;
989
990         typedef struct{
991                 uint32 enableoplockforceclose;
992         } srvsvc_NetSrvInfo1537;
993
994         typedef struct{
995                 uint32 enablefcbopens;
996         } srvsvc_NetSrvInfo1538;
997
998         typedef struct{
999                 uint32 enableraw;
1000         } srvsvc_NetSrvInfo1539;
1001
1002         typedef struct{
1003                 uint32 enablesharednetdrives;
1004         } srvsvc_NetSrvInfo1540;
1005
1006         typedef struct{
1007                 uint32 minfreeconnections;
1008         } srvsvc_NetSrvInfo1541;
1009
1010         typedef struct{
1011                 uint32 maxfreeconnections;
1012         } srvsvc_NetSrvInfo1542;
1013
1014         typedef struct{
1015                 uint32 initsesstable;
1016         } srvsvc_NetSrvInfo1543;
1017
1018         typedef struct{
1019                 uint32 initconntable;
1020         } srvsvc_NetSrvInfo1544;
1021
1022         typedef struct{
1023                 uint32 initfiletable;
1024         } srvsvc_NetSrvInfo1545;
1025
1026         typedef struct{
1027                 uint32 initsearchtable;
1028         } srvsvc_NetSrvInfo1546;
1029
1030         typedef struct{
1031                 uint32 alertsched;
1032         } srvsvc_NetSrvInfo1547;
1033
1034         typedef struct{
1035                 uint32 errortreshold;
1036         } srvsvc_NetSrvInfo1548;
1037
1038         typedef struct{
1039                 uint32 networkerrortreshold;
1040         } srvsvc_NetSrvInfo1549;
1041
1042         typedef struct{
1043                 uint32 diskspacetreshold;
1044         } srvsvc_NetSrvInfo1550;
1045
1046         typedef struct{
1047                 uint32 maxlinkdelay;
1048         } srvsvc_NetSrvInfo1552;
1049
1050         typedef struct{
1051                 uint32 minlinkthroughput;
1052         } srvsvc_NetSrvInfo1553;
1053
1054         typedef struct{
1055                 uint32 linkinfovalidtime;
1056         } srvsvc_NetSrvInfo1554;
1057
1058         typedef struct{
1059                 uint32 scavqosinfoupdatetime;
1060         } srvsvc_NetSrvInfo1555;
1061
1062         typedef struct{
1063                 uint32 maxworkitemidletime;
1064         } srvsvc_NetSrvInfo1556;
1065
1066
1067         typedef union{
1068                 [case(100)]     srvsvc_NetSrvInfo100 *info100;
1069                 [case(101)]     srvsvc_NetSrvInfo101 *info101;
1070                 [case(102)]     srvsvc_NetSrvInfo102 *info102;
1071                 [case(402)]     srvsvc_NetSrvInfo402 *info402;
1072                 [case(403)]     srvsvc_NetSrvInfo403 *info403;
1073                 [case(502)]     srvsvc_NetSrvInfo502 *info502;
1074                 [case(503)]     srvsvc_NetSrvInfo503 *info503;
1075                 [case(599)]     srvsvc_NetSrvInfo599 *info599;
1076                 [case(1005)]    srvsvc_NetSrvInfo1005 *info1005;
1077                 [case(1010)]    srvsvc_NetSrvInfo1010 *info1010;
1078                 [case(1016)]    srvsvc_NetSrvInfo1016 *info1016;
1079                 [case(1017)]    srvsvc_NetSrvInfo1017 *info1017;
1080                 [case(1018)]    srvsvc_NetSrvInfo1018 *info1018;
1081                 [case(1107)]    srvsvc_NetSrvInfo1107 *info1107;
1082                 [case(1501)]    srvsvc_NetSrvInfo1501 *info1501;
1083                 [case(1502)]    srvsvc_NetSrvInfo1502 *info1502;
1084                 [case(1503)]    srvsvc_NetSrvInfo1503 *info1503;
1085                 [case(1506)]    srvsvc_NetSrvInfo1506 *info1506;
1086                 [case(1509)]    srvsvc_NetSrvInfo1509 *info1509;
1087                 [case(1510)]    srvsvc_NetSrvInfo1510 *info1510;
1088                 [case(1511)]    srvsvc_NetSrvInfo1511 *info1511;
1089                 [case(1512)]    srvsvc_NetSrvInfo1512 *info1512;
1090                 [case(1513)]    srvsvc_NetSrvInfo1513 *info1513;
1091                 [case(1514)]    srvsvc_NetSrvInfo1514 *info1514;
1092                 [case(1515)]    srvsvc_NetSrvInfo1515 *info1515;
1093                 [case(1516)]    srvsvc_NetSrvInfo1516 *info1516;
1094                 [case(1518)]    srvsvc_NetSrvInfo1518 *info1518;
1095                 [case(1520)]    srvsvc_NetSrvInfo1520 *info1520;
1096                 [case(1521)]    srvsvc_NetSrvInfo1521 *info1521;
1097                 [case(1522)]    srvsvc_NetSrvInfo1522 *info1522;
1098                 [case(1523)]    srvsvc_NetSrvInfo1523 *info1523;
1099                 [case(1524)]    srvsvc_NetSrvInfo1524 *info1524;
1100                 [case(1525)]    srvsvc_NetSrvInfo1525 *info1525;
1101                 [case(1528)]    srvsvc_NetSrvInfo1528 *info1528;
1102                 [case(1529)]    srvsvc_NetSrvInfo1529 *info1529;
1103                 [case(1530)]    srvsvc_NetSrvInfo1530 *info1530;
1104                 [case(1533)]    srvsvc_NetSrvInfo1533 *info1533;
1105                 [case(1534)]    srvsvc_NetSrvInfo1534 *info1534;
1106                 [case(1535)]    srvsvc_NetSrvInfo1535 *info1535;
1107                 [case(1536)]    srvsvc_NetSrvInfo1536 *info1536;
1108                 [case(1537)]    srvsvc_NetSrvInfo1537 *info1537;
1109                 [case(1538)]    srvsvc_NetSrvInfo1538 *info1538;
1110                 [case(1539)]    srvsvc_NetSrvInfo1539 *info1539;
1111                 [case(1540)]    srvsvc_NetSrvInfo1540 *info1540;
1112                 [case(1541)]    srvsvc_NetSrvInfo1541 *info1541;
1113                 [case(1542)]    srvsvc_NetSrvInfo1542 *info1542;
1114                 [case(1543)]    srvsvc_NetSrvInfo1543 *info1543;
1115                 [case(1544)]    srvsvc_NetSrvInfo1544 *info1544;
1116                 [case(1545)]    srvsvc_NetSrvInfo1545 *info1545;
1117                 [case(1546)]    srvsvc_NetSrvInfo1546 *info1546;
1118                 [case(1547)]    srvsvc_NetSrvInfo1547 *info1547;
1119                 [case(1548)]    srvsvc_NetSrvInfo1548 *info1548;
1120                 [case(1549)]    srvsvc_NetSrvInfo1549 *info1549;
1121                 [case(1550)]    srvsvc_NetSrvInfo1550 *info1550;
1122                 [case(1552)]    srvsvc_NetSrvInfo1552 *info1552;
1123                 [case(1553)]    srvsvc_NetSrvInfo1553 *info1553;
1124                 [case(1554)]    srvsvc_NetSrvInfo1554 *info1554;
1125                 [case(1555)]    srvsvc_NetSrvInfo1555 *info1555;
1126                 [case(1556)]    srvsvc_NetSrvInfo1556 *info1556;
1127                 [default];
1128         } srvsvc_NetSrvInfo;
1129
1130         /******************/
1131         /* Function: 0x15 */
1132         WERROR srvsvc_NetSrvGetInfo(
1133                 [in,unique]   [string,charset(UTF16)] uint16 *server_unc,
1134                 [in]   uint32 level,
1135                 [out,switch_is(level)] srvsvc_NetSrvInfo info
1136                 );
1137
1138         /******************/
1139         /* Function: 0x16 */
1140         WERROR srvsvc_NetSrvSetInfo(
1141                 [in,unique]   [string,charset(UTF16)] uint16 *server_unc,
1142                 [in]   uint32 level,
1143                 [in,switch_is(level)] srvsvc_NetSrvInfo info,
1144                 [in,out,unique]   uint32 *parm_error
1145                 );
1146
1147 /**************************/
1148 /* srvsvc_NetDisk         */
1149 /**************************/
1150         typedef struct {
1151                 /*
1152                  * In theory this should be:
1153                  *      [charset(UTF16),string] uint16 annotation[3]
1154                  * But midl treats this as:
1155                  *      [charset(UTF16),string] uint16 annotation[]
1156                  * and pidl doesn't support this yet
1157                  */
1158                 [value(0)] uint32 __disk_offset;
1159                 [value(strlen(disk)+1)] uint32 __disk_length;
1160                 [charset(UTF16)] uint16 disk[__disk_length];
1161         } srvsvc_NetDiskInfo0;
1162
1163         typedef struct {
1164                 uint32 count;
1165                 [size_is(count), length_is(count)] srvsvc_NetDiskInfo0 *disks;
1166         } srvsvc_NetDiskInfo;
1167
1168         /******************/
1169         /* Function: 0x17 */
1170         WERROR srvsvc_NetDiskEnum(
1171                 [in,unique]      [string,charset(UTF16)] uint16 *server_unc,
1172                 [in]      uint32 level,
1173                 [in,out]  srvsvc_NetDiskInfo info,
1174                 [in]      uint32 maxlen,
1175                 [out]     uint32 totalentries,
1176                 [in,out,unique]  uint32 *resume_handle
1177                 );
1178
1179 /**************************/
1180 /* srvsvc_NetStatistics   */
1181 /**************************/
1182         typedef struct {
1183                 uint32 start;
1184                 uint32 fopens;
1185                 uint32 devopens;
1186                 uint32 jobsqueued;
1187                 uint32 sopens;
1188                 uint32 stimeouts;
1189                 uint32 serrorout;
1190                 uint32 pwerrors;
1191                 uint32 permerrors;
1192                 uint32 syserrors;
1193                 uint32 bytessent_low;
1194                 uint32 bytessent_high;
1195                 uint32 bytesrcvd_low;
1196                 uint32 bytesrcvd_high;
1197                 uint32 avresponse;
1198                 uint32 reqbufneed;
1199                 uint32 bigbufneed;
1200         } srvsvc_Statistics;
1201
1202         /******************/
1203         /* Function: 0x18 */
1204         WERROR srvsvc_NetServerStatisticsGet(
1205                 [in,unique]      [string,charset(UTF16)] uint16 *server_unc,
1206                 [in,unique]      [string,charset(UTF16)] uint16 *service,
1207                 [in]      uint32 level,
1208                 [in]      uint32 options,
1209                 [out]     srvsvc_Statistics stat
1210                 );
1211
1212 /**************************/
1213 /* srvsvc_NetTransport    */
1214 /**************************/
1215         typedef struct {
1216                 uint32 vcs;
1217                 [string,charset(UTF16)] uint16 *name;
1218                 [size_is(addr_len)] uint8 *addr;
1219                 uint32 addr_len;
1220                 [string,charset(UTF16)] uint16 *net_addr;
1221         } srvsvc_NetTransportInfo0;
1222
1223         /******************/
1224         /* Function: 0x19 */
1225         WERROR srvsvc_NetTransportAdd(
1226                 [in,unique]   [string,charset(UTF16)] uint16 *server_unc,
1227                 [in] uint32 level,
1228                 [in,switch_is(level)]   srvsvc_NetTransportInfo info
1229                 );
1230
1231         typedef struct {
1232                 uint32 count;
1233                 [size_is(count)] srvsvc_NetTransportInfo0 *array;
1234         } srvsvc_NetTransportCtr0;
1235
1236         typedef struct {
1237                 uint32 vcs;
1238                 [string,charset(UTF16)] uint16 *name;
1239                 [size_is(addr_len)] uint8 *addr;
1240                 uint32 addr_len;
1241                 [string,charset(UTF16)] uint16 *net_addr;
1242                 [string,charset(UTF16)] uint16 *domain;
1243         } srvsvc_NetTransportInfo1;
1244
1245         typedef struct {
1246                 uint32 count;
1247                 [size_is(count)] srvsvc_NetTransportInfo1 *array;
1248         } srvsvc_NetTransportCtr1;
1249
1250         typedef struct {
1251                 uint32 vcs;
1252                 [string,charset(UTF16)] uint16 *name;
1253                 [size_is(addr_len)] uint8 *addr;
1254                 uint32 addr_len;
1255                 [string,charset(UTF16)] uint16 *net_addr;
1256                 [string,charset(UTF16)] uint16 *domain;
1257                 uint32 unknown;
1258         } srvsvc_NetTransportInfo2;
1259
1260         typedef struct {
1261                 uint32 count;
1262                 [size_is(count)] srvsvc_NetTransportInfo2 *array;
1263         } srvsvc_NetTransportCtr2;
1264
1265         typedef struct {
1266                 uint32 vcs;
1267                 [string,charset(UTF16)] uint16 *name;
1268                 [size_is(addr_len)] uint8 *addr;
1269                 uint32 addr_len;
1270                 [string,charset(UTF16)] uint16 *net_addr;
1271                 [string,charset(UTF16)] uint16 *domain;
1272                 uint32 unknown1;
1273                 uint32 unknown2;
1274                 uint8 unknown3[256];
1275         } srvsvc_NetTransportInfo3;
1276
1277         typedef struct {
1278                 uint32 count;
1279                 [size_is(count)] srvsvc_NetTransportInfo3 *array;
1280         } srvsvc_NetTransportCtr3;
1281
1282         typedef union {
1283                 [case(0)] srvsvc_NetTransportCtr0 *ctr0;
1284                 [case(1)] srvsvc_NetTransportCtr1 *ctr1;
1285                 [case(2)] srvsvc_NetTransportCtr2 *ctr2;
1286                 [case(3)] srvsvc_NetTransportCtr3 *ctr3;
1287                 [default];
1288         } srvsvc_NetTransportCtr;
1289
1290         /******************/
1291         /* Function: 0x1a */
1292         WERROR srvsvc_NetTransportEnum(
1293                 [in,unique]   [string,charset(UTF16)] uint16 *server_unc,
1294                 [in,out] uint32 level,
1295                 [in,out,switch_is(level)]   srvsvc_NetTransportCtr transports,
1296                 [in]   uint32 max_buffer,
1297                 [out]   uint32 totalentries,
1298                 [in,out,unique]   uint32 *resume_handle
1299                 );
1300
1301         /******************/
1302         /* Function: 0x1b */
1303         WERROR srvsvc_NetTransportDel(
1304                 [in,unique]   [string,charset(UTF16)] uint16 *server_unc,
1305                 [in]    uint32 level,
1306                 [in,switch_is(level)]   srvsvc_NetTransportInfo info
1307                 );
1308
1309 /**************************/
1310 /* srvsvc_NetRemoteTOD    */
1311 /**************************/
1312         typedef struct {
1313                 uint32 elapsed; /* time(NULL) */
1314                 uint32 msecs; /* milliseconds till system reboot (uptime) */
1315                 uint32 hours;
1316                 uint32 mins;
1317                 uint32 secs;
1318                 uint32 hunds;
1319                 int32 timezone; /* in minutes */
1320                 uint32 tinterval; /* clock tick interval in 0.0001 second units; 310 on windows */
1321                 uint32 day;
1322                 uint32 month;
1323                 uint32 year;
1324                 uint32 weekday;
1325         } srvsvc_NetRemoteTODInfo;
1326
1327         /******************/
1328         /* Function: 0x1c */
1329         WERROR srvsvc_NetRemoteTOD(
1330                 [in,unique]   [string,charset(UTF16)] uint16 *server_unc,
1331                 [out,unique]   srvsvc_NetRemoteTODInfo *info
1332                 );
1333
1334 /**************************/
1335 /* srvsvc_NetServiceBits  */
1336 /**************************/
1337         /******************/
1338         /* Function: 0x1d */
1339         WERROR srvsvc_NetSetServiceBits(
1340                 [in,unique]   [string,charset(UTF16)] uint16 *server_unc,
1341                 [in,unique]   [string,charset(UTF16)] uint16 *transport,
1342                 [in]   uint32 servicebits,
1343                 [in]   uint32 updateimmediately
1344                 );
1345
1346 /**************************/
1347 /* srvsvc_NetPath         */
1348 /**************************/
1349         /******************/
1350         /* Function: 0x1e */
1351         WERROR srvsvc_NetPathType(
1352                 [in,unique]   [string,charset(UTF16)] uint16 *server_unc,
1353                 [in]   [string,charset(UTF16)] uint16 path[],
1354                 [in]   uint32 pathflags,
1355                 [out]   uint32 pathtype
1356                 );
1357
1358         /******************/
1359         /* Function: 0x1f */
1360         WERROR srvsvc_NetPathCanonicalize(
1361                 [in,unique]   [string,charset(UTF16)] uint16 *server_unc,
1362                 [in]   [string,charset(UTF16)] uint16 path[],
1363                 [out]  [size_is(maxbuf)] uint8 can_path[],
1364                 [in]   uint32 maxbuf,
1365                 [in]   [string,charset(UTF16)] uint16 prefix[],
1366                 [in,out] uint32 pathtype,
1367                 [in]    uint32 pathflags
1368                 );
1369
1370         /******************/
1371         /* Function: 0x20 */
1372         WERROR srvsvc_NetPathCompare(
1373                 [in,unique]   [string,charset(UTF16)] uint16 *server_unc,
1374                 [in]   [string,charset(UTF16)] uint16 path1[],
1375                 [in]   [string,charset(UTF16)] uint16 path2[],
1376                 [in]    uint32 pathtype,
1377                 [in]    uint32 pathflags
1378                 );
1379
1380 /**************************/
1381 /* srvsvc_NetName         */
1382 /**************************/
1383         /******************/
1384         /* Function: 0x21 */
1385         WERROR srvsvc_NetNameValidate(
1386                 [in,unique]   [string,charset(UTF16)] uint16 *server_unc,
1387                 [in]   [string,charset(UTF16)] uint16 name[],
1388                 [in]    uint32 name_type,
1389                 [in]    uint32 flags
1390                 );
1391
1392         /******************/
1393         /* Function: 0x22 */
1394         [todo] WERROR srvsvc_NETRPRNAMECANONICALIZE(
1395                 );
1396
1397         /******************/
1398         /* Function: 0x23 */
1399         WERROR srvsvc_NetPRNameCompare(
1400                 [in,unique]   [string,charset(UTF16)] uint16 *server_unc,
1401                 [in]   [string,charset(UTF16)] uint16 name1[],
1402                 [in]   [string,charset(UTF16)] uint16 name2[],
1403                 [in]    uint32 name_type,
1404                 [in]    uint32 flags
1405                 );
1406
1407 /**************************/
1408 /* srvsvc_NetShare ...    */
1409 /**************************/
1410         /******************/
1411         /* Function: 0x24 */
1412         /* Note, there must be some way to return entries read vs 
1413            total entries ... */
1414         WERROR srvsvc_NetShareEnum(
1415                 [in,unique]       [string,charset(UTF16)] uint16 *server_unc,
1416                 [in,out]   uint32 level,
1417                 [in,out,switch_is(level)]   srvsvc_NetShareCtr ctr,
1418                 [in]       uint32 max_buffer,
1419                 [out]      uint32 totalentries,
1420                 [in,out,unique]   uint32 *resume_handle
1421                 );
1422
1423         /******************/
1424         /* Function: 0x25 */
1425         WERROR srvsvc_NetShareDelStart(
1426                 [in,unique]       [string,charset(UTF16)] uint16 *server_unc,
1427                 [in]       [string,charset(UTF16)] uint16 share[],
1428                 [in]       uint32 reserved,
1429                 [out,unique] policy_handle *hnd
1430                 );
1431
1432         /******************/
1433         /* Function: 0x26 */
1434         WERROR srvsvc_NetShareDelCommit(
1435                 [in, out,unique] policy_handle *hnd
1436                 );
1437
1438         /******************/
1439         /* Function: 0x27 */
1440         WERROR srvsvc_NetGetFileSecurity(
1441                 [in,unique]       [string,charset(UTF16)] uint16 *server_unc,
1442                 [in,unique]       [string,charset(UTF16)] uint16 *share,
1443                 [in]       [string,charset(UTF16)] uint16 file[],
1444                 [in]       security_secinfo securityinformation,
1445                 [out,unique]       sec_desc_buf *sd_buf
1446                 );
1447
1448         /******************/
1449         /* Function: 0x28 */
1450         WERROR srvsvc_NetSetFileSecurity(
1451                 [in,unique]       [string,charset(UTF16)] uint16 *server_unc,
1452                 [in,unique]       [string,charset(UTF16)] uint16 *share,
1453                 [in]       [string,charset(UTF16)] uint16 file[],
1454                 [in]       security_secinfo securityinformation,
1455                 [in]       sec_desc_buf sd_buf
1456                 );
1457
1458
1459
1460         typedef [switch_type(uint32)] union {
1461                 [case(0)] srvsvc_NetTransportInfo0 info0;
1462                 [case(1)] srvsvc_NetTransportInfo1 info1;
1463                 [case(2)] srvsvc_NetTransportInfo2 info2;
1464                 [case(3)] srvsvc_NetTransportInfo3 info3;
1465         } srvsvc_NetTransportInfo;
1466
1467         /******************/
1468         /* Function: 0x29 */
1469         WERROR srvsvc_NetServerTransportAddEx(
1470                 [in,unique]   [string,charset(UTF16)] uint16 *server_unc,
1471                 [in] uint32 level,
1472                 [in,switch_is(level)]   srvsvc_NetTransportInfo info
1473                 );
1474
1475         /******************/
1476         /* Function: 0x2a */
1477         WERROR srvsvc_NetServerSetServiceBitsEx(
1478                 [in,unique]   [string,charset(UTF16)] uint16 *server_unc,
1479                 [in,unique]   [string,charset(UTF16)] uint16 *emulated_server_unc,
1480                 [in,unique]   [string,charset(UTF16)] uint16 *transport,
1481                 [in]   uint32 servicebitsofinterest,
1482                 [in]   uint32 servicebits,
1483                 [in]   uint32 updateimmediately
1484                 );
1485
1486         /******************/
1487         /* Function: 0x2b */
1488         [todo] WERROR srvsvc_NETRDFSGETVERSION(
1489                 );
1490
1491         /******************/
1492         /* Function: 0x2c */
1493         [todo] WERROR srvsvc_NETRDFSCREATELOCALPARTITION(
1494                 );
1495
1496         /******************/
1497         /* Function: 0x2d */
1498         [todo] WERROR srvsvc_NETRDFSDELETELOCALPARTITION(
1499                 );
1500
1501         /******************/
1502         /* Function: 0x2e */
1503         [todo] WERROR srvsvc_NETRDFSSETLOCALVOLUMESTATE(
1504                 );
1505
1506         /******************/
1507         /* Function: 0x2f */
1508         [todo] WERROR srvsvc_NETRDFSSETSERVERINFO(
1509                 );
1510
1511         /******************/
1512         /* Function: 0x30 */
1513         [todo] WERROR srvsvc_NETRDFSCREATEEXITPOINT(
1514                 );
1515
1516         /******************/
1517         /* Function: 0x31 */
1518         [todo] WERROR srvsvc_NETRDFSDELETEEXITPOINT(
1519                 );
1520
1521         /******************/
1522         /* Function: 0x32 */
1523         [todo] WERROR srvsvc_NETRDFSMODIFYPREFIX(
1524                 );
1525
1526         /******************/
1527         /* Function: 0x33 */
1528         [todo] WERROR srvsvc_NETRDFSFIXLOCALVOLUME(
1529                 );
1530
1531         /******************/
1532         /* Function: 0x34 */
1533         [todo] WERROR srvsvc_NETRDFSMANAGERREPORTSITEINFO(
1534                 );
1535
1536         /******************/
1537         /* Function: 0x35 */
1538         [todo] WERROR srvsvc_NETRSERVERTRANSPORTDELEX(
1539                 );
1540 }