summaryrefslogtreecommitdiff
path: root/librpc/gen_ndr/svcctl.h
blob: c0daab43d5f39a63e67d300aa37e67ce250312fc (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
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
/* header auto-generated by pidl */

#include <stdint.h>

#include "libcli/util/ntstatus.h"

#include "librpc/gen_ndr/misc.h"
#include "librpc/gen_ndr/security.h"
#ifndef _HEADER_svcctl
#define _HEADER_svcctl

#define SVCCTL_ACCEPT_NONE	( 0x00000000 )
#define SERVICE_TYPE_KERNEL_DRIVER	( 0x01 )
#define SERVICE_TYPE_FS_DRIVER	( 0x02 )
#define SERVICE_TYPE_ADAPTER	( 0x04 )
#define SERVICE_TYPE_RECOGNIZER_DRIVER	( 0x08 )
#define SERVICE_TYPE_DRIVER	( SERVICE_TYPE_KERNEL_DRIVER|SERVICE_TYPE_FS_DRIVER|SERVICE_TYPE_RECOGNIZER_DRIVER )
#define SERVICE_TYPE_WIN32_OWN_PROCESS	( 0x10 )
#define SERVICE_TYPE_WIN32_SHARE_PROCESS	( 0x20 )
#define SERVICE_TYPE_WIN32	( SERVICE_TYPE_WIN32_OWN_PROCESS|SERVICE_TYPE_WIN32_SHARE_PROCESS )
#define SERVICE_TYPE_INTERACTIVE_PROCESS	( 0x100 )
#define SV_TYPE_ALL	( 0xFFFFFFFF )
#define SC_MANAGER_READ_ACCESS	( (SEC_STD_READ_CONTROL|SC_RIGHT_MGR_CONNECT|SC_RIGHT_MGR_ENUMERATE_SERVICE|SC_RIGHT_MGR_QUERY_LOCK_STATUS) )
#define SC_MANAGER_EXECUTE_ACCESS	( SC_MANAGER_READ_ACCESS )
#define SC_MANAGER_WRITE_ACCESS	( (SEC_STD_REQUIRED|SC_MANAGER_READ_ACCESS|SC_RIGHT_MGR_CREATE_SERVICE|SC_RIGHT_MGR_LOCK|SC_RIGHT_MGR_MODIFY_BOOT_CONFIG) )
#define SC_MANAGER_ALL_ACCESS	( SC_MANAGER_WRITE_ACCESS )
#define SERVICE_READ_ACCESS	( (SEC_STD_READ_CONTROL|SC_RIGHT_SVC_ENUMERATE_DEPENDENTS|SC_RIGHT_SVC_INTERROGATE|SC_RIGHT_SVC_QUERY_CONFIG|SC_RIGHT_SVC_QUERY_STATUS|SC_RIGHT_SVC_USER_DEFINED_CONTROL) )
#define SERVICE_EXECUTE_ACCESS	( (SERVICE_READ_ACCESS|SC_RIGHT_SVC_START|SC_RIGHT_SVC_STOP|SC_RIGHT_SVC_PAUSE_CONTINUE) )
#define SERVICE_WRITE_ACCESS	( (SEC_STD_REQUIRED|SERVICE_READ_ACCESS|SERVICE_EXECUTE_ACCESS|SC_RIGHT_SVC_CHANGE_CONFIG) )
#define SERVICE_ALL_ACCESS	( SERVICE_WRITE_ACCESS )
struct SERVICE_LOCK_STATUS {
	uint32_t is_locked;
	const char *lock_owner;/* [unique,charset(UTF16)] */
	uint32_t lock_duration;
};

enum svcctl_ServiceStatus
#ifndef USE_UINT_ENUMS
 {
	SVCCTL_STATE_UNKNOWN=0x00000000,
	SVCCTL_STOPPED=0x00000001,
	SVCCTL_START_PENDING=0x00000002,
	SVCCTL_STOP_PENDING=0x00000003,
	SVCCTL_RUNNING=0x00000004,
	SVCCTL_CONTINUE_PENDING=0x00000005,
	SVCCTL_PAUSE_PENDING=0x00000006,
	SVCCTL_PAUSED=0x00000007
}
#else
 { __donnot_use_enum_svcctl_ServiceStatus=0x7FFFFFFF}
#define SVCCTL_STATE_UNKNOWN ( 0x00000000 )
#define SVCCTL_STOPPED ( 0x00000001 )
#define SVCCTL_START_PENDING ( 0x00000002 )
#define SVCCTL_STOP_PENDING ( 0x00000003 )
#define SVCCTL_RUNNING ( 0x00000004 )
#define SVCCTL_CONTINUE_PENDING ( 0x00000005 )
#define SVCCTL_PAUSE_PENDING ( 0x00000006 )
#define SVCCTL_PAUSED ( 0x00000007 )
#endif
;

/* bitmap svcctl_ControlsAccepted */
#define SVCCTL_ACCEPT_STOP ( 0x00000001 )
#define SVCCTL_ACCEPT_PAUSE_CONTINUE ( 0x00000002 )
#define SVCCTL_ACCEPT_SHUTDOWN ( 0x00000004 )
#define SVCCTL_ACCEPT_PARAMCHANGE ( 0x00000008 )
#define SVCCTL_ACCEPT_NETBINDCHANGE ( 0x00000010 )
#define SVCCTL_ACCEPT_HARDWAREPROFILECHANGE ( 0x00000020 )
#define SVCCTL_ACCEPT_POWEREVENT ( 0x00000040 )

struct SERVICE_STATUS {
	uint32_t type;
	enum svcctl_ServiceStatus state;
	uint32_t controls_accepted;
	WERROR win32_exit_code;
	uint32_t service_exit_code;
	uint32_t check_point;
	uint32_t wait_hint;
};

struct SERVICE_STATUS_PROCESS {
	struct SERVICE_STATUS status;
	uint32_t process_id;
	uint32_t service_flags;
}/* [public] */;

struct ENUM_SERVICE_STATUSW {
	const char * service_name;/* [relative,flag(LIBNDR_FLAG_STR_NULLTERM)] */
	const char * display_name;/* [relative,flag(LIBNDR_FLAG_STR_NULLTERM)] */
	struct SERVICE_STATUS status;
}/* [gensize,public] */;

struct ENUM_SERVICE_STATUSA {
	const char * service_name;/* [relative,flag(LIBNDR_FLAG_STR_ASCII|LIBNDR_FLAG_STR_NULLTERM)] */
	const char * display_name;/* [relative,flag(LIBNDR_FLAG_STR_ASCII|LIBNDR_FLAG_STR_NULLTERM)] */
	struct SERVICE_STATUS status;
}/* [gensize,public] */;

/* bitmap svcctl_ServerType */
#define SV_TYPE_WORKSTATION ( 0x00000001 )
#define SV_TYPE_SERVER ( 0x00000002 )
#define SV_TYPE_SQLSERVER ( 0x00000004 )
#define SV_TYPE_DOMAIN_CTRL ( 0x00000008 )
#define SV_TYPE_DOMAIN_BAKCTRL ( 0x00000010 )
#define SV_TYPE_TIME_SOURCE ( 0x00000020 )
#define SV_TYPE_AFP ( 0x00000040 )
#define SV_TYPE_NOVELL ( 0x00000080 )
#define SV_TYPE_DOMAIN_MEMBER ( 0x00000100 )
#define SV_TYPE_PRINTQ_SERVER ( 0x00000200 )
#define SV_TYPE_DIALIN_SERVER ( 0x00000400 )
#define SV_TYPE_SERVER_UNIX ( 0x00000800 )
#define SV_TYPE_NT ( 0x00001000 )
#define SV_TYPE_WFW ( 0x00002000 )
#define SV_TYPE_SERVER_MFPN ( 0x00004000 )
#define SV_TYPE_SERVER_NT ( 0x00008000 )
#define SV_TYPE_POTENTIAL_BROWSER ( 0x00010000 )
#define SV_TYPE_BACKUP_BROWSER ( 0x00020000 )
#define SV_TYPE_MASTER_BROWSER ( 0x00040000 )
#define SV_TYPE_DOMAIN_MASTER ( 0x00080000 )
#define SV_TYPE_SERVER_OSF ( 0x00100000 )
#define SV_TYPE_SERVER_VMS ( 0x00200000 )
#define SV_TYPE_WIN95_PLUS ( 0x00400000 )
#define SV_TYPE_DFS_SERVER ( 0x00800000 )
#define SV_TYPE_ALTERNATE_XPORT ( 0x20000000 )
#define SV_TYPE_LOCAL_LIST_ONLY ( 0x40000000 )
#define SV_TYPE_DOMAIN_ENUM ( 0x80000000 )

enum SERVICE_CONTROL
#ifndef USE_UINT_ENUMS
 {
	SVCCTL_CONTROL_STOP=0x00000001,
	SVCCTL_CONTROL_PAUSE=0x00000002,
	SVCCTL_CONTROL_CONTINUE=0x00000003,
	SVCCTL_CONTROL_INTERROGATE=0x00000004,
	SVCCTL_CONTROL_SHUTDOWN=0x00000005
}
#else
 { __donnot_use_enum_SERVICE_CONTROL=0x7FFFFFFF}
#define SVCCTL_CONTROL_STOP ( 0x00000001 )
#define SVCCTL_CONTROL_PAUSE ( 0x00000002 )
#define SVCCTL_CONTROL_CONTINUE ( 0x00000003 )
#define SVCCTL_CONTROL_INTERROGATE ( 0x00000004 )
#define SVCCTL_CONTROL_SHUTDOWN ( 0x00000005 )
#endif
;

enum svcctl_ErrorControl
#ifndef USE_UINT_ENUMS
 {
	SVCCTL_SVC_ERROR_IGNORE=0x00000000,
	SVCCTL_SVC_ERROR_NORMAL=0x00000001,
	SVCCTL_SVC_ERROR_CRITICAL=0x00000002,
	SVCCTL_SVC_ERROR_SEVERE=0x00000003
}
#else
 { __donnot_use_enum_svcctl_ErrorControl=0x7FFFFFFF}
#define SVCCTL_SVC_ERROR_IGNORE ( 0x00000000 )
#define SVCCTL_SVC_ERROR_NORMAL ( 0x00000001 )
#define SVCCTL_SVC_ERROR_CRITICAL ( 0x00000002 )
#define SVCCTL_SVC_ERROR_SEVERE ( 0x00000003 )
#endif
;

enum svcctl_StartType
#ifndef USE_UINT_ENUMS
 {
	SVCCTL_BOOT_START=0x00000000,
	SVCCTL_SYSTEM_START=0x00000001,
	SVCCTL_AUTO_START=0x00000002,
	SVCCTL_DEMAND_START=0x00000003,
	SVCCTL_DISABLED=0x00000004
}
#else
 { __donnot_use_enum_svcctl_StartType=0x7FFFFFFF}
#define SVCCTL_BOOT_START ( 0x00000000 )
#define SVCCTL_SYSTEM_START ( 0x00000001 )
#define SVCCTL_AUTO_START ( 0x00000002 )
#define SVCCTL_DEMAND_START ( 0x00000003 )
#define SVCCTL_DISABLED ( 0x00000004 )
#endif
;

enum svcctl_ServiceState
#ifndef USE_UINT_ENUMS
 {
	SERVICE_STATE_ACTIVE=0x00000001,
	SERVICE_STATE_INACTIVE=0x00000002,
	SERVICE_STATE_ALL=(SERVICE_STATE_ACTIVE|SERVICE_STATE_INACTIVE)
}
#else
 { __donnot_use_enum_svcctl_ServiceState=0x7FFFFFFF}
#define SERVICE_STATE_ACTIVE ( 0x00000001 )
#define SERVICE_STATE_INACTIVE ( 0x00000002 )
#define SERVICE_STATE_ALL ( (SERVICE_STATE_ACTIVE|SERVICE_STATE_INACTIVE) )
#endif
;

/* bitmap svcctl_MgrAccessMask */
#define SC_RIGHT_MGR_CONNECT ( 0x0001 )
#define SC_RIGHT_MGR_CREATE_SERVICE ( 0x0002 )
#define SC_RIGHT_MGR_ENUMERATE_SERVICE ( 0x0004 )
#define SC_RIGHT_MGR_LOCK ( 0x0008 )
#define SC_RIGHT_MGR_QUERY_LOCK_STATUS ( 0x0010 )
#define SC_RIGHT_MGR_MODIFY_BOOT_CONFIG ( 0x0020 )

/* bitmap svcctl_ServiceAccessMask */
#define SC_RIGHT_SVC_QUERY_CONFIG ( 0x0001 )
#define SC_RIGHT_SVC_CHANGE_CONFIG ( 0x0002 )
#define SC_RIGHT_SVC_QUERY_STATUS ( 0x0004 )
#define SC_RIGHT_SVC_ENUMERATE_DEPENDENTS ( 0x0008 )
#define SC_RIGHT_SVC_START ( 0x0010 )
#define SC_RIGHT_SVC_STOP ( 0x0020 )
#define SC_RIGHT_SVC_PAUSE_CONTINUE ( 0x0040 )
#define SC_RIGHT_SVC_INTERROGATE ( 0x0080 )
#define SC_RIGHT_SVC_USER_DEFINED_CONTROL ( 0x0100 )

struct QUERY_SERVICE_CONFIG {
	uint32_t service_type;
	enum svcctl_StartType start_type;
	enum svcctl_ErrorControl error_control;
	const char *executablepath;/* [unique,range(0,8192),charset(UTF16)] */
	const char *loadordergroup;/* [unique,range(0,8192),charset(UTF16)] */
	uint32_t tag_id;
	const char *dependencies;/* [unique,range(0,8192),charset(UTF16)] */
	const char *startname;/* [unique,range(0,8192),charset(UTF16)] */
	const char *displayname;/* [unique,range(0,8192),charset(UTF16)] */
}/* [gensize,public] */;

enum svcctl_ConfigLevel
#ifndef USE_UINT_ENUMS
 {
	SERVICE_CONFIG_DESCRIPTION=0x00000001,
	SERVICE_CONFIG_FAILURE_ACTIONS=0x00000002
}
#else
 { __donnot_use_enum_svcctl_ConfigLevel=0x7FFFFFFF}
#define SERVICE_CONFIG_DESCRIPTION ( 0x00000001 )
#define SERVICE_CONFIG_FAILURE_ACTIONS ( 0x00000002 )
#endif
;

struct SERVICE_DESCRIPTION {
	const char * description;/* [relative,flag(LIBNDR_FLAG_STR_NULLTERM)] */
}/* [gensize,public] */;

enum SC_ACTION_TYPE
#ifndef USE_UINT_ENUMS
 {
	SC_ACTION_NONE=0,
	SC_ACTION_RESTART=1,
	SC_ACTION_REBOOT=2,
	SC_ACTION_RUN_COMMAND=3
}
#else
 { __donnot_use_enum_SC_ACTION_TYPE=0x7FFFFFFF}
#define SC_ACTION_NONE ( 0 )
#define SC_ACTION_RESTART ( 1 )
#define SC_ACTION_REBOOT ( 2 )
#define SC_ACTION_RUN_COMMAND ( 3 )
#endif
;

struct SC_ACTION {
	enum SC_ACTION_TYPE type;
	uint32_t delay;
};

struct SERVICE_FAILURE_ACTIONS {
	uint32_t reset_period;
	const char * rebootmsg;/* [relative,flag(LIBNDR_FLAG_STR_NULLTERM)] */
	const char * command;/* [relative,flag(LIBNDR_FLAG_STR_NULLTERM)] */
	uint32_t num_actions;/* [range(0,1024)] */
	struct SC_ACTION *actions;/* [relative,size_is(num_actions)] */
}/* [gensize,public] */;

enum svcctl_StatusLevel
#ifndef USE_UINT_ENUMS
 {
	SVC_STATUS_PROCESS_INFO=0x00000000
}
#else
 { __donnot_use_enum_svcctl_StatusLevel=0x7FFFFFFF}
#define SVC_STATUS_PROCESS_INFO ( 0x00000000 )
#endif
;


struct svcctl_CloseServiceHandle {
	struct {
		struct policy_handle *handle;/* [ref] */
	} in;

	struct {
		struct policy_handle *handle;/* [ref] */
		WERROR result;
	} out;

};


struct svcctl_ControlService {
	struct {
		struct policy_handle *handle;/* [ref] */
		enum SERVICE_CONTROL control;
	} in;

	struct {
		struct SERVICE_STATUS *service_status;/* [ref] */
		WERROR result;
	} out;

};


struct svcctl_DeleteService {
	struct {
		struct policy_handle *handle;/* [ref] */
	} in;

	struct {
		WERROR result;
	} out;

};


struct svcctl_LockServiceDatabase {
	struct {
		struct policy_handle *handle;/* [ref] */
	} in;

	struct {
		struct policy_handle *lock;/* [ref] */
		WERROR result;
	} out;

};


struct svcctl_QueryServiceObjectSecurity {
	struct {
		struct policy_handle *handle;/* [ref] */
		uint32_t security_flags;
		uint32_t offered;/* [range(0,0x40000)] */
	} in;

	struct {
		uint8_t *buffer;/* [ref,size_is(offered)] */
		uint32_t *needed;/* [ref,range(0,0x40000)] */
		WERROR result;
	} out;

};


struct svcctl_SetServiceObjectSecurity {
	struct {
		struct policy_handle *handle;/* [ref] */
		uint32_t security_flags;
		uint8_t *buffer;/* [ref,size_is(offered)] */
		uint32_t offered;
	} in;

	struct {
		WERROR result;
	} out;

};


struct svcctl_QueryServiceStatus {
	struct {
		struct policy_handle *handle;/* [ref] */
	} in;

	struct {
		struct SERVICE_STATUS *service_status;/* [ref] */
		WERROR result;
	} out;

};


struct svcctl_SetServiceStatus {
	struct {
		WERROR result;
	} out;

};


struct svcctl_UnlockServiceDatabase {
	struct {
		struct policy_handle *lock;/* [ref] */
	} in;

	struct {
		struct policy_handle *lock;/* [ref] */
		WERROR result;
	} out;

};


struct svcctl_NotifyBootConfigStatus {
	struct {
		WERROR result;
	} out;

};


struct svcctl_SCSetServiceBitsW {
	struct {
		struct policy_handle *handle;/* [ref] */
		uint32_t bits;
		uint32_t bitson;
		uint32_t immediate;
	} in;

	struct {
		WERROR result;
	} out;

};


struct svcctl_ChangeServiceConfigW {
	struct {
		struct policy_handle *handle;/* [ref] */
		uint32_t type;
		enum svcctl_StartType start_type;
		enum svcctl_ErrorControl error_control;
		const char *binary_path;/* [unique,charset(UTF16)] */
		const char *load_order_group;/* [unique,charset(UTF16)] */
		const char *dependencies;/* [unique,charset(UTF16)] */
		const char *service_start_name;/* [unique,charset(UTF16)] */
		const char *password;/* [unique,charset(UTF16)] */
		const char *display_name;/* [unique,charset(UTF16)] */
	} in;

	struct {
		uint32_t *tag_id;/* [ref] */
		WERROR result;
	} out;

};


struct svcctl_CreateServiceW {
	struct {
		struct policy_handle *scmanager_handle;/* [ref] */
		const char *ServiceName;/* [charset(UTF16)] */
		const char *DisplayName;/* [unique,charset(UTF16)] */
		uint32_t desired_access;
		uint32_t type;
		enum svcctl_StartType start_type;
		enum svcctl_ErrorControl error_control;
		const char *binary_path;/* [charset(UTF16)] */
		const char *LoadOrderGroupKey;/* [unique,charset(UTF16)] */
		uint8_t *dependencies;/* [unique,size_is(dependencies_size)] */
		uint32_t dependencies_size;
		const char *service_start_name;/* [unique,charset(UTF16)] */
		uint8_t *password;/* [unique,size_is(password_size)] */
		uint32_t password_size;
		uint32_t *TagId;/* [unique] */
	} in;

	struct {
		struct policy_handle *handle;/* [ref] */
		uint32_t *TagId;/* [unique] */
		WERROR result;
	} out;

};


struct svcctl_EnumDependentServicesW {
	struct {
		struct policy_handle *service;/* [ref] */
		enum svcctl_ServiceState state;
		uint32_t offered;/* [range(0,0x40000)] */
	} in;

	struct {
		uint8_t *service_status;/* [ref,size_is(offered)] */
		uint32_t *needed;/* [ref,range(0,0x40000)] */
		uint32_t *services_returned;/* [ref,range(0,0x40000)] */
		WERROR result;
	} out;

};


struct svcctl_EnumServicesStatusW {
	struct {
		struct policy_handle *handle;/* [ref] */
		uint32_t type;
		enum svcctl_ServiceState state;
		uint32_t offered;/* [range(0,0x40000)] */
		uint32_t *resume_handle;/* [unique] */
	} in;

	struct {
		uint8_t *service;/* [ref,size_is(offered)] */
		uint32_t *needed;/* [ref,range(0,0x40000)] */
		uint32_t *services_returned;/* [ref,range(0,0x40000)] */
		uint32_t *resume_handle;/* [unique] */
		WERROR result;
	} out;

};


struct svcctl_OpenSCManagerW {
	struct {
		const char *MachineName;/* [unique,charset(UTF16)] */
		const char *DatabaseName;/* [unique,charset(UTF16)] */
		uint32_t access_mask;
	} in;

	struct {
		struct policy_handle *handle;/* [ref] */
		WERROR result;
	} out;

};


struct svcctl_OpenServiceW {
	struct {
		struct policy_handle *scmanager_handle;/* [ref] */
		const char *ServiceName;/* [charset(UTF16)] */
		uint32_t access_mask;
	} in;

	struct {
		struct policy_handle *handle;/* [ref] */
		WERROR result;
	} out;

};


struct svcctl_QueryServiceConfigW {
	struct {
		struct policy_handle *handle;/* [ref] */
		uint32_t offered;/* [range(0,8192)] */
	} in;

	struct {
		struct QUERY_SERVICE_CONFIG *query;/* [ref] */
		uint32_t *needed;/* [ref,range(0,8192)] */
		WERROR result;
	} out;

};


struct svcctl_QueryServiceLockStatusW {
	struct {
		struct policy_handle *handle;/* [ref] */
		uint32_t offered;
	} in;

	struct {
		struct SERVICE_LOCK_STATUS *lock_status;/* [ref] */
		uint32_t *needed;/* [ref] */
		WERROR result;
	} out;

};


struct svcctl_StartServiceW {
	struct {
		struct policy_handle *handle;/* [ref] */
		uint32_t NumArgs;
		const char *Arguments;/* [unique,charset(UTF16)] */
	} in;

	struct {
		WERROR result;
	} out;

};


struct svcctl_GetServiceDisplayNameW {
	struct {
		struct policy_handle *handle;/* [ref] */
		const char *service_name;/* [unique,charset(UTF16)] */
		uint32_t *display_name_length;/* [unique] */
	} in;

	struct {
		const char **display_name;/* [ref,charset(UTF16)] */
		uint32_t *display_name_length;/* [unique] */
		WERROR result;
	} out;

};


struct svcctl_GetServiceKeyNameW {
	struct {
		struct policy_handle *handle;/* [ref] */
		const char *service_name;/* [unique,charset(UTF16)] */
		uint32_t *display_name_length;/* [unique] */
	} in;

	struct {
		const char **key_name;/* [ref,charset(UTF16)] */
		uint32_t *display_name_length;/* [unique] */
		WERROR result;
	} out;

};


struct svcctl_SCSetServiceBitsA {
	struct {
		struct policy_handle *handle;/* [ref] */
		uint32_t bits;
		uint32_t bitson;
		uint32_t immediate;
	} in;

	struct {
		WERROR result;
	} out;

};


struct svcctl_ChangeServiceConfigA {
	struct {
		struct policy_handle *handle;/* [ref] */
		uint32_t type;
		enum svcctl_StartType start_type;
		enum svcctl_ErrorControl error_control;
		const char *binary_path;/* [unique,charset(UTF16)] */
		const char *load_order_group;/* [unique,charset(UTF16)] */
		const char *dependencies;/* [unique,charset(UTF16)] */
		const char *service_start_name;/* [unique,charset(UTF16)] */
		const char *password;/* [unique,charset(UTF16)] */
		const char *display_name;/* [unique,charset(UTF16)] */
	} in;

	struct {
		uint32_t *tag_id;/* [ref] */
		WERROR result;
	} out;

};


struct svcctl_CreateServiceA {
	struct {
		struct policy_handle *handle;/* [ref] */
		const char *ServiceName;/* [unique,charset(UTF16)] */
		const char *DisplayName;/* [unique,charset(UTF16)] */
		uint32_t desired_access;
		uint32_t type;
		enum svcctl_StartType start_type;
		enum svcctl_ErrorControl error_control;
		const char *binary_path;/* [unique,charset(UTF16)] */
		const char *LoadOrderGroupKey;/* [unique,charset(UTF16)] */
		const char *dependencies;/* [unique,charset(UTF16)] */
		const char *service_start_name;/* [unique,charset(UTF16)] */
		const char *password;/* [unique,charset(UTF16)] */
	} in;

	struct {
		uint32_t *TagId;/* [unique] */
		WERROR result;
	} out;

};


struct svcctl_EnumDependentServicesA {
	struct {
		struct policy_handle *service;/* [ref] */
		enum svcctl_ServiceState state;
		uint32_t offered;
	} in;

	struct {
		struct ENUM_SERVICE_STATUSA *service_status;/* [unique] */
		uint32_t *needed;/* [ref] */
		uint32_t *services_returned;/* [ref] */
		WERROR result;
	} out;

};


struct svcctl_EnumServicesStatusA {
	struct {
		struct policy_handle *handle;/* [ref] */
		uint32_t type;
		enum svcctl_ServiceState state;
		uint32_t offered;
		uint32_t *resume_handle;/* [unique] */
	} in;

	struct {
		uint8_t *service;/* [size_is(offered)] */
		uint32_t *needed;/* [ref] */
		uint32_t *services_returned;/* [ref] */
		uint32_t *resume_handle;/* [unique] */
		WERROR result;
	} out;

};


struct svcctl_OpenSCManagerA {
	struct {
		const char *MachineName;/* [unique,charset(UTF16)] */
		const char *DatabaseName;/* [unique,charset(UTF16)] */
		uint32_t access_mask;
	} in;

	struct {
		struct policy_handle *handle;/* [ref] */
		WERROR result;
	} out;

};


struct svcctl_OpenServiceA {
	struct {
		struct policy_handle *scmanager_handle;/* [ref] */
		const char *ServiceName;/* [unique,charset(UTF16)] */
		uint32_t access_mask;
	} in;

	struct {
		WERROR result;
	} out;

};


struct svcctl_QueryServiceConfigA {
	struct {
		struct policy_handle *handle;/* [ref] */
		uint32_t offered;
	} in;

	struct {
		uint8_t *query;
		uint32_t *needed;/* [ref] */
		WERROR result;
	} out;

};


struct svcctl_QueryServiceLockStatusA {
	struct {
		struct policy_handle *handle;/* [ref] */
		uint32_t offered;
	} in;

	struct {
		struct SERVICE_LOCK_STATUS *lock_status;/* [ref] */
		uint32_t *needed;/* [ref] */
		WERROR result;
	} out;

};


struct svcctl_StartServiceA {
	struct {
		struct policy_handle *handle;/* [ref] */
		uint32_t NumArgs;
		const char *Arguments;/* [unique,charset(UTF16)] */
	} in;

	struct {
		WERROR result;
	} out;

};


struct svcctl_GetServiceDisplayNameA {
	struct {
		struct policy_handle *handle;/* [ref] */
		const char *service_name;/* [unique,charset(UTF16)] */
		uint32_t *display_name_length;/* [unique] */
	} in;

	struct {
		const char **display_name;/* [ref,charset(UTF16)] */
		uint32_t *display_name_length;/* [unique] */
		WERROR result;
	} out;

};


struct svcctl_GetServiceKeyNameA {
	struct {
		struct policy_handle *handle;/* [ref] */
		const char *service_name;/* [unique,charset(UTF16)] */
		uint32_t *display_name_length;/* [unique] */
	} in;

	struct {
		const char **key_name;/* [ref,charset(UTF16)] */
		uint32_t *display_name_length;/* [unique] */
		WERROR result;
	} out;

};


struct svcctl_GetCurrentGroupeStateW {
	struct {
		WERROR result;
	} out;

};


struct svcctl_EnumServiceGroupW {
	struct {
		WERROR result;
	} out;

};


struct svcctl_ChangeServiceConfig2A {
	struct {
		struct policy_handle *handle;/* [ref] */
		uint32_t info_level;
		uint8_t *info;/* [unique] */
	} in;

	struct {
		WERROR result;
	} out;

};


struct svcctl_ChangeServiceConfig2W {
	struct {
		struct policy_handle *handle;/* [ref] */
		uint32_t info_level;
		uint8_t *info;/* [unique] */
	} in;

	struct {
		WERROR result;
	} out;

};


struct svcctl_QueryServiceConfig2A {
	struct {
		struct policy_handle *handle;/* [ref] */
		enum svcctl_ConfigLevel info_level;
		uint32_t offered;
	} in;

	struct {
		uint8_t *buffer;
		uint32_t *needed;/* [ref] */
		WERROR result;
	} out;

};


struct svcctl_QueryServiceConfig2W {
	struct {
		struct policy_handle *handle;/* [ref] */
		enum svcctl_ConfigLevel info_level;
		uint32_t offered;/* [range(0,8192)] */
	} in;

	struct {
		uint8_t *buffer;/* [ref,size_is(offered)] */
		uint32_t *needed;/* [ref,range(0,8192)] */
		WERROR result;
	} out;

};


struct svcctl_QueryServiceStatusEx {
	struct {
		struct policy_handle *handle;/* [ref] */
		enum svcctl_StatusLevel info_level;
		uint32_t offered;/* [range(0,8192)] */
	} in;

	struct {
		uint8_t *buffer;/* [ref,size_is(offered)] */
		uint32_t *needed;/* [ref,range(0,8192)] */
		WERROR result;
	} out;

};


struct EnumServicesStatusExA {
	struct {
		struct policy_handle *scmanager;/* [ref] */
		uint32_t info_level;
		uint32_t type;
		enum svcctl_ServiceState state;
		uint32_t offered;
		uint32_t *resume_handle;/* [unique] */
	} in;

	struct {
		uint8_t *services;
		uint32_t *needed;/* [ref] */
		uint32_t *service_returned;/* [ref] */
		const char **group_name;/* [ref,charset(UTF16)] */
		uint32_t *resume_handle;/* [unique] */
		WERROR result;
	} out;

};


struct EnumServicesStatusExW {
	struct {
		struct policy_handle *scmanager;/* [ref] */
		uint32_t info_level;
		uint32_t type;
		enum svcctl_ServiceState state;
		uint32_t offered;/* [range(0,0x40000)] */
		const char *group_name;/* [unique,charset(UTF16)] */
		uint32_t *resume_handle;/* [unique,range(0,0x40000)] */
	} in;

	struct {
		uint8_t *services;/* [ref,size_is(offered)] */
		uint32_t *needed;/* [ref,range(0,0x40000)] */
		uint32_t *service_returned;/* [ref,range(0,0x40000)] */
		uint32_t *resume_handle;/* [unique,range(0,0x40000)] */
		WERROR result;
	} out;

};


struct svcctl_SCSendTSMessage {
	struct {
		WERROR result;
	} out;

};

#endif /* _HEADER_svcctl */