1 /* header auto-generated by pidl */
5 #include "librpc/gen_ndr/misc.h"
6 #include "librpc/gen_ndr/security.h"
10 #define SERVICE_TYPE_KERNEL_DRIVER ( 0x01 )
11 #define SERVICE_TYPE_FS_DRIVER ( 0x02 )
12 #define SERVICE_TYPE_ADAPTER ( 0x04 )
13 #define SERVICE_TYPE_RECOGNIZER_DRIVER ( 0x08 )
14 #define SERVICE_TYPE_DRIVER ( SERVICE_TYPE_KERNEL_DRIVER|SERVICE_TYPE_FS_DRIVER|SERVICE_TYPE_RECOGNIZER_DRIVER )
15 #define SERVICE_TYPE_WIN32_OWN_PROCESS ( 0x10 )
16 #define SERVICE_TYPE_WIN32_SHARE_PROCESS ( 0x20 )
17 #define SERVICE_TYPE_WIN32 ( SERVICE_TYPE_WIN32_OWN_PROCESS|SERVICE_TYPE_WIN32_SHARE_PROCESS )
18 #define SERVICE_STATE_ACTIVE ( 0x01 )
19 #define SERVICE_STATE_INACTIVE ( 0x02 )
20 #define SERVICE_STATE_ALL ( 0x03 )
21 #define SV_TYPE_ALL ( 0xFFFFFFFF )
22 #define SC_MANAGER_READ_ACCESS ( (SEC_STD_READ_CONTROL|SC_RIGHT_MGR_CONNECT|SC_RIGHT_MGR_ENUMERATE_SERVICE|SC_RIGHT_MGR_QUERY_LOCK_STATUS) )
23 #define SC_MANAGER_EXECUTE_ACCESS ( SC_MANAGER_READ_ACCESS )
24 #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) )
25 #define SC_MANAGER_ALL_ACCESS ( SC_MANAGER_WRITE_ACCESS )
26 #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) )
27 #define SERVICE_EXECUTE_ACCESS ( (SERVICE_READ_ACCESS|SC_RIGHT_SVC_START|SC_RIGHT_SVC_STOP|SC_RIGHT_SVC_PAUSE_CONTINUE) )
28 #define SERVICE_WRITE_ACCESS ( (SEC_STD_REQUIRED|SERVICE_READ_ACCESS|SERVICE_EXECUTE_ACCESS|SC_RIGHT_SVC_CHANGE_CONFIG) )
29 #define SERVICE_ALL_ACCESS ( SERVICE_WRITE_ACCESS )
30 struct SERVICE_LOCK_STATUS {
32 const char *lock_owner;/* [unique,charset(UTF16)] */
33 uint32_t lock_duration;
36 struct SERVICE_STATUS {
39 uint32_t controls_accepted;
40 WERROR win32_exit_code;
41 uint32_t service_exit_code;
46 struct ENUM_SERVICE_STATUS {
47 const char * service_name;/* [relative,flag(LIBNDR_FLAG_STR_ASCII|LIBNDR_FLAG_STR_NULLTERM)] */
48 const char * display_name;/* [relative,flag(LIBNDR_FLAG_STR_ASCII|LIBNDR_FLAG_STR_NULLTERM)] */
49 struct SERVICE_STATUS status;
52 /* bitmap svcctl_ServerType */
53 #define SV_TYPE_WORKSTATION ( 0x00000001 )
54 #define SV_TYPE_SERVER ( 0x00000002 )
55 #define SV_TYPE_SQLSERVER ( 0x00000004 )
56 #define SV_TYPE_DOMAIN_CTRL ( 0x00000008 )
57 #define SV_TYPE_DOMAIN_BAKCTRL ( 0x00000010 )
58 #define SV_TYPE_TIME_SOURCE ( 0x00000020 )
59 #define SV_TYPE_AFP ( 0x00000040 )
60 #define SV_TYPE_NOVELL ( 0x00000080 )
61 #define SV_TYPE_DOMAIN_MEMBER ( 0x00000100 )
62 #define SV_TYPE_PRINTQ_SERVER ( 0x00000200 )
63 #define SV_TYPE_DIALIN_SERVER ( 0x00000400 )
64 #define SV_TYPE_SERVER_UNIX ( 0x00000800 )
65 #define SV_TYPE_NT ( 0x00001000 )
66 #define SV_TYPE_WFW ( 0x00002000 )
67 #define SV_TYPE_SERVER_MFPN ( 0x00004000 )
68 #define SV_TYPE_SERVER_NT ( 0x00008000 )
69 #define SV_TYPE_POTENTIAL_BROWSER ( 0x00010000 )
70 #define SV_TYPE_BACKUP_BROWSER ( 0x00020000 )
71 #define SV_TYPE_MASTER_BROWSER ( 0x00040000 )
72 #define SV_TYPE_DOMAIN_MASTER ( 0x00080000 )
73 #define SV_TYPE_SERVER_OSF ( 0x00100000 )
74 #define SV_TYPE_SERVER_VMS ( 0x00200000 )
75 #define SV_TYPE_WIN95_PLUS ( 0x00400000 )
76 #define SV_TYPE_DFS_SERVER ( 0x00800000 )
77 #define SV_TYPE_ALTERNATE_XPORT ( 0x20000000 )
78 #define SV_TYPE_LOCAL_LIST_ONLY ( 0x40000000 )
79 #define SV_TYPE_DOMAIN_ENUM ( 0x80000000 )
82 #ifndef USE_UINT_ENUMS
84 SVCCTL_CONTROL_STOP=0x00000001,
85 SVCCTL_CONTROL_PAUSE=0x00000002,
86 SVCCTL_CONTROL_CONTINUE=0x00000003,
87 SVCCTL_CONTROL_INTERROGATE=0x00000004,
88 SVCCTL_CONTROL_SHUTDOWN=0x00000005
91 { __donnot_use_enum_SERVICE_CONTROL=0x7FFFFFFF}
92 #define SVCCTL_CONTROL_STOP ( 0x00000001 )
93 #define SVCCTL_CONTROL_PAUSE ( 0x00000002 )
94 #define SVCCTL_CONTROL_CONTINUE ( 0x00000003 )
95 #define SVCCTL_CONTROL_INTERROGATE ( 0x00000004 )
96 #define SVCCTL_CONTROL_SHUTDOWN ( 0x00000005 )
100 /* bitmap svcctl_MgrAccessMask */
101 #define SC_RIGHT_MGR_CONNECT ( 0x0001 )
102 #define SC_RIGHT_MGR_CREATE_SERVICE ( 0x0002 )
103 #define SC_RIGHT_MGR_ENUMERATE_SERVICE ( 0x0004 )
104 #define SC_RIGHT_MGR_LOCK ( 0x0008 )
105 #define SC_RIGHT_MGR_QUERY_LOCK_STATUS ( 0x0010 )
106 #define SC_RIGHT_MGR_MODIFY_BOOT_CONFIG ( 0x0020 )
108 /* bitmap svcctl_ServiceAccessMask */
109 #define SC_RIGHT_SVC_QUERY_CONFIG ( 0x0001 )
110 #define SC_RIGHT_SVC_CHANGE_CONFIG ( 0x0002 )
111 #define SC_RIGHT_SVC_QUERY_STATUS ( 0x0004 )
112 #define SC_RIGHT_SVC_ENUMERATE_DEPENDENTS ( 0x0008 )
113 #define SC_RIGHT_SVC_START ( 0x0010 )
114 #define SC_RIGHT_SVC_STOP ( 0x0020 )
115 #define SC_RIGHT_SVC_PAUSE_CONTINUE ( 0x0040 )
116 #define SC_RIGHT_SVC_INTERROGATE ( 0x0080 )
117 #define SC_RIGHT_SVC_USER_DEFINED_CONTROL ( 0x0100 )
119 struct QUERY_SERVICE_CONFIG {
120 uint32_t service_type;
122 uint32_t error_control;
123 const char *executablepath;/* [unique,range(0,8192),charset(UTF16)] */
124 const char *loadordergroup;/* [unique,range(0,8192),charset(UTF16)] */
126 const char *dependencies;/* [unique,range(0,8192),charset(UTF16)] */
127 const char *startname;/* [unique,range(0,8192),charset(UTF16)] */
128 const char *displayname;/* [unique,range(0,8192),charset(UTF16)] */
129 }/* [gensize,public] */;
132 struct svcctl_CloseServiceHandle {
134 struct policy_handle *handle;/* [ref] */
138 struct policy_handle *handle;/* [ref] */
145 struct svcctl_ControlService {
147 struct policy_handle *handle;/* [ref] */
148 enum SERVICE_CONTROL control;
152 struct SERVICE_STATUS *service_status;/* [ref] */
159 struct svcctl_DeleteService {
161 struct policy_handle *handle;/* [ref] */
171 struct svcctl_LockServiceDatabase {
173 struct policy_handle *handle;/* [ref] */
177 struct policy_handle *lock;/* [ref] */
184 struct svcctl_QueryServiceObjectSecurity {
186 struct policy_handle *handle;/* [ref] */
187 uint32_t security_flags;
188 uint32_t buffer_size;/* [range(0,0x40000)] */
192 uint8_t *buffer;/* [ref,size_is(buffer_size)] */
193 uint32_t *needed;/* [ref,range(0,0x40000)] */
200 struct svcctl_SetServiceObjectSecurity {
202 struct policy_handle *handle;/* [ref] */
203 uint32_t security_flags;
204 uint8_t *buffer;/* [ref,size_is(buffer_size)] */
205 uint32_t buffer_size;
215 struct svcctl_QueryServiceStatus {
217 struct policy_handle *handle;/* [ref] */
221 struct SERVICE_STATUS *service_status;/* [ref] */
228 struct svcctl_SetServiceStatus {
236 struct svcctl_UnlockServiceDatabase {
238 struct policy_handle *lock;/* [ref] */
242 struct policy_handle *lock;/* [ref] */
249 struct svcctl_NotifyBootConfigStatus {
257 struct svcctl_SCSetServiceBitsW {
259 struct policy_handle *handle;/* [ref] */
272 struct svcctl_ChangeServiceConfigW {
274 struct policy_handle *handle;/* [ref] */
278 const char *binary_path;/* [unique,charset(UTF16)] */
279 const char *load_order_group;/* [unique,charset(UTF16)] */
280 const char *dependencies;/* [unique,charset(UTF16)] */
281 const char *service_start_name;/* [unique,charset(UTF16)] */
282 const char *password;/* [unique,charset(UTF16)] */
283 const char *display_name;/* [unique,charset(UTF16)] */
287 uint32_t *tag_id;/* [ref] */
294 struct svcctl_CreateServiceW {
296 struct policy_handle *scmanager_handle;/* [ref] */
297 const char *ServiceName;/* [charset(UTF16)] */
298 const char *DisplayName;/* [unique,charset(UTF16)] */
299 uint32_t desired_access;
302 uint32_t error_control;
303 const char *binary_path;/* [charset(UTF16)] */
304 const char *LoadOrderGroupKey;/* [unique,charset(UTF16)] */
305 uint8_t *dependencies;/* [unique,size_is(dependencies_size)] */
306 uint32_t dependencies_size;
307 const char *service_start_name;/* [unique,charset(UTF16)] */
308 uint8_t *password;/* [unique,size_is(password_size)] */
309 uint32_t password_size;
310 uint32_t *TagId;/* [unique] */
314 struct policy_handle *handle;/* [ref] */
315 uint32_t *TagId;/* [unique] */
322 struct svcctl_EnumDependentServicesW {
324 struct policy_handle *service;/* [ref] */
326 uint32_t buf_size;/* [range(0,0x40000)] */
330 uint8_t *service_status;/* [ref,size_is(buf_size)] */
331 uint32_t *bytes_needed;/* [ref,range(0,0x40000)] */
332 uint32_t *services_returned;/* [ref,range(0,0x40000)] */
339 struct svcctl_EnumServicesStatusW {
341 struct policy_handle *handle;/* [ref] */
344 uint32_t buf_size;/* [range(0,262144)] */
345 uint32_t *resume_handle;/* [unique] */
349 uint8_t *service;/* [ref,size_is(buf_size)] */
350 uint32_t *bytes_needed;/* [ref,range(0,262144)] */
351 uint32_t *services_returned;/* [ref,range(0,262144)] */
352 uint32_t *resume_handle;/* [unique] */
359 struct svcctl_OpenSCManagerW {
361 const char *MachineName;/* [unique,charset(UTF16)] */
362 const char *DatabaseName;/* [unique,charset(UTF16)] */
363 uint32_t access_mask;
367 struct policy_handle *handle;/* [ref] */
374 struct svcctl_OpenServiceW {
376 struct policy_handle *scmanager_handle;/* [ref] */
377 const char *ServiceName;/* [charset(UTF16)] */
378 uint32_t access_mask;
382 struct policy_handle *handle;/* [ref] */
389 struct svcctl_QueryServiceConfigW {
391 struct policy_handle *handle;/* [ref] */
392 uint32_t buf_size;/* [range(0,8192)] */
396 struct QUERY_SERVICE_CONFIG *query;/* [ref] */
397 uint32_t *bytes_needed;/* [ref,range(0,8192)] */
404 struct svcctl_QueryServiceLockStatusW {
406 struct policy_handle *handle;/* [ref] */
411 struct SERVICE_LOCK_STATUS *lock_status;/* [ref] */
412 uint32_t *required_buf_size;/* [ref] */
419 struct svcctl_StartServiceW {
421 struct policy_handle *handle;/* [ref] */
423 const char *Arguments;/* [unique,charset(UTF16)] */
433 struct svcctl_GetServiceDisplayNameW {
435 struct policy_handle *handle;/* [ref] */
436 const char *service_name;/* [unique,charset(UTF16)] */
437 uint32_t *display_name_length;/* [unique] */
441 const char **display_name;/* [ref,charset(UTF16)] */
442 uint32_t *display_name_length;/* [unique] */
449 struct svcctl_GetServiceKeyNameW {
451 struct policy_handle *handle;/* [ref] */
452 const char *service_name;/* [unique,charset(UTF16)] */
453 uint32_t *display_name_length;/* [unique] */
457 const char **key_name;/* [ref,charset(UTF16)] */
458 uint32_t *display_name_length;/* [unique] */
465 struct svcctl_SCSetServiceBitsA {
467 struct policy_handle *handle;/* [ref] */
480 struct svcctl_ChangeServiceConfigA {
482 struct policy_handle *handle;/* [ref] */
486 const char *binary_path;/* [unique,charset(UTF16)] */
487 const char *load_order_group;/* [unique,charset(UTF16)] */
488 const char *dependencies;/* [unique,charset(UTF16)] */
489 const char *service_start_name;/* [unique,charset(UTF16)] */
490 const char *password;/* [unique,charset(UTF16)] */
491 const char *display_name;/* [unique,charset(UTF16)] */
495 uint32_t *tag_id;/* [ref] */
502 struct svcctl_CreateServiceA {
504 struct policy_handle *handle;/* [ref] */
505 const char *ServiceName;/* [unique,charset(UTF16)] */
506 const char *DisplayName;/* [unique,charset(UTF16)] */
507 uint32_t desired_access;
510 uint32_t error_control;
511 const char *binary_path;/* [unique,charset(UTF16)] */
512 const char *LoadOrderGroupKey;/* [unique,charset(UTF16)] */
513 const char *dependencies;/* [unique,charset(UTF16)] */
514 const char *service_start_name;/* [unique,charset(UTF16)] */
515 const char *password;/* [unique,charset(UTF16)] */
519 uint32_t *TagId;/* [unique] */
526 struct svcctl_EnumDependentServicesA {
528 struct policy_handle *service;/* [ref] */
534 struct ENUM_SERVICE_STATUS *service_status;/* [unique] */
535 uint32_t *bytes_needed;/* [ref] */
536 uint32_t *services_returned;/* [ref] */
543 struct svcctl_EnumServicesStatusA {
545 struct policy_handle *handle;/* [ref] */
549 uint32_t *resume_handle;/* [unique] */
553 uint8_t *service;/* [size_is(buf_size)] */
554 uint32_t *bytes_needed;/* [ref] */
555 uint32_t *services_returned;/* [ref] */
556 uint32_t *resume_handle;/* [unique] */
563 struct svcctl_OpenSCManagerA {
565 const char *MachineName;/* [unique,charset(UTF16)] */
566 const char *DatabaseName;/* [unique,charset(UTF16)] */
567 uint32_t access_mask;
571 struct policy_handle *handle;/* [ref] */
578 struct svcctl_OpenServiceA {
580 struct policy_handle *scmanager_handle;/* [ref] */
581 const char *ServiceName;/* [unique,charset(UTF16)] */
582 uint32_t access_mask;
592 struct svcctl_QueryServiceConfigA {
594 struct policy_handle *handle;/* [ref] */
600 uint32_t *bytes_needed;/* [ref] */
607 struct svcctl_QueryServiceLockStatusA {
609 struct policy_handle *handle;/* [ref] */
614 struct SERVICE_LOCK_STATUS *lock_status;/* [ref] */
615 uint32_t *required_buf_size;/* [ref] */
622 struct svcctl_StartServiceA {
624 struct policy_handle *handle;/* [ref] */
626 const char *Arguments;/* [unique,charset(UTF16)] */
636 struct svcctl_GetServiceDisplayNameA {
638 struct policy_handle *handle;/* [ref] */
639 const char *service_name;/* [unique,charset(UTF16)] */
640 uint32_t *display_name_length;/* [unique] */
644 const char **display_name;/* [ref,charset(UTF16)] */
645 uint32_t *display_name_length;/* [unique] */
652 struct svcctl_GetServiceKeyNameA {
654 struct policy_handle *handle;/* [ref] */
655 const char *service_name;/* [unique,charset(UTF16)] */
656 uint32_t *display_name_length;/* [unique] */
660 const char **key_name;/* [ref,charset(UTF16)] */
661 uint32_t *display_name_length;/* [unique] */
668 struct svcctl_GetCurrentGroupeStateW {
676 struct svcctl_EnumServiceGroupW {
684 struct svcctl_ChangeServiceConfig2A {
686 struct policy_handle *handle;/* [ref] */
688 uint8_t *info;/* [unique] */
698 struct svcctl_ChangeServiceConfig2W {
700 struct policy_handle *handle;/* [ref] */
702 uint8_t *info;/* [unique] */
712 struct svcctl_QueryServiceConfig2A {
714 struct policy_handle *handle;/* [ref] */
721 uint32_t *bytes_needed;/* [ref] */
728 struct svcctl_QueryServiceConfig2W {
730 struct policy_handle *handle;/* [ref] */
732 uint32_t buf_size;/* [range(0,8192)] */
736 uint8_t *buffer;/* [ref,size_is(buf_size)] */
737 uint32_t *bytes_needed;/* [ref,range(0,8192)] */
744 struct svcctl_QueryServiceStatusEx {
746 struct policy_handle *handle;/* [ref] */
748 uint32_t buf_size;/* [range(0,8192)] */
752 uint8_t *buffer;/* [ref,size_is(buf_size)] */
753 uint32_t *bytes_needed;/* [ref,range(0,8192)] */
760 struct EnumServicesStatusExA {
762 struct policy_handle *scmanager;/* [ref] */
767 uint32_t *resume_handle;/* [unique] */
772 uint32_t *bytes_needed;/* [ref] */
773 uint32_t *service_returned;/* [ref] */
774 const char **group_name;/* [ref,charset(UTF16)] */
775 uint32_t *resume_handle;/* [unique] */
782 struct EnumServicesStatusExW {
784 struct policy_handle *scmanager;/* [ref] */
788 uint32_t buf_size;/* [range(0,262144)] */
789 const char *group_name;/* [unique,charset(UTF16)] */
790 uint32_t *resume_handle;/* [unique,range(0,262144)] */
794 uint8_t *services;/* [ref,size_is(buf_size)] */
795 uint32_t *bytes_needed;/* [ref,range(0,262144)] */
796 uint32_t *service_returned;/* [ref,range(0,262144)] */
797 uint32_t *resume_handle;/* [unique,range(0,262144)] */
804 struct svcctl_SCSendTSMessage {
811 #endif /* _HEADER_svcctl */