1 /* header auto-generated by pidl */
5 #include "libcli/util/ntstatus.h"
7 #include "librpc/gen_ndr/lsa.h"
8 #include "librpc/gen_ndr/security.h"
9 #include "librpc/gen_ndr/misc.h"
10 #ifndef _HEADER_winreg
11 #define _HEADER_winreg
13 #define REG_KEY_READ ( (STANDARD_RIGHTS_READ_ACCESS|KEY_QUERY_VALUE|KEY_ENUMERATE_SUB_KEYS|KEY_NOTIFY) )
14 #define REG_KEY_EXECUTE ( REG_KEY_READ )
15 #define REG_KEY_WRITE ( (STANDARD_RIGHTS_WRITE_ACCESS|KEY_SET_VALUE|KEY_CREATE_SUB_KEY) )
16 #define REG_KEY_ALL ( (STANDARD_RIGHTS_REQUIRED_ACCESS|REG_KEY_READ|REG_KEY_WRITE|KEY_CREATE_LINK) )
17 #define REG_OPTION_NON_VOLATILE ( 0x00000000 )
18 /* bitmap winreg_AccessMask */
19 #define KEY_QUERY_VALUE ( 0x00001 )
20 #define KEY_SET_VALUE ( 0x00002 )
21 #define KEY_CREATE_SUB_KEY ( 0x00004 )
22 #define KEY_ENUMERATE_SUB_KEYS ( 0x00008 )
23 #define KEY_NOTIFY ( 0x00010 )
24 #define KEY_CREATE_LINK ( 0x00020 )
25 #define KEY_WOW64_64KEY ( 0x00100 )
26 #define KEY_WOW64_32KEY ( 0x00200 )
28 struct winreg_String
{
29 uint16_t name_len
;/* [value(strlen_m_term(name)*2)] */
30 uint16_t name_size
;/* [value(strlen_m_term(name)*2)] */
31 const char *name
;/* [unique,charset(UTF16)] */
34 struct KeySecurityData
{
35 uint8_t *data
;/* [unique,length_is(len),size_is(size)] */
40 struct winreg_SecBuf
{
42 struct KeySecurityData sd
;
46 /* bitmap winreg_KeyOptions */
47 #define REG_OPTION_VOLATILE ( 0x00000001 )
48 #define REG_OPTION_CREATE_LINK ( 0x00000002 )
49 #define REG_OPTION_BACKUP_RESTORE ( 0x00000004 )
50 #define REG_OPTION_OPEN_LINK ( 0x00000008 )
52 enum winreg_CreateAction
53 #ifndef USE_UINT_ENUMS
55 REG_ACTION_NONE
=(int)(0),
56 REG_CREATED_NEW_KEY
=(int)(1),
57 REG_OPENED_EXISTING_KEY
=(int)(2)
60 { __donnot_use_enum_winreg_CreateAction
=0x7FFFFFFF}
61 #define REG_ACTION_NONE ( 0 )
62 #define REG_CREATED_NEW_KEY ( 1 )
63 #define REG_OPENED_EXISTING_KEY ( 2 )
67 struct winreg_StringBuf
{
68 uint16_t length
;/* [value(strlen_m_term_null(name)*2)] */
70 const char *name
;/* [unique,length_is(length/2),charset(UTF16),size_is(size/2)] */
73 struct winreg_ValNameBuf
{
74 uint16_t length
;/* [value(strlen_m_term(name)*2)] */
76 const char *name
;/* [unique,length_is(length/2),charset(UTF16),size_is(size/2)] */
79 /* bitmap winreg_NotifyChangeType */
80 #define REG_NOTIFY_CHANGE_NAME ( 0x00000001 )
81 #define REG_NOTIFY_CHANGE_ATTRIBUTES ( 0x00000002 )
82 #define REG_NOTIFY_CHANGE_LAST_SET ( 0x00000004 )
83 #define REG_NOTIFY_CHANGE_SECURITY ( 0x00000008 )
85 struct KeySecurityAttribute
{
87 struct KeySecurityData sec_data
;
91 struct QueryMultipleValue
{
92 struct winreg_String
*name
;/* [unique] */
93 enum winreg_Type type
;
99 struct winreg_OpenHKCR
{
101 uint16_t *system_name
;/* [unique] */
102 uint32_t access_mask
;
106 struct policy_handle
*handle
;/* [ref] */
113 struct winreg_OpenHKCU
{
115 uint16_t *system_name
;/* [unique] */
116 uint32_t access_mask
;
120 struct policy_handle
*handle
;/* [ref] */
127 struct winreg_OpenHKLM
{
129 uint16_t *system_name
;/* [unique] */
130 uint32_t access_mask
;
134 struct policy_handle
*handle
;/* [ref] */
141 struct winreg_OpenHKPD
{
143 uint16_t *system_name
;/* [unique] */
144 uint32_t access_mask
;
148 struct policy_handle
*handle
;/* [ref] */
155 struct winreg_OpenHKU
{
157 uint16_t *system_name
;/* [unique] */
158 uint32_t access_mask
;
162 struct policy_handle
*handle
;/* [ref] */
169 struct winreg_CloseKey
{
171 struct policy_handle
*handle
;/* [ref] */
175 struct policy_handle
*handle
;/* [ref] */
182 struct winreg_CreateKey
{
184 struct policy_handle
*handle
;/* [ref] */
185 struct winreg_String name
;
186 struct winreg_String keyclass
;
188 uint32_t access_mask
;
189 struct winreg_SecBuf
*secdesc
;/* [unique] */
190 enum winreg_CreateAction
*action_taken
;/* [unique] */
194 struct policy_handle
*new_handle
;/* [ref] */
195 enum winreg_CreateAction
*action_taken
;/* [unique] */
202 struct winreg_DeleteKey
{
204 struct policy_handle
*handle
;/* [ref] */
205 struct winreg_String key
;
215 struct winreg_DeleteValue
{
217 struct policy_handle
*handle
;/* [ref] */
218 struct winreg_String value
;
228 struct winreg_EnumKey
{
230 struct policy_handle
*handle
;/* [ref] */
232 struct winreg_StringBuf
*name
;/* [ref] */
233 struct winreg_StringBuf
*keyclass
;/* [unique] */
234 NTTIME
*last_changed_time
;/* [unique] */
238 struct winreg_StringBuf
*name
;/* [ref] */
239 struct winreg_StringBuf
*keyclass
;/* [unique] */
240 NTTIME
*last_changed_time
;/* [unique] */
247 struct winreg_EnumValue
{
249 struct policy_handle
*handle
;/* [ref] */
251 struct winreg_ValNameBuf
*name
;/* [ref] */
252 enum winreg_Type
*type
;/* [unique] */
253 uint8_t *value
;/* [unique,length_is(*length),size_is(*size)] */
254 uint32_t *size
;/* [unique] */
255 uint32_t *length
;/* [unique] */
259 struct winreg_ValNameBuf
*name
;/* [ref] */
260 enum winreg_Type
*type
;/* [unique] */
261 uint8_t *value
;/* [unique,length_is(*length),size_is(*size)] */
262 uint32_t *size
;/* [unique] */
263 uint32_t *length
;/* [unique] */
270 struct winreg_FlushKey
{
272 struct policy_handle
*handle
;/* [ref] */
282 struct winreg_GetKeySecurity
{
284 struct policy_handle
*handle
;/* [ref] */
286 struct KeySecurityData
*sd
;/* [ref] */
290 struct KeySecurityData
*sd
;/* [ref] */
297 struct winreg_LoadKey
{
299 struct policy_handle
*handle
;/* [ref] */
300 struct winreg_String
*keyname
;/* [unique] */
301 struct winreg_String
*filename
;/* [unique] */
311 struct winreg_NotifyChangeKeyValue
{
313 struct policy_handle
*handle
;/* [ref] */
314 uint8_t watch_subtree
;
315 uint32_t notify_filter
;
317 struct winreg_String string1
;
318 struct winreg_String string2
;
329 struct winreg_OpenKey
{
331 struct policy_handle
*parent_handle
;/* [ref] */
332 struct winreg_String keyname
;
334 uint32_t access_mask
;
338 struct policy_handle
*handle
;/* [ref] */
345 struct winreg_QueryInfoKey
{
347 struct policy_handle
*handle
;/* [ref] */
348 struct winreg_String
*classname
;/* [ref] */
352 uint32_t *num_subkeys
;/* [ref] */
353 uint32_t *max_subkeylen
;/* [ref] */
354 uint32_t *max_classlen
;/* [ref] */
355 uint32_t *num_values
;/* [ref] */
356 uint32_t *max_valnamelen
;/* [ref] */
357 uint32_t *max_valbufsize
;/* [ref] */
358 uint32_t *secdescsize
;/* [ref] */
359 NTTIME
*last_changed_time
;/* [ref] */
360 struct winreg_String
*classname
;/* [ref] */
367 struct winreg_QueryValue
{
369 struct policy_handle
*handle
;/* [ref] */
370 struct winreg_String
*value_name
;/* [ref] */
371 enum winreg_Type
*type
;/* [unique] */
372 uint8_t *data
;/* [unique,range(0,0x4000000),length_is(data_length?*data_length:0),size_is(data_size?*data_size:0)] */
373 uint32_t *data_size
;/* [unique] */
374 uint32_t *data_length
;/* [unique] */
378 enum winreg_Type
*type
;/* [unique] */
379 uint8_t *data
;/* [unique,range(0,0x4000000),length_is(data_length?*data_length:0),size_is(data_size?*data_size:0)] */
380 uint32_t *data_size
;/* [unique] */
381 uint32_t *data_length
;/* [unique] */
388 struct winreg_ReplaceKey
{
390 struct policy_handle
*handle
;/* [ref] */
391 struct winreg_String
*subkey
;/* [ref] */
392 struct winreg_String
*new_file
;/* [ref] */
393 struct winreg_String
*old_file
;/* [ref] */
403 struct winreg_RestoreKey
{
405 struct policy_handle
*handle
;/* [ref] */
406 struct winreg_String
*filename
;/* [ref] */
417 struct winreg_SaveKey
{
419 struct policy_handle
*handle
;/* [ref] */
420 struct winreg_String
*filename
;/* [ref] */
421 struct KeySecurityAttribute
*sec_attrib
;/* [unique] */
431 struct winreg_SetKeySecurity
{
433 struct policy_handle
*handle
;/* [ref] */
435 struct KeySecurityData
*sd
;/* [ref] */
445 struct winreg_SetValue
{
447 struct policy_handle
*handle
;/* [ref] */
448 struct winreg_String name
;
449 enum winreg_Type type
;
450 uint8_t *data
;/* [ref,size_is(size)] */
461 struct winreg_UnLoadKey
{
463 struct policy_handle
*handle
;/* [ref] */
464 struct winreg_String
*subkey
;/* [ref] */
474 struct winreg_InitiateSystemShutdown
{
476 uint16_t *hostname
;/* [unique] */
477 struct lsa_StringLarge
*message
;/* [unique] */
490 struct winreg_AbortSystemShutdown
{
492 uint16_t *server
;/* [unique] */
502 struct winreg_GetVersion
{
504 struct policy_handle
*handle
;/* [ref] */
508 uint32_t *version
;/* [ref] */
515 struct winreg_OpenHKCC
{
517 uint16_t *system_name
;/* [unique] */
518 uint32_t access_mask
;
522 struct policy_handle
*handle
;/* [ref] */
529 struct winreg_OpenHKDD
{
531 uint16_t *system_name
;/* [unique] */
532 uint32_t access_mask
;
536 struct policy_handle
*handle
;/* [ref] */
543 struct winreg_QueryMultipleValues
{
545 struct policy_handle
*key_handle
;/* [ref] */
547 struct QueryMultipleValue
*values
;/* [ref,length_is(num_values),size_is(num_values)] */
548 uint8_t *buffer
;/* [unique,length_is(*buffer_size),size_is(*buffer_size)] */
549 uint32_t *buffer_size
;/* [ref] */
553 struct QueryMultipleValue
*values
;/* [ref,length_is(num_values),size_is(num_values)] */
554 uint8_t *buffer
;/* [unique,length_is(*buffer_size),size_is(*buffer_size)] */
555 uint32_t *buffer_size
;/* [ref] */
562 struct winreg_InitiateSystemShutdownEx
{
564 uint16_t *hostname
;/* [unique] */
565 struct lsa_StringLarge
*message
;/* [unique] */
579 struct winreg_SaveKeyEx
{
581 struct policy_handle
*handle
;/* [ref] */
582 struct winreg_String
*filename
;/* [ref] */
583 struct KeySecurityAttribute
*sec_attrib
;/* [unique] */
594 struct winreg_OpenHKPT
{
596 uint16_t *system_name
;/* [unique] */
597 uint32_t access_mask
;
601 struct policy_handle
*handle
;/* [ref] */
608 struct winreg_OpenHKPN
{
610 uint16_t *system_name
;/* [unique] */
611 uint32_t access_mask
;
615 struct policy_handle
*handle
;/* [ref] */
622 struct winreg_QueryMultipleValues2
{
624 struct policy_handle
*key_handle
;/* [ref] */
627 struct QueryMultipleValue
*values
;/* [ref,length_is(num_values),size_is(num_values)] */
628 uint8_t *buffer
;/* [unique,length_is(offered),size_is(offered)] */
632 uint32_t *needed
;/* [ref] */
633 struct QueryMultipleValue
*values
;/* [ref,length_is(num_values),size_is(num_values)] */
634 uint8_t *buffer
;/* [unique,length_is(offered),size_is(offered)] */
641 struct winreg_DeleteKeyEx
{
643 struct policy_handle
*handle
;/* [ref] */
644 struct winreg_String
*key
;/* [ref] */
645 uint32_t access_mask
;
655 #endif /* _HEADER_winreg */