summaryrefslogtreecommitdiff
path: root/source3/librpc/gen_ndr/winreg.h
blob: 87ba27e623756272d1a0803e319a50ba6c19346a (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
/* header auto-generated by pidl */

#include "librpc/gen_ndr/lsa.h"
#include "librpc/gen_ndr/initshutdown.h"
#include "librpc/gen_ndr/security.h"
#ifndef _HEADER_winreg
#define _HEADER_winreg

/* bitmap winreg_AccessMask */

enum winreg_Type {
	REG_NONE=0,
	REG_SZ=1,
	REG_EXPAND_SZ=2,
	REG_BINARY=3,
	REG_DWORD=4,
	REG_DWORD_BIG_ENDIAN=5,
	REG_LINK=6,
	REG_MULTI_SZ=7,
	REG_RESOURCE_LIST=8,
	REG_FULL_RESOURCE_DESCRIPTOR=9,
	REG_RESOURCE_REQUIREMENTS_LIST=10,
	REG_QWORD=11
};

struct winreg_String {
	uint16_t name_len;/* [value(strlen_m_term(name)*2)] */
	uint16_t name_size;/* [value(strlen_m_term(name)*2)] */
	const char *name;/* [unique,charset(UTF16)] */
}/* [public,noejs] */;

struct KeySecurityData {
	uint8_t *data;/* [unique,length_is(len),size_is(size)] */
	uint32_t size;
	uint32_t len;
};

struct winreg_SecBuf {
	uint32_t length;
	struct KeySecurityData sd;
	uint8_t inherit;
};

enum winreg_CreateAction {
	REG_ACTION_NONE=0,
	REG_CREATED_NEW_KEY=1,
	REG_OPENED_EXISTING_KEY=2
};

struct winreg_StringBuf {
	uint16_t length;/* [value(strlen_m_term_null(name)*2)] */
	uint16_t size;
	const char *name;/* [unique,length_is(length/2),charset(UTF16),size_is(size/2)] */
};

struct KeySecurityAttribute {
	uint32_t data_size;
	struct KeySecurityData sec_data;
	uint8_t inherit;
};

struct QueryMultipleValue {
	struct winreg_String *name;/* [unique] */
	enum winreg_Type type;
	uint32_t offset;
	uint32_t length;
};


struct winreg_OpenHKCR {
	struct {
		uint16_t *system_name;/* [unique] */
		uint32_t access_mask;
	} in;

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

};


struct winreg_OpenHKCU {
	struct {
		uint16_t *system_name;/* [unique] */
		uint32_t access_mask;
	} in;

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

};


struct winreg_OpenHKLM {
	struct {
		uint16_t *system_name;/* [unique] */
		uint32_t access_mask;
	} in;

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

};


struct winreg_OpenHKPD {
	struct {
		uint16_t *system_name;/* [unique] */
		uint32_t access_mask;
	} in;

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

};


struct winreg_OpenHKU {
	struct {
		uint16_t *system_name;/* [unique] */
		uint32_t access_mask;
	} in;

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

};


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

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

};


struct winreg_CreateKey {
	struct {
		struct policy_handle *handle;/* [ref] */
		struct winreg_String name;
		struct winreg_String keyclass;
		uint32_t options;
		uint32_t access_mask;
		struct winreg_SecBuf *secdesc;/* [unique] */
		enum winreg_CreateAction *action_taken;/* [unique] */
	} in;

	struct {
		struct policy_handle *new_handle;/* [ref] */
		enum winreg_CreateAction *action_taken;/* [unique] */
		WERROR result;
	} out;

};


struct winreg_DeleteKey {
	struct {
		struct policy_handle *handle;/* [ref] */
		struct winreg_String key;
	} in;

	struct {
		WERROR result;
	} out;

};


struct winreg_DeleteValue {
	struct {
		struct policy_handle *handle;/* [ref] */
		struct winreg_String value;
	} in;

	struct {
		WERROR result;
	} out;

};


struct winreg_EnumKey {
	struct {
		struct policy_handle *handle;/* [ref] */
		uint32_t enum_index;
		struct winreg_StringBuf *name;/* [ref] */
		struct winreg_StringBuf *keyclass;/* [unique] */
		NTTIME *last_changed_time;/* [unique] */
	} in;

	struct {
		struct winreg_StringBuf *name;/* [ref] */
		struct winreg_StringBuf *keyclass;/* [unique] */
		NTTIME *last_changed_time;/* [unique] */
		WERROR result;
	} out;

};


struct winreg_EnumValue {
	struct {
		struct policy_handle *handle;/* [ref] */
		uint32_t enum_index;
		struct winreg_StringBuf *name;/* [ref] */
		enum winreg_Type *type;/* [unique] */
		uint8_t *data;/* [unique,length_is(*value_length),size_is(*data_size)] */
		uint32_t *data_size;/* [unique] */
		uint32_t *value_length;/* [unique] */
	} in;

	struct {
		struct winreg_StringBuf *name;/* [ref] */
		enum winreg_Type *type;/* [unique] */
		uint8_t *data;/* [unique,length_is(*value_length),size_is(*data_size)] */
		uint32_t *data_size;/* [unique] */
		uint32_t *value_length;/* [unique] */
		WERROR result;
	} out;

};


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

	struct {
		WERROR result;
	} out;

};


struct winreg_GetKeySecurity {
	struct {
		struct policy_handle *handle;/* [ref] */
		uint32_t sec_info;
		struct KeySecurityData *sd;/* [ref] */
	} in;

	struct {
		struct KeySecurityData *sd;/* [ref] */
		WERROR result;
	} out;

};


struct winreg_LoadKey {
	struct {
		struct policy_handle *handle;/* [ref] */
		struct winreg_String *keyname;/* [unique] */
		struct winreg_String *filename;/* [unique] */
	} in;

	struct {
		WERROR result;
	} out;

};


struct winreg_NotifyChangeKeyValue {
	struct {
		struct policy_handle *handle;/* [ref] */
		uint8_t watch_subtree;
		uint32_t notify_filter;
		uint32_t unknown;
		struct winreg_String string1;
		struct winreg_String string2;
		uint32_t unknown2;
	} in;

	struct {
		WERROR result;
	} out;

};


struct winreg_OpenKey {
	struct {
		struct policy_handle *parent_handle;/* [ref] */
		struct winreg_String keyname;
		uint32_t unknown;
		uint32_t access_mask;
	} in;

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

};


struct winreg_QueryInfoKey {
	struct {
		struct policy_handle *handle;/* [ref] */
		struct winreg_String *classname;/* [ref] */
	} in;

	struct {
		struct winreg_String *classname;/* [ref] */
		uint32_t *num_subkeys;/* [ref] */
		uint32_t *max_subkeylen;/* [ref] */
		uint32_t *max_classlen;/* [ref] */
		uint32_t *num_values;/* [ref] */
		uint32_t *max_valnamelen;/* [ref] */
		uint32_t *max_valbufsize;/* [ref] */
		uint32_t *secdescsize;/* [ref] */
		NTTIME *last_changed_time;/* [ref] */
		WERROR result;
	} out;

};


struct winreg_QueryValue {
	struct {
		struct policy_handle *handle;/* [ref] */
		struct winreg_String value_name;
		enum winreg_Type *type;/* [unique] */
		uint8_t *data;/* [unique,length_is(*value_length),size_is(*data_size)] */
		uint32_t *data_size;/* [unique] */
		uint32_t *value_length;/* [unique] */
	} in;

	struct {
		enum winreg_Type *type;/* [unique] */
		uint8_t *data;/* [unique,length_is(*value_length),size_is(*data_size)] */
		uint32_t *data_size;/* [unique] */
		uint32_t *value_length;/* [unique] */
		WERROR result;
	} out;

};


struct winreg_ReplaceKey {
	struct {
		WERROR result;
	} out;

};


struct winreg_RestoreKey {
	struct {
		struct policy_handle *handle;/* [ref] */
		struct winreg_String *filename;/* [ref] */
		uint32_t flags;
	} in;

	struct {
		WERROR result;
	} out;

};


struct winreg_SaveKey {
	struct {
		struct policy_handle *handle;/* [ref] */
		struct winreg_String *filename;/* [ref] */
		struct KeySecurityAttribute *sec_attrib;/* [unique] */
	} in;

	struct {
		WERROR result;
	} out;

};


struct winreg_SetKeySecurity {
	struct {
		struct policy_handle *handle;/* [ref] */
		uint32_t access_mask;
		struct KeySecurityData *sd;/* [ref] */
	} in;

	struct {
		struct KeySecurityData *sd;/* [ref] */
		WERROR result;
	} out;

};


struct winreg_SetValue {
	struct {
		struct policy_handle *handle;/* [ref] */
		struct winreg_String name;
		enum winreg_Type type;
		uint8_t *data;/* [ref,size_is(size)] */
		uint32_t size;
	} in;

	struct {
		WERROR result;
	} out;

};


struct winreg_UnLoadKey {
	struct {
		WERROR result;
	} out;

};


struct winreg_InitiateSystemShutdown {
	struct {
		uint16_t *hostname;/* [unique] */
		struct initshutdown_String *message;/* [unique] */
		uint32_t timeout;
		uint8_t force_apps;
		uint8_t reboot;
	} in;

	struct {
		WERROR result;
	} out;

};


struct winreg_AbortSystemShutdown {
	struct {
		uint16_t *server;/* [unique] */
	} in;

	struct {
		WERROR result;
	} out;

};


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

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

};


struct winreg_OpenHKCC {
	struct {
		uint16_t *system_name;/* [unique] */
		uint32_t access_mask;
	} in;

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

};


struct winreg_OpenHKDD {
	struct {
		uint16_t *system_name;/* [unique] */
		uint32_t access_mask;
	} in;

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

};


struct winreg_QueryMultipleValues {
	struct {
		struct policy_handle *key_handle;/* [ref] */
		struct QueryMultipleValue *values;/* [ref,length_is(num_values),size_is(num_values)] */
		uint32_t num_values;
		uint8_t *buffer;/* [unique,length_is(*buffer_size),size_is(*buffer_size)] */
		uint32_t *buffer_size;/* [ref] */
	} in;

	struct {
		struct QueryMultipleValue *values;/* [ref,length_is(num_values),size_is(num_values)] */
		uint8_t *buffer;/* [unique,length_is(*buffer_size),size_is(*buffer_size)] */
		uint32_t *buffer_size;/* [ref] */
		WERROR result;
	} out;

};


struct winreg_InitiateSystemShutdownEx {
	struct {
		uint16_t *hostname;/* [unique] */
		struct initshutdown_String *message;/* [unique] */
		uint32_t timeout;
		uint8_t force_apps;
		uint8_t reboot;
		uint32_t reason;
	} in;

	struct {
		WERROR result;
	} out;

};


struct winreg_SaveKeyEx {
	struct {
		WERROR result;
	} out;

};


struct winreg_OpenHKPT {
	struct {
		uint16_t *system_name;/* [unique] */
		uint32_t access_mask;
	} in;

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

};


struct winreg_OpenHKPN {
	struct {
		uint16_t *system_name;/* [unique] */
		uint32_t access_mask;
	} in;

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

};


struct winreg_QueryMultipleValues2 {
	struct {
		WERROR result;
	} out;

};

#endif /* _HEADER_winreg */