summaryrefslogtreecommitdiff
path: root/librpc/idl/svcctl.idl
blob: 671a1dc47be21d33b9ca08b2239d45898ec5fe01 (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
#include "idl_types.h"

/*
  svcctl interface definitions
*/

import "misc.idl", "security.idl";
[ uuid("367abb81-9844-35f1-ad32-98f038001003"),
  version(2.0),
  pointer_default(unique),
  endpoint("ncacn_np:[\\pipe\\svcctl]", "ncalrpc:"),
  helper("../librpc/ndr/ndr_svcctl.h"),
  helpstring("Service Control")
] interface svcctl
{
	typedef struct {
		uint32 is_locked;
		[string,charset(UTF16)] uint16 *lock_owner;
		uint32 lock_duration;
	} SERVICE_LOCK_STATUS;

	typedef [v1_enum] enum {
		SVCCTL_STATE_UNKNOWN		= 0x00000000,	/* only used internally to smbd */
		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
	} svcctl_ServiceStatus;

	const int SVCCTL_ACCEPT_NONE			= 0x00000000;

	typedef [bitmap32bit] bitmap {
		SVCCTL_ACCEPT_STOP			= 0x00000001,
		SVCCTL_ACCEPT_PAUSE_CONTINUE		= 0x00000002,
		SVCCTL_ACCEPT_SHUTDOWN			= 0x00000004,
		SVCCTL_ACCEPT_PARAMCHANGE		= 0x00000008,
		SVCCTL_ACCEPT_NETBINDCHANGE		= 0x00000010,
		SVCCTL_ACCEPT_HARDWAREPROFILECHANGE	= 0x00000020,
		SVCCTL_ACCEPT_POWEREVENT		= 0x00000040
	} svcctl_ControlsAccepted;

	typedef struct {
		uint32 type;
		svcctl_ServiceStatus state;
		svcctl_ControlsAccepted controls_accepted;
		WERROR win32_exit_code;
		uint32 service_exit_code;
		uint32 check_point;
		uint32 wait_hint;
	} SERVICE_STATUS;

	typedef [public] struct {
		SERVICE_STATUS status;
		uint32 process_id;
		uint32 service_flags;
	} SERVICE_STATUS_PROCESS;

	typedef [public,gensize] struct {
		[relative] nstring *service_name;
		[relative] nstring *display_name;
		SERVICE_STATUS status;
	} ENUM_SERVICE_STATUSW;

	typedef [public,gensize] struct {
		[relative] astring *service_name;
		[relative] astring *display_name;
		SERVICE_STATUS status;
	} ENUM_SERVICE_STATUSA;

	const int SERVICE_TYPE_KERNEL_DRIVER       = 0x01;
	const int SERVICE_TYPE_FS_DRIVER           = 0x02;
	const int SERVICE_TYPE_ADAPTER             = 0x04;
	const int SERVICE_TYPE_RECOGNIZER_DRIVER   = 0x08;
	const int SERVICE_TYPE_DRIVER=SERVICE_TYPE_KERNEL_DRIVER|SERVICE_TYPE_FS_DRIVER|SERVICE_TYPE_RECOGNIZER_DRIVER;
	const int SERVICE_TYPE_WIN32_OWN_PROCESS   = 0x10;
	const int SERVICE_TYPE_WIN32_SHARE_PROCESS = 0x20;
	const int SERVICE_TYPE_WIN32=SERVICE_TYPE_WIN32_OWN_PROCESS|SERVICE_TYPE_WIN32_SHARE_PROCESS;
	const int SERVICE_TYPE_INTERACTIVE_PROCESS = 0x100;

	/*****************/
	/* Function 0x00 */
	WERROR svcctl_CloseServiceHandle(
		[in,out,ref] policy_handle *handle
	);

	/*****************/
	/* Function 0x01 */

	/* Service Controls */

	typedef [v1_enum] enum {
		SVCCTL_CONTROL_STOP		= 0x00000001,
		SVCCTL_CONTROL_PAUSE		= 0x00000002,
		SVCCTL_CONTROL_CONTINUE		= 0x00000003,
		SVCCTL_CONTROL_INTERROGATE	= 0x00000004,
		SVCCTL_CONTROL_SHUTDOWN		= 0x00000005
	} SERVICE_CONTROL;

	WERROR svcctl_ControlService(
		[in,ref] policy_handle *handle,
		[in] SERVICE_CONTROL control,
		[out,ref] SERVICE_STATUS *service_status
	);

	/*****************/
	/* Function 0x02 */
	WERROR svcctl_DeleteService(
		[in,ref] policy_handle *handle
	);

	/*****************/
	/* Function 0x03 */

	WERROR svcctl_LockServiceDatabase(
		[in,ref] policy_handle *handle,
		[out,ref] policy_handle *lock
	);

	/*****************/
	/* Function 0x04 */
	WERROR svcctl_QueryServiceObjectSecurity(
		[in] policy_handle *handle,
		[in] security_secinfo security_flags,
		[out,ref,size_is(offered)] uint8 *buffer,
		[in,range(0,0x40000)] uint32 offered,
		[out,ref,range(0,0x40000)] uint32 *needed
	);

	/*****************/
	/* Function 0x05 */
	WERROR svcctl_SetServiceObjectSecurity(
		[in] policy_handle *handle,
		[in] security_secinfo security_flags,
		[in,ref,size_is(offered)] uint8 *buffer,
		[in] uint32 offered
	);

	/*****************/
	/* Function 0x06 */
	WERROR svcctl_QueryServiceStatus(
		[in,ref] policy_handle *handle,
		[out,ref] SERVICE_STATUS *service_status
	);

	/*****************/
	/* Function 0x07 */
	[todo] WERROR svcctl_SetServiceStatus(
	);

	/*****************/
	/* Function 0x08 */
	WERROR svcctl_UnlockServiceDatabase(
		[in,out,ref] policy_handle *lock
	);

	/*****************/
	/* Function 0x09 */
	[todo] WERROR svcctl_NotifyBootConfigStatus(
	);

	/*****************/
	/* Function 0x0a */
	WERROR svcctl_SCSetServiceBitsW(
		[in,ref] policy_handle *handle,
		[in] uint32 bits,
		[in] boolean32 bitson,
		[in] boolean32 immediate
	);

	/*****************/
	/* Function 0x0b */

	typedef [v1_enum] enum {
		SVCCTL_SVC_ERROR_IGNORE		= 0x00000000,
		SVCCTL_SVC_ERROR_NORMAL		= 0x00000001,
		SVCCTL_SVC_ERROR_CRITICAL	= 0x00000002,
		SVCCTL_SVC_ERROR_SEVERE		= 0x00000003
	} svcctl_ErrorControl;

	typedef [v1_enum] enum {
		SVCCTL_BOOT_START		= 0x00000000,
		SVCCTL_SYSTEM_START		= 0x00000001,
		SVCCTL_AUTO_START		= 0x00000002,
		SVCCTL_DEMAND_START		= 0x00000003,
		SVCCTL_DISABLED			= 0x00000004
	} svcctl_StartType;

	WERROR svcctl_ChangeServiceConfigW(
		[in,ref] policy_handle *handle,
		[in] uint32 type,
		[in] svcctl_StartType start_type,
		[in] svcctl_ErrorControl error_control,
		[in,unique] [string,charset(UTF16)] uint16 *binary_path,
		[in,unique] [string,charset(UTF16)] uint16 *load_order_group,
		[out,ref] uint32 *tag_id,
		[in,unique] [string,charset(UTF16)] uint16 *dependencies,
		[in,unique] [string,charset(UTF16)] uint16 *service_start_name,
		[in,unique] [string,charset(UTF16)] uint16 *password,
		[in,unique] [string,charset(UTF16)] uint16 *display_name
	);

	/*****************/
	/* Function 0x0c */
	WERROR svcctl_CreateServiceW(
		[in,ref] policy_handle *scmanager_handle,
		[in] [string,charset(UTF16)] uint16 ServiceName[],
		[in,unique] [string,charset(UTF16)] uint16 *DisplayName,
		[in] uint32 desired_access,
		[in] uint32 type,
		[in] svcctl_StartType start_type,
		[in] svcctl_ErrorControl error_control,
		[in] [string,charset(UTF16)] uint16 binary_path[],
		[in,unique] [string,charset(UTF16)] uint16 *LoadOrderGroupKey,
		[in,out,unique] uint32 *TagId,
		[in,unique,size_is(dependencies_size)] uint8 *dependencies,
		[in] uint32 dependencies_size,
		[in,unique] [string,charset(UTF16)] uint16 *service_start_name,
		[in,unique,size_is(password_size)] uint8 *password,
		[in] uint32 password_size,
		[out,ref] policy_handle *handle
	);

	/*****************/
	/* Function 0x0d */
	WERROR svcctl_EnumDependentServicesW(
		[in,ref] policy_handle *service,
		[in] svcctl_ServiceState state,
		[out,ref,size_is(offered)] uint8 *service_status,
		[in,range(0,0x40000)] uint32 offered,
		[out,ref,range(0,0x40000)] uint32 *needed,
		[out,ref,range(0,0x40000)] uint32 *services_returned
	);

	/*****************/
	/* Function 0x0e */

	typedef [v1_enum] enum {
		SERVICE_STATE_ACTIVE	= 0x00000001,
		SERVICE_STATE_INACTIVE	= 0x00000002,
		SERVICE_STATE_ALL	= ( SERVICE_STATE_ACTIVE | SERVICE_STATE_INACTIVE )
	} svcctl_ServiceState;

	WERROR svcctl_EnumServicesStatusW(
		[in,ref] policy_handle *handle,
		[in] uint32 type,
		[in] svcctl_ServiceState state,
		[out,ref,size_is(offered)] uint8 *service,
		[in] [range(0,0x40000)] uint32 offered,
		[out,ref] [range(0,0x40000)] uint32 *needed,
		[out,ref] [range(0,0x40000)] uint32 *services_returned,
		[in,out,unique] uint32 *resume_handle
	);

	/*****************/
	/* Function 0x0f */

	/* Service Control Manager Bits */

	typedef [bitmap32bit] bitmap {
		SC_RIGHT_MGR_CONNECT		= 0x0001,
		SC_RIGHT_MGR_CREATE_SERVICE	= 0x0002,
		SC_RIGHT_MGR_ENUMERATE_SERVICE	= 0x0004,
		SC_RIGHT_MGR_LOCK		= 0x0008,
		SC_RIGHT_MGR_QUERY_LOCK_STATUS	= 0x0010,
		SC_RIGHT_MGR_MODIFY_BOOT_CONFIG	= 0x0020
	} svcctl_MgrAccessMask;

	const int SC_MANAGER_READ_ACCESS =
		(SEC_STD_READ_CONTROL			|
		 SC_RIGHT_MGR_CONNECT			|
		 SC_RIGHT_MGR_ENUMERATE_SERVICE		|
		 SC_RIGHT_MGR_QUERY_LOCK_STATUS);

	const int SC_MANAGER_EXECUTE_ACCESS = SC_MANAGER_READ_ACCESS;

	const int 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);

	const int SC_MANAGER_ALL_ACCESS = SC_MANAGER_WRITE_ACCESS;

	WERROR svcctl_OpenSCManagerW(
		[in,unique] [string,charset(UTF16)] uint16 *MachineName,
		[in,unique] [string,charset(UTF16)] uint16 *DatabaseName,
		[in] svcctl_MgrAccessMask access_mask,
		[out,ref] policy_handle *handle
	);

	/*****************/
	/* Function 0x10 */

	/* Service Object Bits */

	typedef [bitmap32bit] bitmap {
		SC_RIGHT_SVC_QUERY_CONFIG		= 0x0001,
		SC_RIGHT_SVC_CHANGE_CONFIG		= 0x0002,
		SC_RIGHT_SVC_QUERY_STATUS		= 0x0004,
		SC_RIGHT_SVC_ENUMERATE_DEPENDENTS	= 0x0008,
		SC_RIGHT_SVC_START			= 0x0010,
		SC_RIGHT_SVC_STOP			= 0x0020,
		SC_RIGHT_SVC_PAUSE_CONTINUE		= 0x0040,
		SC_RIGHT_SVC_INTERROGATE		= 0x0080,
		SC_RIGHT_SVC_USER_DEFINED_CONTROL	= 0x0100
	} svcctl_ServiceAccessMask;

	const int 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);

	const int SERVICE_EXECUTE_ACCESS =
		(SERVICE_READ_ACCESS 			|
		 SC_RIGHT_SVC_START			|
		 SC_RIGHT_SVC_STOP			|
		 SC_RIGHT_SVC_PAUSE_CONTINUE);

	const int SERVICE_WRITE_ACCESS =
		(SEC_STD_REQUIRED			|
		 SERVICE_READ_ACCESS			|
		 SERVICE_EXECUTE_ACCESS			|
		 SC_RIGHT_SVC_CHANGE_CONFIG);

	const int SERVICE_ALL_ACCESS = SERVICE_WRITE_ACCESS;

	WERROR svcctl_OpenServiceW(
		[in,ref] policy_handle *scmanager_handle,
		[in] [string,charset(UTF16)] uint16 ServiceName[],
		[in] svcctl_ServiceAccessMask access_mask,
		[out,ref] policy_handle *handle
	);

	/*****************/
	/* Function 0x11 */

	typedef [public,gensize] struct {
		uint32 service_type;
		svcctl_StartType start_type;
		svcctl_ErrorControl error_control;
		[string,charset(UTF16)] [range(0,8192)] uint16 *executablepath;
		[string,charset(UTF16)] [range(0,8192)] uint16 *loadordergroup;
		uint32 tag_id;
		[string,charset(UTF16)] [range(0,8192)] uint16 *dependencies;
		[string,charset(UTF16)] [range(0,8192)] uint16 *startname;
		[string,charset(UTF16)] [range(0,8192)] uint16 *displayname;
	} QUERY_SERVICE_CONFIG;

	WERROR svcctl_QueryServiceConfigW(
		[in,ref] policy_handle *handle,
		[out] QUERY_SERVICE_CONFIG *query,
		[in] [range(0,8192)] uint32 offered,
		[out,ref] [range(0,8192)] uint32 *needed
	);

	/*****************/
	/* Function 0x12 */
	WERROR svcctl_QueryServiceLockStatusW(
		[in,ref] policy_handle *handle,
		[in] uint32 offered,
		[out,ref] SERVICE_LOCK_STATUS *lock_status,
		[out,ref] uint32 *needed
	);

	/*****************/
	/* Function 0x13 */

	const int SC_MAX_ARGUMENT_LENGTH = 1024;
	const int SC_MAX_ARGUMENTS = 1024;

	typedef struct {
		[string,charset(UTF16),range(0,SC_MAX_ARGUMENT_LENGTH)] uint16 *string;
	} svcctl_ArgumentString;

	WERROR svcctl_StartServiceW(
		[in,ref] policy_handle *handle,
		[in,range(0,SC_MAX_ARGUMENTS)] uint32 NumArgs,
		[in,unique,size_is(NumArgs)] svcctl_ArgumentString *Arguments
	);

	/*****************/
	/* Function 0x14 */
	WERROR svcctl_GetServiceDisplayNameW(
		[in,ref] policy_handle *handle,
		[in,unique] [string,charset(UTF16)] uint16 *service_name,
		[out,ref] [string,charset(UTF16)] uint16 **display_name,
		[in,out,unique] uint32 *display_name_length
	);

	/*****************/
	/* Function 0x15 */
	WERROR svcctl_GetServiceKeyNameW(
		[in,ref] policy_handle *handle,
		[in,unique] [string,charset(UTF16)] uint16 *service_name,
		[out,ref] [string,charset(UTF16)] uint16 **key_name,
		[in,out,unique] uint32 *display_name_length
	);

	/*****************/
	/* Function 0x16 */
	WERROR svcctl_SCSetServiceBitsA(
		[in,ref] policy_handle *handle,
		[in] uint32 bits,
		[in] boolean32 bitson,
		[in] boolean32 immediate
	);

	/*****************/
	/* Function 0x17 */
	WERROR svcctl_ChangeServiceConfigA(
		[in,ref] policy_handle *handle,
		[in] uint32 type,
		[in] svcctl_StartType start_type,
		[in] svcctl_ErrorControl error_control,
		[in,unique] [string,charset(UTF16)] uint16 *binary_path,
		[in,unique] [string,charset(UTF16)] uint16 *load_order_group,
		[out,ref] uint32 *tag_id,
		[in,unique] [string,charset(UTF16)] uint16 *dependencies,
		[in,unique] [string,charset(UTF16)] uint16 *service_start_name,
		[in,unique] [string,charset(UTF16)] uint16 *password,
		[in,unique] [string,charset(UTF16)] uint16 *display_name
	);

	/*****************/
	/* Function 0x18 */
	WERROR svcctl_CreateServiceA(
		[in,ref] policy_handle *handle,
		[in,unique] [string,charset(UTF16)] uint16 *ServiceName,
		[in,unique] [string,charset(UTF16)] uint16 *DisplayName,
		[in] uint32 desired_access,
		[in] uint32 type,
		[in] svcctl_StartType start_type,
		[in] svcctl_ErrorControl error_control,
		[in,unique] [string,charset(UTF16)] uint16 *binary_path,
		[in,unique] [string,charset(UTF16)] uint16 *LoadOrderGroupKey,
		[out,unique] uint32 *TagId,
		[in,unique] [string,charset(UTF16)] uint16 *dependencies,
		[in,unique] [string,charset(UTF16)] uint16 *service_start_name,
		[in,unique] [string,charset(UTF16)] uint16 *password
	);

	/*****************/
	/* Function 0x19 */
	WERROR svcctl_EnumDependentServicesA(
		[in,ref] policy_handle *service,
		[in] svcctl_ServiceState state,
		[out,unique] ENUM_SERVICE_STATUSA *service_status,
		[in] uint32 offered,
		[out,ref] uint32 *needed,
		[out,ref] uint32 *services_returned
	);

	/*****************/
	/* Function 0x1a */
	WERROR svcctl_EnumServicesStatusA(
		[in,ref] policy_handle *handle,
		[in] uint32 type,
		[in] svcctl_ServiceState state,
		[in] uint32 offered,
		[out,size_is(offered)] uint8 service[*],
		[out,ref] uint32 *needed,
		[out,ref] uint32 *services_returned,
		[in,out,unique] uint32 *resume_handle
	);

	/*****************/
	/* Function 0x1b */
	WERROR svcctl_OpenSCManagerA(
		[in,unique] [string,charset(UTF16)] uint16 *MachineName,
		[in,unique] [string,charset(UTF16)] uint16 *DatabaseName,
		[in] uint32 access_mask,
		[out,ref] policy_handle *handle
	);

	/*****************/
	/* Function 0x1c */
	WERROR svcctl_OpenServiceA(
		[in,ref] policy_handle *scmanager_handle,
		[in,unique] [string,charset(UTF16)] uint16 *ServiceName,
		[in] uint32 access_mask,
		[out,ref] policy_handle *handle
	);

	/*****************/
	/* Function 0x1d */
	WERROR svcctl_QueryServiceConfigA(
		[in,ref] policy_handle *handle,
		[out] uint8 query[offered], /*QUERYU_SERVICE_CONFIG */
		[in] uint32 offered,
		[out,ref] uint32 *needed
	);

	/*****************/
	/* Function 0x1e */
	WERROR svcctl_QueryServiceLockStatusA(
		[in,ref] policy_handle *handle,
		[in] uint32 offered,
		[out,ref] SERVICE_LOCK_STATUS *lock_status,
		[out,ref] uint32 *needed
	);

	/*****************/
	/* Function 0x1f */
	WERROR svcctl_StartServiceA(
		[in,ref] policy_handle *handle,
		[in] uint32 NumArgs,
		[in,unique/*FIXME:,length_is(NumArgs)*/] [string,charset(UTF16)] uint16 *Arguments
	);

	/*****************/
	/* Function 0x20 */
	WERROR svcctl_GetServiceDisplayNameA(
		[in,ref] policy_handle *handle,
		[in,unique] [string,charset(UTF16)] uint16 *service_name,
		[out,ref] [string,charset(UTF16)] uint16 **display_name,
		[in,out,unique] uint32 *display_name_length
	);

	/*****************/
	/* Function 0x21 */
	WERROR svcctl_GetServiceKeyNameA(
		[in,ref] policy_handle *handle,
		[in,unique] [string,charset(UTF16)] uint16 *service_name,
		[out,ref] [string,charset(UTF16)] uint16 **key_name,
		[in,out,unique] uint32 *display_name_length
	);

	/*****************/
	/* Function 0x22 */
	[todo] WERROR svcctl_GetCurrentGroupeStateW(
	);

	/*****************/
	/* Function 0x23 */
	[todo] WERROR svcctl_EnumServiceGroupW(
	);

	/*****************/
	/* Function 0x24 */
	WERROR svcctl_ChangeServiceConfig2A(
		[in,ref] policy_handle *handle,
		[in] uint32 info_level,
		[in,unique] uint8 *info
	);

	/*****************/
	/* Function 0x25 */
	WERROR svcctl_ChangeServiceConfig2W(
		[in,ref] policy_handle *handle,
		[in] uint32 info_level,
		[in,unique] uint8 *info
	);

	/*****************/
	/* Function 0x26 */

	typedef [v1_enum] enum {
		SERVICE_CONFIG_DESCRIPTION	= 0x00000001,
		SERVICE_CONFIG_FAILURE_ACTIONS	= 0x00000002
	} svcctl_ConfigLevel;

	typedef [gensize,public] struct {
		[relative] nstring *description;
	} SERVICE_DESCRIPTION;

	typedef [v1_enum] enum {
		SC_ACTION_NONE		= 0,
		SC_ACTION_RESTART	= 1,
		SC_ACTION_REBOOT	= 2,
		SC_ACTION_RUN_COMMAND	= 3
	} SC_ACTION_TYPE;

	typedef struct {
		SC_ACTION_TYPE type;
		uint32 delay;
	} SC_ACTION;

	typedef [public,gensize] struct {
		uint32 reset_period;
		[relative] nstring *rebootmsg;
		[relative] nstring *command;
		[range(0,1024)] uint32 num_actions;
		[relative] [size_is(num_actions)] SC_ACTION *actions;
	} SERVICE_FAILURE_ACTIONS;

	WERROR svcctl_QueryServiceConfig2A(
		[in,ref] policy_handle *handle,
		[in] svcctl_ConfigLevel info_level,
		[out] uint8 buffer[offered],
		[in] uint32 offered,
		[out,ref] uint32 *needed
	);

	/*****************/
	/* Function 0x27 */
	WERROR svcctl_QueryServiceConfig2W(
		[in,ref] policy_handle *handle,
		[in] svcctl_ConfigLevel info_level,
		[out,ref,size_is(offered)] uint8 *buffer,
		[in] [range(0,8192)] uint32 offered,
		[out,ref] [range(0,8192)] uint32 *needed
	);

	/*****************/
	/* Function 0x28 */

	typedef [v1_enum] enum {
		SVC_STATUS_PROCESS_INFO		= 0x00000000
	} svcctl_StatusLevel;

	WERROR svcctl_QueryServiceStatusEx(
		[in,ref] policy_handle *handle,
		[in] svcctl_StatusLevel info_level,
		[out,ref,size_is(offered)] uint8 *buffer,
		[in] [range(0,8192)] uint32 offered,
		[out,ref] [range(0,8192)] uint32 *needed
	);

	/*****************/
	/* Function 0x29 */
	WERROR EnumServicesStatusExA(
		[in,ref] policy_handle *scmanager,
		[in] uint32 info_level,
		[in] uint32 type,
		[in] svcctl_ServiceState state,
		[out] uint8 services[offered],
		[in] uint32 offered,
		[out,ref] uint32 *needed,
		[out,ref] uint32 *service_returned,
		[in,out,unique] uint32 *resume_handle,
		[out,ref] [string,charset(UTF16)] uint16 **group_name
	);

	/*****************/
	/* Function 0x2a */
	WERROR EnumServicesStatusExW(
		[in,ref] policy_handle *scmanager,
		[in] uint32 info_level,
		[in] uint32 type,
		[in] svcctl_ServiceState state,
		[out,ref,size_is(offered)] uint8 *services,
		[in] [range(0,0x40000)] uint32 offered,
		[out,ref] [range(0,0x40000)] uint32 *needed,
		[out,ref] [range(0,0x40000)] uint32 *service_returned,
		[in,out,unique] [range(0,0x40000)] uint32 *resume_handle,
		[in,unique] [string,charset(UTF16)] uint16 *group_name
	);

	/*****************/
	/* Function 0x2b */
	[todo] WERROR svcctl_SCSendTSMessage(
	);
}