1 | /*
|
---|
2 | netlogon interface
|
---|
3 | much of this was derived from the ethereal sources - thanks to everyone
|
---|
4 | who contributed!
|
---|
5 | */
|
---|
6 |
|
---|
7 | import "lsa.idl", "samr.idl", "security.idl", "nbt.idl";
|
---|
8 |
|
---|
9 | #include "idl_types.h"
|
---|
10 |
|
---|
11 | [
|
---|
12 | uuid("12345678-1234-abcd-ef00-01234567cffb"),
|
---|
13 | version(1.0),
|
---|
14 | endpoint("ncacn_np:[\\pipe\\netlogon]","ncacn_ip_tcp:","ncalrpc:"),
|
---|
15 | pointer_default(unique)
|
---|
16 | ]
|
---|
17 |
|
---|
18 | interface netlogon
|
---|
19 | {
|
---|
20 | typedef bitmap samr_AcctFlags samr_AcctFlags;
|
---|
21 | typedef bitmap samr_GroupAttrs samr_GroupAttrs;
|
---|
22 |
|
---|
23 | /*****************/
|
---|
24 | /* Function 0x00 */
|
---|
25 |
|
---|
26 | typedef struct {
|
---|
27 | [string,charset(UTF16)] uint16 *account_name;
|
---|
28 | uint32 priv;
|
---|
29 | uint32 auth_flags;
|
---|
30 | uint32 logon_count;
|
---|
31 | uint32 bad_pw_count;
|
---|
32 | time_t last_logon;
|
---|
33 | time_t last_logoff;
|
---|
34 | time_t logoff_time;
|
---|
35 | time_t kickoff_time;
|
---|
36 | uint32 password_age;
|
---|
37 | time_t pw_can_change;
|
---|
38 | time_t pw_must_change;
|
---|
39 | [string,charset(UTF16)] uint16 *computer;
|
---|
40 | [string,charset(UTF16)] uint16 *domain;
|
---|
41 | [string,charset(UTF16)] uint16 *script_path;
|
---|
42 | uint32 unknown;
|
---|
43 | } netr_UasInfo;
|
---|
44 |
|
---|
45 | WERROR netr_LogonUasLogon(
|
---|
46 | [in,unique] [string,charset(UTF16)] uint16 *server_name,
|
---|
47 | [in] [string,charset(UTF16)] uint16 account_name[],
|
---|
48 | [in] [string,charset(UTF16)] uint16 workstation[],
|
---|
49 | [out,ref] netr_UasInfo *info
|
---|
50 | );
|
---|
51 |
|
---|
52 |
|
---|
53 | /*****************/
|
---|
54 | /* Function 0x01 */
|
---|
55 |
|
---|
56 | typedef struct {
|
---|
57 | uint32 duration;
|
---|
58 | uint16 logon_count;
|
---|
59 | } netr_UasLogoffInfo;
|
---|
60 |
|
---|
61 | WERROR netr_LogonUasLogoff(
|
---|
62 | [in,unique] [string,charset(UTF16)] uint16 *server_name,
|
---|
63 | [in] [string,charset(UTF16)] uint16 account_name[],
|
---|
64 | [in] [string,charset(UTF16)] uint16 workstation[],
|
---|
65 | [out,ref] netr_UasLogoffInfo *info
|
---|
66 | );
|
---|
67 |
|
---|
68 |
|
---|
69 | /*****************/
|
---|
70 | /* Function 0x02 */
|
---|
71 |
|
---|
72 | /* in netr_AcctLockStr size seems to be be 24, and rrenard thinks
|
---|
73 | that the structure of the bindata looks like this:
|
---|
74 |
|
---|
75 | dlong lockout_duration;
|
---|
76 | udlong reset_count;
|
---|
77 | uint32 bad_attempt_lockout;
|
---|
78 | uint32 dummy;
|
---|
79 |
|
---|
80 | but it doesn't look as though this structure is reflected at the
|
---|
81 | NDR level. Maybe it is left to the application to decode the bindata array.
|
---|
82 | */
|
---|
83 | typedef [public] struct {
|
---|
84 | dlong lockout_duration;
|
---|
85 | udlong reset_count;
|
---|
86 | uint32 bad_attempt_lockout;
|
---|
87 | uint32 dummy;
|
---|
88 | } netr_AcctLockStr;
|
---|
89 |
|
---|
90 | /* - MSV1_0_ALLOW_SERVER_TRUST_ACCOUNT
|
---|
91 | * sets the NETLOGON_SERVER_TRUST_ACCOUNT user_flag
|
---|
92 | * - MSV1_0_UPDATE_LOGON_STATISTICS
|
---|
93 | * sets the logon time on network logon
|
---|
94 | * - MSV1_0_RETURN_USER_PARAMETERS
|
---|
95 | * sets the user parameters in the driveletter
|
---|
96 | * - MSV1_0_RETURN_PROFILE_PATH
|
---|
97 | * returns the profilepath in the driveletter and
|
---|
98 | * sets LOGON_PROFILE_PATH_RETURNED user_flag
|
---|
99 | */
|
---|
100 |
|
---|
101 | typedef [public,bitmap32bit] bitmap {
|
---|
102 | MSV1_0_CLEARTEXT_PASSWORD_ALLOWED = 0x00000002,
|
---|
103 | MSV1_0_UPDATE_LOGON_STATISTICS = 0x00000004,
|
---|
104 | MSV1_0_RETURN_USER_PARAMETERS = 0x00000008,
|
---|
105 | MSV1_0_ALLOW_SERVER_TRUST_ACCOUNT = 0x00000020,
|
---|
106 | MSV1_0_RETURN_PROFILE_PATH = 0x00000200,
|
---|
107 | MSV1_0_ALLOW_WORKSTATION_TRUST_ACCOUNT = 0x00000800
|
---|
108 | } netr_LogonParameterControl;
|
---|
109 |
|
---|
110 | typedef struct {
|
---|
111 | lsa_String domain_name;
|
---|
112 | netr_LogonParameterControl parameter_control; /* see MSV1_0_* */
|
---|
113 | uint32 logon_id_low;
|
---|
114 | uint32 logon_id_high;
|
---|
115 | lsa_String account_name;
|
---|
116 | lsa_String workstation;
|
---|
117 | } netr_IdentityInfo;
|
---|
118 |
|
---|
119 | typedef struct {
|
---|
120 | netr_IdentityInfo identity_info;
|
---|
121 | samr_Password lmpassword;
|
---|
122 | samr_Password ntpassword;
|
---|
123 | } netr_PasswordInfo;
|
---|
124 |
|
---|
125 | typedef [flag(NDR_PAHEX)] struct {
|
---|
126 | uint16 length;
|
---|
127 | [value(length)] uint16 size;
|
---|
128 | [size_is(length),length_is(length)] uint8 *data;
|
---|
129 | } netr_ChallengeResponse;
|
---|
130 |
|
---|
131 | typedef [flag(NDR_PAHEX)] struct {
|
---|
132 | netr_IdentityInfo identity_info;
|
---|
133 | uint8 challenge[8];
|
---|
134 | netr_ChallengeResponse nt;
|
---|
135 | netr_ChallengeResponse lm;
|
---|
136 | } netr_NetworkInfo;
|
---|
137 |
|
---|
138 | typedef [public,switch_type(uint16)] union {
|
---|
139 | [case(1)] netr_PasswordInfo *password;
|
---|
140 | [case(2)] netr_NetworkInfo *network;
|
---|
141 | [case(3)] netr_PasswordInfo *password;
|
---|
142 | [case(5)] netr_PasswordInfo *password;
|
---|
143 | [case(6)] netr_NetworkInfo *network;
|
---|
144 | } netr_LogonInfo;
|
---|
145 |
|
---|
146 | typedef [public,flag(NDR_PAHEX)] struct {
|
---|
147 | uint8 key[16];
|
---|
148 | } netr_UserSessionKey;
|
---|
149 |
|
---|
150 | typedef [public,flag(NDR_PAHEX)] struct {
|
---|
151 | uint8 key[8];
|
---|
152 | } netr_LMSessionKey;
|
---|
153 |
|
---|
154 | /* Flags for user_flags below */
|
---|
155 | typedef [public,bitmap32bit] bitmap {
|
---|
156 | NETLOGON_GUEST = 0x00000001,
|
---|
157 | NETLOGON_NOENCRYPTION = 0x00000002,
|
---|
158 | NETLOGON_CACHED_ACCOUNT = 0x00000004,
|
---|
159 | NETLOGON_USED_LM_PASSWORD = 0x00000008,
|
---|
160 | NETLOGON_EXTRA_SIDS = 0x00000020,
|
---|
161 | NETLOGON_SUBAUTH_SESSION_KEY = 0x00000040,
|
---|
162 | NETLOGON_SERVER_TRUST_ACCOUNT = 0x00000080,
|
---|
163 | NETLOGON_NTLMV2_ENABLED = 0x00000100,
|
---|
164 | NETLOGON_RESOURCE_GROUPS = 0x00000200,
|
---|
165 | NETLOGON_PROFILE_PATH_RETURNED = 0x00000400,
|
---|
166 | NETLOGON_GRACE_LOGON = 0x01000000
|
---|
167 | } netr_UserFlags;
|
---|
168 |
|
---|
169 | typedef struct {
|
---|
170 | NTTIME last_logon;
|
---|
171 | NTTIME last_logoff;
|
---|
172 | NTTIME acct_expiry;
|
---|
173 | NTTIME last_password_change;
|
---|
174 | NTTIME allow_password_change;
|
---|
175 | NTTIME force_password_change;
|
---|
176 | lsa_String account_name;
|
---|
177 | lsa_String full_name;
|
---|
178 | lsa_String logon_script;
|
---|
179 | lsa_String profile_path;
|
---|
180 | lsa_String home_directory;
|
---|
181 | lsa_String home_drive;
|
---|
182 | uint16 logon_count;
|
---|
183 | uint16 bad_password_count;
|
---|
184 | uint32 rid;
|
---|
185 | uint32 primary_gid;
|
---|
186 | samr_RidWithAttributeArray groups;
|
---|
187 | netr_UserFlags user_flags;
|
---|
188 | netr_UserSessionKey key;
|
---|
189 | lsa_StringLarge logon_server;
|
---|
190 | lsa_StringLarge domain;
|
---|
191 | dom_sid2 *domain_sid;
|
---|
192 | netr_LMSessionKey LMSessKey;
|
---|
193 | samr_AcctFlags acct_flags;
|
---|
194 | uint32 unknown[7];
|
---|
195 | } netr_SamBaseInfo;
|
---|
196 |
|
---|
197 | typedef struct {
|
---|
198 | netr_SamBaseInfo base;
|
---|
199 | } netr_SamInfo2;
|
---|
200 |
|
---|
201 | typedef struct {
|
---|
202 | dom_sid2 *sid;
|
---|
203 | samr_GroupAttrs attributes;
|
---|
204 | } netr_SidAttr;
|
---|
205 |
|
---|
206 | typedef [public] struct {
|
---|
207 | netr_SamBaseInfo base;
|
---|
208 | uint32 sidcount;
|
---|
209 | [size_is(sidcount)] netr_SidAttr *sids;
|
---|
210 | } netr_SamInfo3;
|
---|
211 |
|
---|
212 | typedef struct {
|
---|
213 | netr_SamBaseInfo base;
|
---|
214 | uint32 sidcount;
|
---|
215 | [size_is(sidcount)] netr_SidAttr *sids;
|
---|
216 | lsa_String forest;
|
---|
217 | lsa_String principle;
|
---|
218 | uint32 unknown4[20];
|
---|
219 | } netr_SamInfo6;
|
---|
220 |
|
---|
221 | typedef struct {
|
---|
222 | uint32 pac_size;
|
---|
223 | [size_is(pac_size)] uint8 *pac;
|
---|
224 | lsa_String logon_domain;
|
---|
225 | lsa_String logon_server;
|
---|
226 | lsa_String principal_name;
|
---|
227 | uint32 auth_size;
|
---|
228 | [size_is(auth_size)] uint8 *auth;
|
---|
229 | netr_UserSessionKey user_session_key;
|
---|
230 | uint32 expansionroom[10];
|
---|
231 | lsa_String unknown1;
|
---|
232 | lsa_String unknown2;
|
---|
233 | lsa_String unknown3;
|
---|
234 | lsa_String unknown4;
|
---|
235 | } netr_PacInfo;
|
---|
236 |
|
---|
237 | typedef [public,switch_type(uint16)] union {
|
---|
238 | [case(2)] netr_SamInfo2 *sam2;
|
---|
239 | [case(3)] netr_SamInfo3 *sam3;
|
---|
240 | [case(4)] netr_PacInfo *pac;
|
---|
241 | [case(5)] netr_PacInfo *pac;
|
---|
242 | [case(6)] netr_SamInfo6 *sam6;
|
---|
243 | } netr_Validation;
|
---|
244 |
|
---|
245 | typedef [public, flag(NDR_PAHEX)] struct {
|
---|
246 | uint8 data[8];
|
---|
247 | } netr_Credential;
|
---|
248 |
|
---|
249 | typedef [public] struct {
|
---|
250 | netr_Credential cred;
|
---|
251 | time_t timestamp;
|
---|
252 | } netr_Authenticator;
|
---|
253 |
|
---|
254 | typedef enum {
|
---|
255 | INTERACTIVE_LOGON_TYPE = 1,
|
---|
256 | NET_LOGON_TYPE = 2
|
---|
257 | } netr_LogonLevel;
|
---|
258 |
|
---|
259 | NTSTATUS netr_LogonSamLogon(
|
---|
260 | [in,unique] [string,charset(UTF16)] uint16 *server_name,
|
---|
261 | [in,unique] [string,charset(UTF16)] uint16 *computer_name,
|
---|
262 | [in,unique] netr_Authenticator *credential,
|
---|
263 | [in,out,unique] netr_Authenticator *return_authenticator,
|
---|
264 | [in] netr_LogonLevel logon_level,
|
---|
265 | [in,ref] [switch_is(logon_level)] netr_LogonInfo *logon,
|
---|
266 | [in] uint16 validation_level,
|
---|
267 | [out,ref] [switch_is(validation_level)] netr_Validation *validation,
|
---|
268 | [out,ref] uint8 *authoritative
|
---|
269 | );
|
---|
270 |
|
---|
271 |
|
---|
272 | /*****************/
|
---|
273 | /* Function 0x03 */
|
---|
274 |
|
---|
275 | NTSTATUS netr_LogonSamLogoff(
|
---|
276 | [in,unique] [string,charset(UTF16)] uint16 *server_name,
|
---|
277 | [in,unique] [string,charset(UTF16)] uint16 *computer_name,
|
---|
278 | [in,unique] netr_Authenticator *credential,
|
---|
279 | [in,out,unique] netr_Authenticator *return_authenticator,
|
---|
280 | [in] netr_LogonLevel logon_level,
|
---|
281 | [in] [switch_is(logon_level)] netr_LogonInfo logon
|
---|
282 | );
|
---|
283 |
|
---|
284 |
|
---|
285 |
|
---|
286 | /*****************/
|
---|
287 | /* Function 0x04 */
|
---|
288 |
|
---|
289 | NTSTATUS netr_ServerReqChallenge(
|
---|
290 | [in,unique,string,charset(UTF16)] uint16 *server_name,
|
---|
291 | [in,string,charset(UTF16)] uint16 computer_name[],
|
---|
292 | [in,ref] netr_Credential *credentials,
|
---|
293 | [out,ref] netr_Credential *return_credentials
|
---|
294 | );
|
---|
295 |
|
---|
296 |
|
---|
297 | /*****************/
|
---|
298 | /* Function 0x05 */
|
---|
299 |
|
---|
300 | typedef enum netr_SchannelType netr_SchannelType;
|
---|
301 |
|
---|
302 | NTSTATUS netr_ServerAuthenticate(
|
---|
303 | [in,unique,string,charset(UTF16)] uint16 *server_name,
|
---|
304 | [in,string,charset(UTF16)] uint16 account_name[],
|
---|
305 | [in] netr_SchannelType secure_channel_type,
|
---|
306 | [in,string,charset(UTF16)] uint16 computer_name[],
|
---|
307 | [in,ref] netr_Credential *credentials,
|
---|
308 | [out,ref] netr_Credential *return_credentials
|
---|
309 | );
|
---|
310 |
|
---|
311 |
|
---|
312 | /*****************/
|
---|
313 | /* Function 0x06 */
|
---|
314 |
|
---|
315 | NTSTATUS netr_ServerPasswordSet(
|
---|
316 | [in,unique] [string,charset(UTF16)] uint16 *server_name,
|
---|
317 | [in] [string,charset(UTF16)] uint16 account_name[],
|
---|
318 | [in] netr_SchannelType secure_channel_type,
|
---|
319 | [in] [string,charset(UTF16)] uint16 computer_name[],
|
---|
320 | [in,ref] netr_Authenticator *credential,
|
---|
321 | [out,ref] netr_Authenticator *return_authenticator,
|
---|
322 | [in,ref] samr_Password *new_password
|
---|
323 | );
|
---|
324 |
|
---|
325 |
|
---|
326 | /*****************/
|
---|
327 | /* Function 0x07 */
|
---|
328 |
|
---|
329 | typedef enum netr_SamDatabaseID netr_SamDatabaseID;
|
---|
330 |
|
---|
331 | typedef struct {
|
---|
332 | [string,charset(UTF16)] uint16 *account_name;
|
---|
333 | lsa_String unknown1;
|
---|
334 | lsa_String unknown2;
|
---|
335 | lsa_String unknown3;
|
---|
336 | lsa_String unknown4;
|
---|
337 | uint32 unknown5;
|
---|
338 | uint32 unknown6;
|
---|
339 | uint32 unknown7;
|
---|
340 | uint32 unknown8;
|
---|
341 | } netr_DELTA_DELETE_USER;
|
---|
342 |
|
---|
343 | typedef struct {
|
---|
344 | uint16 length;
|
---|
345 | [value(length)] uint16 size;
|
---|
346 | uint32 flags;
|
---|
347 | samr_Password pwd;
|
---|
348 | } netr_USER_KEY16;
|
---|
349 |
|
---|
350 | typedef struct {
|
---|
351 | uint16 nt_length;
|
---|
352 | [value(nt_length)] uint16 nt_size;
|
---|
353 | uint32 nt_flags;
|
---|
354 | uint16 lm_length;
|
---|
355 | [value(lm_length)] uint16 lm_size;
|
---|
356 | uint32 lm_flags;
|
---|
357 | uint8 nt_history[nt_length];
|
---|
358 | uint8 lm_history[lm_length];
|
---|
359 | } netr_PasswordHistory;
|
---|
360 |
|
---|
361 | typedef struct {
|
---|
362 | netr_USER_KEY16 lmpassword;
|
---|
363 | netr_USER_KEY16 ntpassword;
|
---|
364 | netr_PasswordHistory history;
|
---|
365 | } netr_USER_KEYS2;
|
---|
366 |
|
---|
367 | typedef struct { /* TODO: make this a union! */
|
---|
368 | netr_USER_KEYS2 keys2;
|
---|
369 | } netr_USER_KEY_UNION;
|
---|
370 |
|
---|
371 | typedef [public] struct {
|
---|
372 | uint32 version;
|
---|
373 | netr_USER_KEY_UNION keys;
|
---|
374 | } netr_USER_KEYS;
|
---|
375 |
|
---|
376 | typedef struct {
|
---|
377 | boolean8 SensitiveDataFlag;
|
---|
378 | uint32 DataLength;
|
---|
379 |
|
---|
380 | /* netr_USER_KEYS encrypted with the session key */
|
---|
381 | [size_is(DataLength)][flag(NDR_PAHEX)] uint8 *SensitiveData;
|
---|
382 | } netr_USER_PRIVATE_INFO;
|
---|
383 |
|
---|
384 | typedef struct {
|
---|
385 | lsa_String account_name;
|
---|
386 | lsa_String full_name;
|
---|
387 | uint32 rid;
|
---|
388 | uint32 primary_gid;
|
---|
389 | lsa_String home_directory;
|
---|
390 | lsa_String home_drive;
|
---|
391 | lsa_String logon_script;
|
---|
392 | lsa_String description;
|
---|
393 | lsa_String workstations;
|
---|
394 | NTTIME last_logon;
|
---|
395 | NTTIME last_logoff;
|
---|
396 | samr_LogonHours logon_hours;
|
---|
397 | uint16 bad_password_count;
|
---|
398 | uint16 logon_count;
|
---|
399 | NTTIME last_password_change;
|
---|
400 | NTTIME acct_expiry;
|
---|
401 | samr_AcctFlags acct_flags;
|
---|
402 | samr_Password lmpassword;
|
---|
403 | samr_Password ntpassword;
|
---|
404 | boolean8 nt_password_present;
|
---|
405 | boolean8 lm_password_present;
|
---|
406 | boolean8 password_expired;
|
---|
407 | lsa_String comment;
|
---|
408 | lsa_String parameters;
|
---|
409 | uint16 country_code;
|
---|
410 | uint16 code_page;
|
---|
411 | netr_USER_PRIVATE_INFO user_private_info;
|
---|
412 | uint32 SecurityInformation;
|
---|
413 | sec_desc_buf sdbuf;
|
---|
414 | lsa_String profile_path;
|
---|
415 | lsa_String unknown2;
|
---|
416 | lsa_String unknown3;
|
---|
417 | lsa_String unknown4;
|
---|
418 | uint32 unknown5;
|
---|
419 | uint32 unknown6;
|
---|
420 | uint32 unknown7;
|
---|
421 | uint32 unknown8;
|
---|
422 | } netr_DELTA_USER;
|
---|
423 |
|
---|
424 | typedef struct {
|
---|
425 | lsa_String domain_name;
|
---|
426 | lsa_String comment;
|
---|
427 | dlong force_logoff_time;
|
---|
428 | uint16 min_password_length;
|
---|
429 | uint16 password_history_length;
|
---|
430 | /* yes, these are signed. They are in negative 100ns */
|
---|
431 | dlong max_password_age;
|
---|
432 | dlong min_password_age;
|
---|
433 | udlong sequence_num;
|
---|
434 | NTTIME domain_create_time;
|
---|
435 | uint32 SecurityInformation;
|
---|
436 | sec_desc_buf sdbuf;
|
---|
437 | lsa_BinaryString account_lockout;
|
---|
438 | lsa_String unknown2;
|
---|
439 | lsa_String unknown3;
|
---|
440 | lsa_String unknown4;
|
---|
441 | uint32 logon_to_chgpass;
|
---|
442 | uint32 unknown6;
|
---|
443 | uint32 unknown7;
|
---|
444 | uint32 unknown8;
|
---|
445 | } netr_DELTA_DOMAIN;
|
---|
446 |
|
---|
447 | typedef struct {
|
---|
448 | lsa_String group_name;
|
---|
449 | uint32 rid;
|
---|
450 | uint32 attributes;
|
---|
451 | lsa_String description;
|
---|
452 | uint32 SecurityInformation;
|
---|
453 | sec_desc_buf sdbuf;
|
---|
454 | lsa_String unknown1;
|
---|
455 | lsa_String unknown2;
|
---|
456 | lsa_String unknown3;
|
---|
457 | lsa_String unknown4;
|
---|
458 | uint32 unknown5;
|
---|
459 | uint32 unknown6;
|
---|
460 | uint32 unknown7;
|
---|
461 | uint32 unknown8;
|
---|
462 | } netr_DELTA_GROUP;
|
---|
463 |
|
---|
464 | typedef struct {
|
---|
465 | lsa_String OldName;
|
---|
466 | lsa_String NewName;
|
---|
467 | lsa_String unknown1;
|
---|
468 | lsa_String unknown2;
|
---|
469 | lsa_String unknown3;
|
---|
470 | lsa_String unknown4;
|
---|
471 | uint32 unknown5;
|
---|
472 | uint32 unknown6;
|
---|
473 | uint32 unknown7;
|
---|
474 | uint32 unknown8;
|
---|
475 | } netr_DELTA_RENAME;
|
---|
476 |
|
---|
477 | typedef struct {
|
---|
478 | [size_is(num_rids)] uint32 *rids;
|
---|
479 | [size_is(num_rids)] uint32 *attribs;
|
---|
480 | uint32 num_rids;
|
---|
481 | uint32 unknown1;
|
---|
482 | uint32 unknown2;
|
---|
483 | uint32 unknown3;
|
---|
484 | uint32 unknown4;
|
---|
485 | } netr_DELTA_GROUP_MEMBER;
|
---|
486 |
|
---|
487 | typedef struct {
|
---|
488 | lsa_String alias_name;
|
---|
489 | uint32 rid;
|
---|
490 | uint32 SecurityInformation;
|
---|
491 | sec_desc_buf sdbuf;
|
---|
492 | lsa_String description;
|
---|
493 | lsa_String unknown2;
|
---|
494 | lsa_String unknown3;
|
---|
495 | lsa_String unknown4;
|
---|
496 | uint32 unknown5;
|
---|
497 | uint32 unknown6;
|
---|
498 | uint32 unknown7;
|
---|
499 | uint32 unknown8;
|
---|
500 | } netr_DELTA_ALIAS;
|
---|
501 |
|
---|
502 | typedef struct {
|
---|
503 | lsa_SidArray sids;
|
---|
504 | uint32 unknown1;
|
---|
505 | uint32 unknown2;
|
---|
506 | uint32 unknown3;
|
---|
507 | uint32 unknown4;
|
---|
508 | } netr_DELTA_ALIAS_MEMBER;
|
---|
509 |
|
---|
510 | typedef struct {
|
---|
511 | uint32 pagedpoollimit;
|
---|
512 | uint32 nonpagedpoollimit;
|
---|
513 | uint32 minimumworkingsetsize;
|
---|
514 | uint32 maximumworkingsetsize;
|
---|
515 | uint32 pagefilelimit;
|
---|
516 | NTTIME timelimit;
|
---|
517 | } netr_QUOTA_LIMITS;
|
---|
518 |
|
---|
519 | typedef struct {
|
---|
520 | uint32 maxlogsize;
|
---|
521 | NTTIME auditretentionperiod;
|
---|
522 | boolean8 auditingmode;
|
---|
523 | uint32 maxauditeventcount;
|
---|
524 | [size_is(maxauditeventcount+1)] uint32 *eventauditoptions;
|
---|
525 | lsa_String primary_domain_name;
|
---|
526 | dom_sid2 *sid;
|
---|
527 | netr_QUOTA_LIMITS quota_limits;
|
---|
528 | udlong sequence_num;
|
---|
529 | NTTIME db_create_time;
|
---|
530 | uint32 SecurityInformation;
|
---|
531 | sec_desc_buf sdbuf;
|
---|
532 | lsa_String unknown1;
|
---|
533 | lsa_String unknown2;
|
---|
534 | lsa_String unknown3;
|
---|
535 | lsa_String unknown4;
|
---|
536 | uint32 unknown5;
|
---|
537 | uint32 unknown6;
|
---|
538 | uint32 unknown7;
|
---|
539 | uint32 unknown8;
|
---|
540 | } netr_DELTA_POLICY;
|
---|
541 |
|
---|
542 | typedef struct {
|
---|
543 | lsa_String domain_name;
|
---|
544 | uint32 num_controllers;
|
---|
545 | [size_is(num_controllers)] lsa_String *controller_names;
|
---|
546 | uint32 SecurityInformation;
|
---|
547 | sec_desc_buf sdbuf;
|
---|
548 | lsa_String unknown1;
|
---|
549 | lsa_String unknown2;
|
---|
550 | lsa_String unknown3;
|
---|
551 | lsa_String unknown4;
|
---|
552 | uint32 posix_offset;
|
---|
553 | uint32 unknown6;
|
---|
554 | uint32 unknown7;
|
---|
555 | uint32 unknown8;
|
---|
556 | } netr_DELTA_TRUSTED_DOMAIN;
|
---|
557 |
|
---|
558 | typedef struct {
|
---|
559 | uint16 unknown;
|
---|
560 | } netr_DELTA_DELETE_TRUST;
|
---|
561 |
|
---|
562 | typedef struct {
|
---|
563 | uint32 privilege_entries;
|
---|
564 | uint32 privilege_control;
|
---|
565 | [size_is(privilege_entries)] uint32 *privilege_attrib;
|
---|
566 | [size_is(privilege_entries)] lsa_String *privilege_name;
|
---|
567 | netr_QUOTA_LIMITS quotalimits;
|
---|
568 | uint32 system_flags;
|
---|
569 | uint32 SecurityInformation;
|
---|
570 | sec_desc_buf sdbuf;
|
---|
571 | lsa_String unknown1;
|
---|
572 | lsa_String unknown2;
|
---|
573 | lsa_String unknown3;
|
---|
574 | lsa_String unknown4;
|
---|
575 | uint32 unknown5;
|
---|
576 | uint32 unknown6;
|
---|
577 | uint32 unknown7;
|
---|
578 | uint32 unknown8;
|
---|
579 | } netr_DELTA_ACCOUNT;
|
---|
580 |
|
---|
581 | typedef struct {
|
---|
582 | uint16 unknown;
|
---|
583 | } netr_DELTA_DELETE_ACCOUNT;
|
---|
584 |
|
---|
585 | typedef struct {
|
---|
586 | uint16 unknown;
|
---|
587 | } netr_DELTA_DELETE_SECRET;
|
---|
588 |
|
---|
589 | typedef struct {
|
---|
590 | uint32 len;
|
---|
591 | uint32 maxlen;
|
---|
592 | [size_is(maxlen)][length_is(len)] uint8 *cipher_data;
|
---|
593 | } netr_CIPHER_VALUE;
|
---|
594 |
|
---|
595 | typedef struct {
|
---|
596 | netr_CIPHER_VALUE current_cipher;
|
---|
597 | NTTIME current_cipher_set_time;
|
---|
598 | netr_CIPHER_VALUE old_cipher;
|
---|
599 | NTTIME old_cipher_set_time;
|
---|
600 | uint32 SecurityInformation;
|
---|
601 | sec_desc_buf sdbuf;
|
---|
602 | lsa_String unknown1;
|
---|
603 | lsa_String unknown2;
|
---|
604 | lsa_String unknown3;
|
---|
605 | lsa_String unknown4;
|
---|
606 | uint32 unknown5;
|
---|
607 | uint32 unknown6;
|
---|
608 | uint32 unknown7;
|
---|
609 | uint32 unknown8;
|
---|
610 | } netr_DELTA_SECRET;
|
---|
611 |
|
---|
612 | typedef enum {
|
---|
613 | NETR_DELTA_DOMAIN = 1,
|
---|
614 | NETR_DELTA_GROUP = 2,
|
---|
615 | NETR_DELTA_DELETE_GROUP = 3,
|
---|
616 | NETR_DELTA_RENAME_GROUP = 4,
|
---|
617 | NETR_DELTA_USER = 5,
|
---|
618 | NETR_DELTA_DELETE_USER = 6,
|
---|
619 | NETR_DELTA_RENAME_USER = 7,
|
---|
620 | NETR_DELTA_GROUP_MEMBER = 8,
|
---|
621 | NETR_DELTA_ALIAS = 9,
|
---|
622 | NETR_DELTA_DELETE_ALIAS = 10,
|
---|
623 | NETR_DELTA_RENAME_ALIAS = 11,
|
---|
624 | NETR_DELTA_ALIAS_MEMBER = 12,
|
---|
625 | NETR_DELTA_POLICY = 13,
|
---|
626 | NETR_DELTA_TRUSTED_DOMAIN = 14,
|
---|
627 | NETR_DELTA_DELETE_TRUST = 15,
|
---|
628 | NETR_DELTA_ACCOUNT = 16,
|
---|
629 | NETR_DELTA_DELETE_ACCOUNT = 17,
|
---|
630 | NETR_DELTA_SECRET = 18,
|
---|
631 | NETR_DELTA_DELETE_SECRET = 19,
|
---|
632 | NETR_DELTA_DELETE_GROUP2 = 20,
|
---|
633 | NETR_DELTA_DELETE_USER2 = 21,
|
---|
634 | NETR_DELTA_MODIFY_COUNT = 22
|
---|
635 | } netr_DeltaEnum;
|
---|
636 |
|
---|
637 | typedef [switch_type(netr_DeltaEnum)] union {
|
---|
638 | [case(NETR_DELTA_DOMAIN)] netr_DELTA_DOMAIN *domain;
|
---|
639 | [case(NETR_DELTA_GROUP)] netr_DELTA_GROUP *group;
|
---|
640 | [case(NETR_DELTA_DELETE_GROUP)] ; /* rid only */
|
---|
641 | [case(NETR_DELTA_RENAME_GROUP)] netr_DELTA_RENAME *rename_group;
|
---|
642 | [case(NETR_DELTA_USER)] netr_DELTA_USER *user;
|
---|
643 | [case(NETR_DELTA_DELETE_USER)] ; /* rid only */
|
---|
644 | [case(NETR_DELTA_RENAME_USER)] netr_DELTA_RENAME *rename_user;
|
---|
645 | [case(NETR_DELTA_GROUP_MEMBER)] netr_DELTA_GROUP_MEMBER *group_member;
|
---|
646 | [case(NETR_DELTA_ALIAS)] netr_DELTA_ALIAS *alias;
|
---|
647 | [case(NETR_DELTA_DELETE_ALIAS)] ; /* rid only */
|
---|
648 | [case(NETR_DELTA_RENAME_ALIAS)] netr_DELTA_RENAME *rename_alias;
|
---|
649 | [case(NETR_DELTA_ALIAS_MEMBER)] netr_DELTA_ALIAS_MEMBER *alias_member;
|
---|
650 | [case(NETR_DELTA_POLICY)] netr_DELTA_POLICY *policy;
|
---|
651 | [case(NETR_DELTA_TRUSTED_DOMAIN)] netr_DELTA_TRUSTED_DOMAIN *trusted_domain;
|
---|
652 | [case(NETR_DELTA_DELETE_TRUST)] netr_DELTA_DELETE_TRUST delete_trust;
|
---|
653 | [case(NETR_DELTA_ACCOUNT)] netr_DELTA_ACCOUNT *account;
|
---|
654 | [case(NETR_DELTA_DELETE_ACCOUNT)] netr_DELTA_DELETE_ACCOUNT delete_account;
|
---|
655 | [case(NETR_DELTA_SECRET)] netr_DELTA_SECRET *secret;
|
---|
656 | [case(NETR_DELTA_DELETE_SECRET)] netr_DELTA_DELETE_SECRET delete_secret;
|
---|
657 | [case(NETR_DELTA_DELETE_GROUP2)] netr_DELTA_DELETE_USER *delete_group;
|
---|
658 | [case(NETR_DELTA_DELETE_USER2)] netr_DELTA_DELETE_USER *delete_user;
|
---|
659 | [case(NETR_DELTA_MODIFY_COUNT)] udlong *modified_count;
|
---|
660 | } netr_DELTA_UNION;
|
---|
661 |
|
---|
662 | typedef [switch_type(netr_DeltaEnum)] union {
|
---|
663 | [case(NETR_DELTA_DOMAIN)] uint32 rid;
|
---|
664 | [case(NETR_DELTA_GROUP)] uint32 rid;
|
---|
665 | [case(NETR_DELTA_DELETE_GROUP)] uint32 rid;
|
---|
666 | [case(NETR_DELTA_RENAME_GROUP)] uint32 rid;
|
---|
667 | [case(NETR_DELTA_USER)] uint32 rid;
|
---|
668 | [case(NETR_DELTA_DELETE_USER)] uint32 rid;
|
---|
669 | [case(NETR_DELTA_RENAME_USER)] uint32 rid;
|
---|
670 | [case(NETR_DELTA_GROUP_MEMBER)] uint32 rid;
|
---|
671 | [case(NETR_DELTA_ALIAS)] uint32 rid;
|
---|
672 | [case(NETR_DELTA_DELETE_ALIAS)] uint32 rid;
|
---|
673 | [case(NETR_DELTA_RENAME_ALIAS)] uint32 rid;
|
---|
674 | [case(NETR_DELTA_ALIAS_MEMBER)] uint32 rid;
|
---|
675 | [case(NETR_DELTA_POLICY)] dom_sid2 *sid;
|
---|
676 | [case(NETR_DELTA_TRUSTED_DOMAIN)] dom_sid2 *sid;
|
---|
677 | [case(NETR_DELTA_DELETE_TRUST)] dom_sid2 *sid;
|
---|
678 | [case(NETR_DELTA_ACCOUNT)] dom_sid2 *sid;
|
---|
679 | [case(NETR_DELTA_DELETE_ACCOUNT)] dom_sid2 *sid;
|
---|
680 | [case(NETR_DELTA_SECRET)] [string,charset(UTF16)] uint16 *name;
|
---|
681 | [case(NETR_DELTA_DELETE_SECRET)] [string,charset(UTF16)] uint16 *name;
|
---|
682 | [case(NETR_DELTA_DELETE_GROUP2)] uint32 rid;
|
---|
683 | [case(NETR_DELTA_DELETE_USER2)] uint32 rid;
|
---|
684 | [case(NETR_DELTA_MODIFY_COUNT)] ;
|
---|
685 | } netr_DELTA_ID_UNION;
|
---|
686 |
|
---|
687 | typedef struct {
|
---|
688 | netr_DeltaEnum delta_type;
|
---|
689 | [switch_is(delta_type)] netr_DELTA_ID_UNION delta_id_union;
|
---|
690 | [switch_is(delta_type)] netr_DELTA_UNION delta_union;
|
---|
691 | } netr_DELTA_ENUM;
|
---|
692 |
|
---|
693 | typedef struct {
|
---|
694 | uint32 num_deltas;
|
---|
695 | [size_is(num_deltas)] netr_DELTA_ENUM *delta_enum;
|
---|
696 | } netr_DELTA_ENUM_ARRAY;
|
---|
697 |
|
---|
698 |
|
---|
699 | NTSTATUS netr_DatabaseDeltas(
|
---|
700 | [in] [string,charset(UTF16)] uint16 logon_server[],
|
---|
701 | [in] [string,charset(UTF16)] uint16 computername[],
|
---|
702 | [in,ref] netr_Authenticator *credential,
|
---|
703 | [in,out,ref] netr_Authenticator *return_authenticator,
|
---|
704 | [in] netr_SamDatabaseID database_id,
|
---|
705 | [in,out,ref] udlong *sequence_num,
|
---|
706 | [out,ref] netr_DELTA_ENUM_ARRAY **delta_enum_array,
|
---|
707 | [in] uint32 preferredmaximumlength
|
---|
708 | );
|
---|
709 |
|
---|
710 |
|
---|
711 | /*****************/
|
---|
712 | /* Function 0x08 */
|
---|
713 |
|
---|
714 | NTSTATUS netr_DatabaseSync(
|
---|
715 | [in] [string,charset(UTF16)] uint16 logon_server[],
|
---|
716 | [in] [string,charset(UTF16)] uint16 computername[],
|
---|
717 | [in] netr_Authenticator credential,
|
---|
718 | [in,out,ref] netr_Authenticator *return_authenticator,
|
---|
719 | [in] netr_SamDatabaseID database_id,
|
---|
720 | [in,out,ref] uint32 *sync_context,
|
---|
721 | [in] uint32 preferredmaximumlength,
|
---|
722 | [out,ref] netr_DELTA_ENUM_ARRAY *delta_enum_array
|
---|
723 | );
|
---|
724 |
|
---|
725 |
|
---|
726 | /*****************/
|
---|
727 | /* Function 0x09 */
|
---|
728 |
|
---|
729 | /* w2k3 returns NT_STATUS_NOT_IMPLEMENTED for this call */
|
---|
730 |
|
---|
731 | typedef [flag(NDR_PAHEX)] struct {
|
---|
732 | uint8 computer_name[16];
|
---|
733 | uint32 timecreated;
|
---|
734 | uint32 serial_number;
|
---|
735 | } netr_UAS_INFO_0;
|
---|
736 |
|
---|
737 | typedef struct {
|
---|
738 | [flag(NDR_REMAINING)] DATA_BLOB blob;
|
---|
739 | } netr_AccountBuffer;
|
---|
740 |
|
---|
741 | NTSTATUS netr_AccountDeltas(
|
---|
742 | [in,unique] [string,charset(UTF16)] uint16 *logon_server,
|
---|
743 | [in] [string,charset(UTF16)] uint16 computername[],
|
---|
744 | [in] netr_Authenticator credential,
|
---|
745 | [in,out,ref] netr_Authenticator *return_authenticator,
|
---|
746 | [in] netr_UAS_INFO_0 uas,
|
---|
747 | [in] uint32 count,
|
---|
748 | [in] uint32 level,
|
---|
749 | [in] uint32 buffersize,
|
---|
750 | [out,ref,subcontext(4)] netr_AccountBuffer *buffer,
|
---|
751 | [out,ref] uint32 *count_returned,
|
---|
752 | [out,ref] uint32 *total_entries,
|
---|
753 | [out,ref] netr_UAS_INFO_0 *recordid
|
---|
754 | );
|
---|
755 |
|
---|
756 |
|
---|
757 | /*****************/
|
---|
758 | /* Function 0x0A */
|
---|
759 |
|
---|
760 | NTSTATUS netr_AccountSync(
|
---|
761 | [in,unique] [string,charset(UTF16)] uint16 *logon_server,
|
---|
762 | [in] [string,charset(UTF16)] uint16 computername[],
|
---|
763 | [in] netr_Authenticator credential,
|
---|
764 | [in,out,ref] netr_Authenticator *return_authenticator,
|
---|
765 | [in] uint32 reference,
|
---|
766 | [in] uint32 level,
|
---|
767 | [in] uint32 buffersize,
|
---|
768 | [out,ref,subcontext(4)] netr_AccountBuffer *buffer,
|
---|
769 | [out,ref] uint32 *count_returned,
|
---|
770 | [out,ref] uint32 *total_entries,
|
---|
771 | [out,ref] uint32 *next_reference,
|
---|
772 | [in,out,ref] netr_UAS_INFO_0 *recordid
|
---|
773 | );
|
---|
774 |
|
---|
775 |
|
---|
776 | /*****************/
|
---|
777 | /* Function 0x0B */
|
---|
778 |
|
---|
779 | WERROR netr_GetDcName(
|
---|
780 | [in] [string,charset(UTF16)] uint16 logon_server[],
|
---|
781 | [in,unique] [string,charset(UTF16)] uint16 *domainname,
|
---|
782 | [out,ref] [string,charset(UTF16)] uint16 **dcname
|
---|
783 | );
|
---|
784 |
|
---|
785 | /*****************/
|
---|
786 | /* Function 0x0C */
|
---|
787 |
|
---|
788 | typedef [bitmap32bit] bitmap {
|
---|
789 | NETLOGON_CTRL_REPL_NEEDED = 0x0001,
|
---|
790 | NETLOGON_CTRL_REPL_IN_PROGRESS = 0x0002,
|
---|
791 | NETLOGON_CTRL_REPL_FULL_SYNC = 0x0004
|
---|
792 | } netr_InfoFlags;
|
---|
793 |
|
---|
794 | typedef struct {
|
---|
795 | netr_InfoFlags flags;
|
---|
796 | uint32 pdc_connection_status;
|
---|
797 | } netr_NETLOGON_INFO_1;
|
---|
798 |
|
---|
799 | typedef struct {
|
---|
800 | netr_InfoFlags flags;
|
---|
801 | uint32 pdc_connection_status;
|
---|
802 | [string,charset(UTF16)] uint16 *trusted_dc_name;
|
---|
803 | uint32 tc_connection_status;
|
---|
804 | } netr_NETLOGON_INFO_2;
|
---|
805 |
|
---|
806 | typedef struct {
|
---|
807 | netr_InfoFlags flags;
|
---|
808 | uint32 logon_attempts;
|
---|
809 | uint32 unknown1;
|
---|
810 | uint32 unknown2;
|
---|
811 | uint32 unknown3;
|
---|
812 | uint32 unknown4;
|
---|
813 | uint32 unknown5;
|
---|
814 | } netr_NETLOGON_INFO_3;
|
---|
815 |
|
---|
816 | typedef union {
|
---|
817 | [case(1)] netr_NETLOGON_INFO_1 *info1;
|
---|
818 | [case(2)] netr_NETLOGON_INFO_2 *info2;
|
---|
819 | [case(3)] netr_NETLOGON_INFO_3 *info3;
|
---|
820 | } netr_CONTROL_QUERY_INFORMATION;
|
---|
821 |
|
---|
822 | /* function_code values */
|
---|
823 | typedef [v1_enum] enum {
|
---|
824 | NETLOGON_CONTROL_SYNC = 2,
|
---|
825 | NETLOGON_CONTROL_REDISCOVER = 5,
|
---|
826 | NETLOGON_CONTROL_TC_QUERY = 6,
|
---|
827 | NETLOGON_CONTROL_TRANSPORT_NOTIFY = 7,
|
---|
828 | NETLOGON_CONTROL_SET_DBFLAG = 65534
|
---|
829 | } netr_LogonControlCode;
|
---|
830 |
|
---|
831 | WERROR netr_LogonControl(
|
---|
832 | [in,unique] [string,charset(UTF16)] uint16 *logon_server,
|
---|
833 | [in] netr_LogonControlCode function_code,
|
---|
834 | [in] uint32 level,
|
---|
835 | [out,ref,switch_is(level)] netr_CONTROL_QUERY_INFORMATION *info
|
---|
836 | );
|
---|
837 |
|
---|
838 |
|
---|
839 | /*****************/
|
---|
840 | /* Function 0x0D */
|
---|
841 |
|
---|
842 | WERROR netr_GetAnyDCName(
|
---|
843 | [in,unique] [string,charset(UTF16)] uint16 *logon_server,
|
---|
844 | [in,unique] [string,charset(UTF16)] uint16 *domainname,
|
---|
845 | [out,ref] [string,charset(UTF16)] uint16 **dcname
|
---|
846 | );
|
---|
847 |
|
---|
848 |
|
---|
849 | /*****************/
|
---|
850 | /* Function 0x0E */
|
---|
851 |
|
---|
852 | typedef union {
|
---|
853 | [case(NETLOGON_CONTROL_REDISCOVER)] [string,charset(UTF16)] uint16 *domain;
|
---|
854 | [case(NETLOGON_CONTROL_TC_QUERY)] [string,charset(UTF16)] uint16 *domain;
|
---|
855 | [case(NETLOGON_CONTROL_TRANSPORT_NOTIFY)] [string,charset(UTF16)] uint16 *domain;
|
---|
856 | [case(NETLOGON_CONTROL_SET_DBFLAG)] uint32 debug_level;
|
---|
857 | } netr_CONTROL_DATA_INFORMATION;
|
---|
858 |
|
---|
859 | WERROR netr_LogonControl2(
|
---|
860 | [in,unique] [string,charset(UTF16)] uint16 *logon_server,
|
---|
861 | [in] netr_LogonControlCode function_code,
|
---|
862 | [in] uint32 level,
|
---|
863 | [in,ref][switch_is(function_code)] netr_CONTROL_DATA_INFORMATION *data,
|
---|
864 | [out,ref][switch_is(level)] netr_CONTROL_QUERY_INFORMATION *query
|
---|
865 | );
|
---|
866 |
|
---|
867 |
|
---|
868 | /* If NETLOGON_NEG_ARCFOUR flag is not set, then the passwords and LM
|
---|
869 | * session keys are encrypted with DES calls. (And the user session key
|
---|
870 | * is unencrypted) */
|
---|
871 |
|
---|
872 | /*****************/
|
---|
873 | /* Function 0x0F */
|
---|
874 |
|
---|
875 | typedef [bitmap32bit] bitmap {
|
---|
876 | NETLOGON_NEG_ACCOUNT_LOCKOUT = 0x00000001,
|
---|
877 | NETLOGON_NEG_PERSISTENT_SAMREPL = 0x00000002,
|
---|
878 | NETLOGON_NEG_ARCFOUR = 0x00000004,
|
---|
879 | NETLOGON_NEG_PROMOTION_COUNT = 0x00000008,
|
---|
880 | NETLOGON_NEG_CHANGELOG_BDC = 0x00000010,
|
---|
881 | NETLOGON_NEG_FULL_SYNC_REPL = 0x00000020,
|
---|
882 | NETLOGON_NEG_MULTIPLE_SIDS = 0x00000040,
|
---|
883 | NETLOGON_NEG_REDO = 0x00000080,
|
---|
884 | NETLOGON_NEG_PASSWORD_CHANGE_REFUSAL = 0x00000100,
|
---|
885 | NETLOGON_NEG_SEND_PASSWORD_INFO_PDC = 0x00000200,
|
---|
886 | NETLOGON_NEG_GENERIC_PASSTHROUGH = 0x00000400,
|
---|
887 | NETLOGON_NEG_CONCURRENT_RPC = 0x00000800,
|
---|
888 | NETLOGON_NEG_AVOID_ACCOUNT_DB_REPL = 0x00001000,
|
---|
889 | NETLOGON_NEG_AVOID_SECURITYAUTH_DB_REPL = 0x00002000,
|
---|
890 | NETLOGON_NEG_128BIT = 0x00004000, /* STRONG_KEYS */
|
---|
891 | NETLOGON_NEG_TRANSITIVE_TRUSTS = 0x00008000,
|
---|
892 | NETLOGON_NEG_DNS_DOMAIN_TRUSTS = 0x00010000,
|
---|
893 | NETLOGON_NEG_PASSWORD_SET2 = 0x00020000,
|
---|
894 | NETLOGON_NEG_GETDOMAININFO = 0x00040000,
|
---|
895 | NETLOGON_NEG_CROSS_FOREST_TRUSTS = 0x00080000,
|
---|
896 | NETLOGON_NEG_NEUTRALIZE_NT4_EMULATION = 0x00100000,
|
---|
897 | NETLOGON_NEG_RODC_PASSTHROUGH = 0x00200000,
|
---|
898 | NETLOGON_NEG_AUTHENTICATED_RPC_LSASS = 0x20000000,
|
---|
899 | NETLOGON_NEG_SCHANNEL = 0x40000000 /* AUTHENTICATED_RPC */
|
---|
900 | } netr_NegotiateFlags;
|
---|
901 |
|
---|
902 | NTSTATUS netr_ServerAuthenticate2(
|
---|
903 | [in,unique] [string,charset(UTF16)] uint16 *server_name,
|
---|
904 | [in] [string,charset(UTF16)] uint16 account_name[],
|
---|
905 | [in] netr_SchannelType secure_channel_type,
|
---|
906 | [in] [string,charset(UTF16)] uint16 computer_name[],
|
---|
907 | [in,ref] netr_Credential *credentials,
|
---|
908 | [out,ref] netr_Credential *return_credentials,
|
---|
909 | [in,out,ref] netr_NegotiateFlags *negotiate_flags
|
---|
910 | );
|
---|
911 |
|
---|
912 |
|
---|
913 | /*****************/
|
---|
914 | /* Function 0x10 */
|
---|
915 |
|
---|
916 | NTSTATUS netr_DatabaseSync2(
|
---|
917 | [in] [string,charset(UTF16)] uint16 logon_server[],
|
---|
918 | [in] [string,charset(UTF16)] uint16 computername[],
|
---|
919 | [in] netr_Authenticator *credential,
|
---|
920 | [in,out,ref] netr_Authenticator *return_authenticator,
|
---|
921 | [in] netr_SamDatabaseID database_id,
|
---|
922 | [in] uint16 restart_state,
|
---|
923 | [in,out,ref] uint32 *sync_context,
|
---|
924 | [out,ref] netr_DELTA_ENUM_ARRAY **delta_enum_array,
|
---|
925 | [in] uint32 preferredmaximumlength
|
---|
926 | );
|
---|
927 |
|
---|
928 |
|
---|
929 | /*****************/
|
---|
930 | /* Function 0x11 */
|
---|
931 |
|
---|
932 | /* i'm not at all sure how this call works */
|
---|
933 |
|
---|
934 | NTSTATUS netr_DatabaseRedo(
|
---|
935 | [in] [string,charset(UTF16)] uint16 logon_server[],
|
---|
936 | [in] [string,charset(UTF16)] uint16 computername[],
|
---|
937 | [in] netr_Authenticator credential,
|
---|
938 | [in,out,ref] netr_Authenticator *return_authenticator,
|
---|
939 | [in,unique][size_is(change_log_entry_size)] uint8 *change_log_entry,
|
---|
940 | [in] uint32 change_log_entry_size,
|
---|
941 | [out,ref] netr_DELTA_ENUM_ARRAY *delta_enum_array
|
---|
942 | );
|
---|
943 |
|
---|
944 |
|
---|
945 | /*****************/
|
---|
946 | /* Function 0x12 */
|
---|
947 |
|
---|
948 | WERROR netr_LogonControl2Ex(
|
---|
949 | [in,unique] [string,charset(UTF16)] uint16 *logon_server,
|
---|
950 | [in] uint32 function_code,
|
---|
951 | [in] uint32 level,
|
---|
952 | [in][switch_is(function_code)] netr_CONTROL_DATA_INFORMATION data,
|
---|
953 | [out,ref][switch_is(level)] netr_CONTROL_QUERY_INFORMATION *query
|
---|
954 | );
|
---|
955 |
|
---|
956 | /*****************/
|
---|
957 | /* Function 0x13 */
|
---|
958 | typedef struct {
|
---|
959 | uint32 length;
|
---|
960 | [size_is(length)] uint8 *data;
|
---|
961 | } netr_Blob;
|
---|
962 |
|
---|
963 | WERROR netr_NetrEnumerateTrustedDomains(
|
---|
964 | [in,unique] [string,charset(UTF16)] uint16 *server_name,
|
---|
965 | [out,ref] netr_Blob *trusted_domains_blob
|
---|
966 | );
|
---|
967 |
|
---|
968 | /*****************/
|
---|
969 | /* Function 0x14 */
|
---|
970 |
|
---|
971 | /* one unkown bit still: DS_IP_VERSION_AGNOSTIC - gd*/
|
---|
972 |
|
---|
973 | const int DSGETDC_VALID_FLAGS = (DS_FORCE_REDISCOVERY |
|
---|
974 | DS_DIRECTORY_SERVICE_REQUIRED |
|
---|
975 | DS_DIRECTORY_SERVICE_PREFERRED |
|
---|
976 | DS_GC_SERVER_REQUIRED |
|
---|
977 | DS_PDC_REQUIRED |
|
---|
978 | DS_BACKGROUND_ONLY |
|
---|
979 | DS_IP_REQUIRED |
|
---|
980 | DS_KDC_REQUIRED |
|
---|
981 | DS_TIMESERV_REQUIRED |
|
---|
982 | DS_WRITABLE_REQUIRED |
|
---|
983 | DS_GOOD_TIMESERV_PREFERRED |
|
---|
984 | DS_AVOID_SELF |
|
---|
985 | DS_ONLY_LDAP_NEEDED |
|
---|
986 | DS_IS_FLAT_NAME |
|
---|
987 | DS_IS_DNS_NAME |
|
---|
988 | DS_RETURN_FLAT_NAME |
|
---|
989 | DS_RETURN_DNS_NAME);
|
---|
990 |
|
---|
991 | typedef [bitmap32bit] bitmap {
|
---|
992 | DS_FORCE_REDISCOVERY = 0x00000001,
|
---|
993 | DS_DIRECTORY_SERVICE_REQUIRED = 0x00000010,
|
---|
994 | DS_DIRECTORY_SERVICE_PREFERRED = 0x00000020,
|
---|
995 | DS_GC_SERVER_REQUIRED = 0x00000040,
|
---|
996 | DS_PDC_REQUIRED = 0x00000080,
|
---|
997 | DS_BACKGROUND_ONLY = 0x00000100,
|
---|
998 | DS_IP_REQUIRED = 0x00000200,
|
---|
999 | DS_KDC_REQUIRED = 0x00000400,
|
---|
1000 | DS_TIMESERV_REQUIRED = 0x00000800,
|
---|
1001 | DS_WRITABLE_REQUIRED = 0x00001000,
|
---|
1002 | DS_GOOD_TIMESERV_PREFERRED = 0x00002000,
|
---|
1003 | DS_AVOID_SELF = 0x00004000,
|
---|
1004 | DS_ONLY_LDAP_NEEDED = 0x00008000,
|
---|
1005 | DS_IS_FLAT_NAME = 0x00010000,
|
---|
1006 | DS_IS_DNS_NAME = 0x00020000,
|
---|
1007 | DS_TRY_NEXTCLOSEST_SITE = 0x00040000,
|
---|
1008 | DS_DIRECTORY_SERVICE_6_REQUIRED = 0x00080000,
|
---|
1009 | DS_RETURN_DNS_NAME = 0x40000000,
|
---|
1010 | DS_RETURN_FLAT_NAME = 0x80000000
|
---|
1011 | } netr_DsRGetDCName_flags;
|
---|
1012 |
|
---|
1013 | typedef [v1_enum] enum {
|
---|
1014 | DS_ADDRESS_TYPE_INET = 1,
|
---|
1015 | DS_ADDRESS_TYPE_NETBIOS = 2
|
---|
1016 | } netr_DsRGetDCNameInfo_AddressType;
|
---|
1017 |
|
---|
1018 | typedef [bitmap32bit] bitmap {
|
---|
1019 | DS_SERVER_PDC = NBT_SERVER_PDC,
|
---|
1020 | DS_SERVER_GC = NBT_SERVER_GC,
|
---|
1021 | DS_SERVER_LDAP = NBT_SERVER_LDAP,
|
---|
1022 | DS_SERVER_DS = NBT_SERVER_DS,
|
---|
1023 | DS_SERVER_KDC = NBT_SERVER_KDC,
|
---|
1024 | DS_SERVER_TIMESERV = NBT_SERVER_TIMESERV,
|
---|
1025 | DS_SERVER_CLOSEST = NBT_SERVER_CLOSEST,
|
---|
1026 | DS_SERVER_WRITABLE = NBT_SERVER_WRITABLE,
|
---|
1027 | DS_SERVER_GOOD_TIMESERV = NBT_SERVER_GOOD_TIMESERV,
|
---|
1028 | DS_SERVER_NDNC = NBT_SERVER_NDNC,
|
---|
1029 | DS_SERVER_SELECT_SECRET_DOMAIN_6 = NBT_SERVER_SELECT_SECRET_DOMAIN_6,
|
---|
1030 | DS_SERVER_FULL_SECRET_DOMAIN_6 = NBT_SERVER_FULL_SECRET_DOMAIN_6,
|
---|
1031 | DS_DNS_CONTROLLER = 0x20000000,
|
---|
1032 | DS_DNS_DOMAIN = 0x40000000,
|
---|
1033 | DS_DNS_FOREST = 0x80000000
|
---|
1034 | } netr_DsR_DcFlags;
|
---|
1035 |
|
---|
1036 | typedef [public] struct {
|
---|
1037 | [string,charset(UTF16)] uint16 *dc_unc;
|
---|
1038 | [string,charset(UTF16)] uint16 *dc_address;
|
---|
1039 | netr_DsRGetDCNameInfo_AddressType dc_address_type;
|
---|
1040 | GUID domain_guid;
|
---|
1041 | [string,charset(UTF16)] uint16 *domain_name;
|
---|
1042 | [string,charset(UTF16)] uint16 *forest_name;
|
---|
1043 | netr_DsR_DcFlags dc_flags;
|
---|
1044 | [string,charset(UTF16)] uint16 *dc_site_name;
|
---|
1045 | [string,charset(UTF16)] uint16 *client_site_name;
|
---|
1046 | } netr_DsRGetDCNameInfo;
|
---|
1047 |
|
---|
1048 | WERROR netr_DsRGetDCName(
|
---|
1049 | [in,unique] [string,charset(UTF16)] uint16 *server_unc,
|
---|
1050 | [in,unique] [string,charset(UTF16)] uint16 *domain_name,
|
---|
1051 | [in,unique] GUID *domain_guid,
|
---|
1052 | [in,unique] GUID *site_guid,
|
---|
1053 | [in] netr_DsRGetDCName_flags flags,
|
---|
1054 | [out,ref] netr_DsRGetDCNameInfo **info
|
---|
1055 | );
|
---|
1056 |
|
---|
1057 | /*****************/
|
---|
1058 | /* Function 0x15 */
|
---|
1059 | typedef [switch_type(uint32)] union {
|
---|
1060 | [case(1)] netr_NegotiateFlags server_capabilities;
|
---|
1061 | } netr_Capabilities;
|
---|
1062 |
|
---|
1063 | NTSTATUS netr_LogonGetCapabilities(
|
---|
1064 | [in] [string,charset(UTF16)] uint16 server_name[],
|
---|
1065 | [in,unique] [string,charset(UTF16)] uint16 *computer_name,
|
---|
1066 | [in,ref] netr_Authenticator *credential,
|
---|
1067 | [in,out,ref] netr_Authenticator *return_authenticator,
|
---|
1068 | [in] uint32 query_level,
|
---|
1069 | [out,ref,switch_is(query_level)] netr_Capabilities *capabilities
|
---|
1070 | );
|
---|
1071 |
|
---|
1072 | /****************/
|
---|
1073 | /* Function 0x16 */
|
---|
1074 | WERROR netr_NETRLOGONSETSERVICEBITS();
|
---|
1075 |
|
---|
1076 | /****************/
|
---|
1077 | /* Function 0x17 */
|
---|
1078 | WERROR netr_LogonGetTrustRid(
|
---|
1079 | [in,unique] [string,charset(UTF16)] uint16 *server_name,
|
---|
1080 | [in,unique] [string,charset(UTF16)] uint16 *domain_name,
|
---|
1081 | [out,ref] uint32 *rid
|
---|
1082 | );
|
---|
1083 |
|
---|
1084 | /****************/
|
---|
1085 | /* Function 0x18 */
|
---|
1086 | WERROR netr_NETRLOGONCOMPUTESERVERDIGEST();
|
---|
1087 |
|
---|
1088 | /****************/
|
---|
1089 | /* Function 0x19 */
|
---|
1090 | WERROR netr_NETRLOGONCOMPUTECLIENTDIGEST();
|
---|
1091 |
|
---|
1092 | /****************/
|
---|
1093 | /* Function 0x1a */
|
---|
1094 | NTSTATUS netr_ServerAuthenticate3(
|
---|
1095 | [in,unique] [string,charset(UTF16)] uint16 *server_name,
|
---|
1096 | [in] [string,charset(UTF16)] uint16 account_name[],
|
---|
1097 | [in] netr_SchannelType secure_channel_type,
|
---|
1098 | [in] [string,charset(UTF16)] uint16 computer_name[],
|
---|
1099 | [in,out,ref] netr_Credential *credentials,
|
---|
1100 | [in,out,ref] netr_NegotiateFlags *negotiate_flags,
|
---|
1101 | [out,ref] uint32 *rid
|
---|
1102 | );
|
---|
1103 |
|
---|
1104 | /****************/
|
---|
1105 | /* Function 0x1b */
|
---|
1106 |
|
---|
1107 | WERROR netr_DsRGetDCNameEx(
|
---|
1108 | [in,unique] [string,charset(UTF16)] uint16 *server_unc,
|
---|
1109 | [in,unique] [string,charset(UTF16)] uint16 *domain_name,
|
---|
1110 | [in,unique] GUID *domain_guid,
|
---|
1111 | [in,unique] [string,charset(UTF16)] uint16 *site_name,
|
---|
1112 | [in] netr_DsRGetDCName_flags flags,
|
---|
1113 | [out,ref] netr_DsRGetDCNameInfo **info
|
---|
1114 | );
|
---|
1115 |
|
---|
1116 | /****************/
|
---|
1117 | /* Function 0x1c */
|
---|
1118 | WERROR netr_DsRGetSiteName(
|
---|
1119 | [in,unique] [string,charset(UTF16)] uint16 *computer_name,
|
---|
1120 | [out,ref] [string,charset(UTF16)] uint16 **site
|
---|
1121 | );
|
---|
1122 |
|
---|
1123 | /****************/
|
---|
1124 | /* Function 0x1d */
|
---|
1125 |
|
---|
1126 | typedef [flag(NDR_PAHEX)] struct {
|
---|
1127 | uint16 length;
|
---|
1128 | uint16 size;
|
---|
1129 | [size_is(size/2),length_is(length/2)] uint16 *data;
|
---|
1130 | } netr_BinaryString;
|
---|
1131 |
|
---|
1132 | typedef struct {
|
---|
1133 | netr_Blob blob;
|
---|
1134 | [string,charset(UTF16)] uint16 *workstation_domain;
|
---|
1135 | [string,charset(UTF16)] uint16 *workstation_site;
|
---|
1136 | [string,charset(UTF16)] uint16 *unknown1;
|
---|
1137 | [string,charset(UTF16)] uint16 *unknown2;
|
---|
1138 | [string,charset(UTF16)] uint16 *unknown3;
|
---|
1139 | [string,charset(UTF16)] uint16 *unknown4;
|
---|
1140 | netr_BinaryString blob2;
|
---|
1141 | lsa_String product;
|
---|
1142 | lsa_String unknown5;
|
---|
1143 | lsa_String unknown6;
|
---|
1144 | uint32 unknown7[4];
|
---|
1145 | } netr_DomainQuery1;
|
---|
1146 |
|
---|
1147 | typedef union {
|
---|
1148 | [case(1)] netr_DomainQuery1 *query1;
|
---|
1149 | [case(2)] netr_DomainQuery1 *query1;
|
---|
1150 | } netr_DomainQuery;
|
---|
1151 |
|
---|
1152 | typedef struct {
|
---|
1153 | lsa_String domainname;
|
---|
1154 | lsa_String fulldomainname;
|
---|
1155 | lsa_String forest;
|
---|
1156 | GUID guid;
|
---|
1157 | dom_sid2 *sid;
|
---|
1158 | netr_BinaryString unknown1[4];
|
---|
1159 | uint32 unknown[4];
|
---|
1160 | } netr_DomainTrustInfo;
|
---|
1161 |
|
---|
1162 | typedef struct {
|
---|
1163 | netr_DomainTrustInfo domaininfo;
|
---|
1164 | uint32 num_trusts;
|
---|
1165 | [size_is(num_trusts)] netr_DomainTrustInfo *trusts;
|
---|
1166 | uint32 unknown[14]; /* room for expansion? */
|
---|
1167 | } netr_DomainInfo1;
|
---|
1168 |
|
---|
1169 | typedef union {
|
---|
1170 | [case(1)] netr_DomainInfo1 *info1;
|
---|
1171 | [case(2)] netr_DomainInfo1 *info1;
|
---|
1172 | } netr_DomainInfo;
|
---|
1173 |
|
---|
1174 | NTSTATUS netr_LogonGetDomainInfo(
|
---|
1175 | [in] [string,charset(UTF16)] uint16 server_name[],
|
---|
1176 | [in,unique] [string,charset(UTF16)] uint16 *computer_name,
|
---|
1177 | [in,ref] netr_Authenticator *credential,
|
---|
1178 | [in,out,ref] netr_Authenticator *return_authenticator,
|
---|
1179 | [in] uint32 level,
|
---|
1180 | [in,switch_is(level)] netr_DomainQuery query,
|
---|
1181 | [out,ref,switch_is(level)] netr_DomainInfo *info
|
---|
1182 | );
|
---|
1183 |
|
---|
1184 | typedef [flag(NDR_PAHEX)] struct {
|
---|
1185 | uint8 data[512];
|
---|
1186 | uint32 length;
|
---|
1187 | } netr_CryptPassword;
|
---|
1188 |
|
---|
1189 | /*****************/
|
---|
1190 | /* Function 0x1e */
|
---|
1191 | NTSTATUS netr_ServerPasswordSet2(
|
---|
1192 | [in,unique] [string,charset(UTF16)] uint16 *server_name,
|
---|
1193 | [in] [string,charset(UTF16)] uint16 account_name[],
|
---|
1194 | [in] netr_SchannelType secure_channel_type,
|
---|
1195 | [in] [string,charset(UTF16)] uint16 computer_name[],
|
---|
1196 | [in,ref] netr_Authenticator *credential,
|
---|
1197 | [out,ref] netr_Authenticator *return_authenticator,
|
---|
1198 | [in,ref] netr_CryptPassword *new_password
|
---|
1199 | );
|
---|
1200 |
|
---|
1201 | /****************/
|
---|
1202 | /* Function 0x1f */
|
---|
1203 | WERROR netr_ServerPasswordGet(
|
---|
1204 | [in,unique] [string,charset(UTF16)] uint16 *server_name,
|
---|
1205 | [in] [string,charset(UTF16)] uint16 account_name[],
|
---|
1206 | [in] netr_SchannelType secure_channel_type,
|
---|
1207 | [in] [string,charset(UTF16)] uint16 computer_name[],
|
---|
1208 | [in,ref] netr_Authenticator *credential,
|
---|
1209 | [out,ref] netr_Authenticator *return_authenticator,
|
---|
1210 | [out,ref] samr_Password *password
|
---|
1211 | );
|
---|
1212 |
|
---|
1213 | /****************/
|
---|
1214 | /* Function 0x20 */
|
---|
1215 | WERROR netr_NETRLOGONSENDTOSAM();
|
---|
1216 |
|
---|
1217 | /****************/
|
---|
1218 | /* Function 0x21 */
|
---|
1219 | typedef struct {
|
---|
1220 | uint32 count;
|
---|
1221 | [size_is(count)] lsa_String *sitename;
|
---|
1222 | } netr_DsRAddressToSitenamesWCtr;
|
---|
1223 |
|
---|
1224 | typedef struct {
|
---|
1225 | [size_is(size)] uint8 *buffer;
|
---|
1226 | uint32 size;
|
---|
1227 | } netr_DsRAddress;
|
---|
1228 |
|
---|
1229 | WERROR netr_DsRAddressToSitenamesW(
|
---|
1230 | [in,unique] [string,charset(UTF16)] uint16 *server_name,
|
---|
1231 | [in] [range(0,32000)] uint32 count,
|
---|
1232 | [in] [size_is(count)] [ref] netr_DsRAddress *addresses,
|
---|
1233 | [out] [ref] netr_DsRAddressToSitenamesWCtr **ctr
|
---|
1234 | );
|
---|
1235 |
|
---|
1236 | /****************/
|
---|
1237 | /* Function 0x22 */
|
---|
1238 | WERROR netr_DsRGetDCNameEx2(
|
---|
1239 | [in,unique] [string,charset(UTF16)] uint16 *server_unc,
|
---|
1240 | [in,unique] [string,charset(UTF16)] uint16 *client_account,
|
---|
1241 | [in] samr_AcctFlags mask,
|
---|
1242 | [in,unique] [string,charset(UTF16)] uint16 *domain_name,
|
---|
1243 | [in,unique] GUID *domain_guid,
|
---|
1244 | [in,unique] [string,charset(UTF16)] uint16 *site_name,
|
---|
1245 | [in] netr_DsRGetDCName_flags flags,
|
---|
1246 | [out,ref] netr_DsRGetDCNameInfo **info
|
---|
1247 | );
|
---|
1248 |
|
---|
1249 | /****************/
|
---|
1250 | /* Function 0x23 */
|
---|
1251 | WERROR netr_NETRLOGONGETTIMESERVICEPARENTDOMAIN();
|
---|
1252 |
|
---|
1253 | /****************/
|
---|
1254 | /* Function 0x24 */
|
---|
1255 | typedef [bitmap32bit] bitmap {
|
---|
1256 | NETR_TRUST_FLAG_IN_FOREST = 0x00000001,
|
---|
1257 | NETR_TRUST_FLAG_OUTBOUND = 0x00000002,
|
---|
1258 | NETR_TRUST_FLAG_TREEROOT = 0x00000004,
|
---|
1259 | NETR_TRUST_FLAG_PRIMARY = 0x00000008,
|
---|
1260 | NETR_TRUST_FLAG_NATIVE = 0x00000010,
|
---|
1261 | NETR_TRUST_FLAG_INBOUND = 0x00000020
|
---|
1262 | } netr_TrustFlags;
|
---|
1263 |
|
---|
1264 | typedef [v1_enum] enum {
|
---|
1265 | NETR_TRUST_TYPE_DOWNLEVEL = 1,
|
---|
1266 | NETR_TRUST_TYPE_UPLEVEL = 2,
|
---|
1267 | NETR_TRUST_TYPE_MIT = 3,
|
---|
1268 | NETR_TRUST_TYPE_DCE = 4
|
---|
1269 | } netr_TrustType;
|
---|
1270 |
|
---|
1271 | typedef [bitmap32bit] bitmap {
|
---|
1272 | NETR_TRUST_ATTRIBUTE_NON_TRANSITIVE = 0x00000001,
|
---|
1273 | NETR_TRUST_ATTRIBUTE_UPLEVEL_ONLY = 0x00000002,
|
---|
1274 | NETR_TRUST_ATTRIBUTE_QUARANTINED_DOMAIN = 0x00000004,
|
---|
1275 | NETR_TRUST_ATTRIBUTE_FOREST_TRANSITIVE = 0x00000008,
|
---|
1276 | NETR_TRUST_ATTRIBUTE_CROSS_ORGANIZATION = 0x00000010,
|
---|
1277 | NETR_TRUST_ATTRIBUTE_WITHIN_FOREST = 0x00000020,
|
---|
1278 | NETR_TRUST_ATTRIBUTE_TREAT_AS_EXTERNAL = 0x00000040
|
---|
1279 | } netr_TrustAttributes;
|
---|
1280 |
|
---|
1281 | typedef struct {
|
---|
1282 | [string,charset(UTF16)] uint16 *netbios_name;
|
---|
1283 | [string,charset(UTF16)] uint16 *dns_name;
|
---|
1284 | netr_TrustFlags trust_flags;
|
---|
1285 | uint32 parent_index;
|
---|
1286 | netr_TrustType trust_type;
|
---|
1287 | netr_TrustAttributes trust_attributes;
|
---|
1288 | dom_sid2 *sid;
|
---|
1289 | GUID guid;
|
---|
1290 | } netr_DomainTrust;
|
---|
1291 |
|
---|
1292 | typedef struct {
|
---|
1293 | uint32 count;
|
---|
1294 | [size_is(count)] netr_DomainTrust *array;
|
---|
1295 | } netr_DomainTrustList;
|
---|
1296 |
|
---|
1297 | WERROR netr_NetrEnumerateTrustedDomainsEx(
|
---|
1298 | [in,unique] [string,charset(UTF16)] uint16 *server_name,
|
---|
1299 | [out,ref] netr_DomainTrustList *dom_trust_list
|
---|
1300 | );
|
---|
1301 |
|
---|
1302 | /****************/
|
---|
1303 | /* Function 0x25 */
|
---|
1304 | typedef struct {
|
---|
1305 | uint32 count;
|
---|
1306 | [size_is(count)] lsa_String *sitename;
|
---|
1307 | [size_is(count)] lsa_String *subnetname;
|
---|
1308 | } netr_DsRAddressToSitenamesExWCtr;
|
---|
1309 |
|
---|
1310 | WERROR netr_DsRAddressToSitenamesExW(
|
---|
1311 | [in,unique] [string,charset(UTF16)] uint16 *server_name,
|
---|
1312 | [in] [range(0,32000)] uint32 count,
|
---|
1313 | [in] [size_is(count)] [ref] netr_DsRAddress *addresses,
|
---|
1314 | [out] [ref] netr_DsRAddressToSitenamesExWCtr **ctr
|
---|
1315 | );
|
---|
1316 |
|
---|
1317 | /****************/
|
---|
1318 | /* Function 0x26 */
|
---|
1319 |
|
---|
1320 | typedef struct {
|
---|
1321 | uint32 num_sites;
|
---|
1322 | [size_is(num_sites)] [unique] lsa_String *sites;
|
---|
1323 | } DcSitesCtr;
|
---|
1324 |
|
---|
1325 | WERROR netr_DsrGetDcSiteCoverageW(
|
---|
1326 | [in,unique] [string,charset(UTF16)] uint16 *server_name,
|
---|
1327 | [out,ref] DcSitesCtr *ctr
|
---|
1328 | );
|
---|
1329 |
|
---|
1330 | /****************/
|
---|
1331 | /* Function 0x27 */
|
---|
1332 | NTSTATUS netr_LogonSamLogonEx(
|
---|
1333 | [in,unique] [string,charset(UTF16)] uint16 *server_name,
|
---|
1334 | [in,unique] [string,charset(UTF16)] uint16 *computer_name,
|
---|
1335 | [in] netr_LogonLevel logon_level,
|
---|
1336 | [in,ref] [switch_is(logon_level)] netr_LogonInfo *logon,
|
---|
1337 | [in] uint16 validation_level,
|
---|
1338 | [out,ref] [switch_is(validation_level)] netr_Validation *validation,
|
---|
1339 | [out,ref] uint8 *authoritative,
|
---|
1340 | [in,out,ref] uint32 *flags
|
---|
1341 | );
|
---|
1342 |
|
---|
1343 | /****************/
|
---|
1344 | /* Function 0x28 */
|
---|
1345 |
|
---|
1346 | WERROR netr_DsrEnumerateDomainTrusts(
|
---|
1347 | [in,unique] [string,charset(UTF16)] uint16 *server_name,
|
---|
1348 | [in] netr_TrustFlags trust_flags,
|
---|
1349 | [out,ref] netr_DomainTrustList *trusts
|
---|
1350 | );
|
---|
1351 |
|
---|
1352 |
|
---|
1353 | /****************/
|
---|
1354 | /* Function 0x29 */
|
---|
1355 | WERROR netr_DsrDeregisterDNSHostRecords(
|
---|
1356 | [in,unique] [string,charset(UTF16)] uint16 *server_name,
|
---|
1357 | [in,unique] [string,charset(UTF16)] uint16 *domain,
|
---|
1358 | [in,unique] GUID *domain_guid,
|
---|
1359 | [in,unique] GUID *dsa_guid,
|
---|
1360 | [in,ref] [string,charset(UTF16)] uint16 *dns_host
|
---|
1361 | );
|
---|
1362 |
|
---|
1363 | /****************/
|
---|
1364 | /* Function 0x2a */
|
---|
1365 | NTSTATUS netr_ServerTrustPasswordsGet(
|
---|
1366 | [in,unique] [string,charset(UTF16)] uint16 *server_name,
|
---|
1367 | [in] [string,charset(UTF16)] uint16 account_name[],
|
---|
1368 | [in] netr_SchannelType secure_channel_type,
|
---|
1369 | [in] [string,charset(UTF16)] uint16 computer_name[],
|
---|
1370 | [in,ref] netr_Authenticator *credential,
|
---|
1371 | [out,ref] netr_Authenticator *return_authenticator,
|
---|
1372 | [out,ref] samr_Password *password,
|
---|
1373 | [out,ref] samr_Password *password2
|
---|
1374 | );
|
---|
1375 |
|
---|
1376 | /****************/
|
---|
1377 | /* Function 0x2b */
|
---|
1378 |
|
---|
1379 | const int DS_GFTI_UPDATE_TDO = 0x1;
|
---|
1380 |
|
---|
1381 | WERROR netr_DsRGetForestTrustInformation(
|
---|
1382 | [in,unique] [string,charset(UTF16)] uint16 *server_name,
|
---|
1383 | [in,unique] [string,charset(UTF16)] uint16 *trusted_domain_name,
|
---|
1384 | [in] uint32 flags,
|
---|
1385 | [out,ref] lsa_ForestTrustInformation **forest_trust_info
|
---|
1386 | );
|
---|
1387 |
|
---|
1388 | /****************/
|
---|
1389 | /* Function 0x2c */
|
---|
1390 | WERROR netr_GetForestTrustInformation(
|
---|
1391 | [in,unique] [string,charset(UTF16)] uint16 *server_name,
|
---|
1392 | [in,ref] [string,charset(UTF16)] uint16 *trusted_domain_name,
|
---|
1393 | [in,ref] netr_Authenticator *credential,
|
---|
1394 | [out,ref] netr_Authenticator *return_authenticator,
|
---|
1395 | [in] uint32 flags,
|
---|
1396 | [out,ref] lsa_ForestTrustInformation **forest_trust_info
|
---|
1397 | );
|
---|
1398 |
|
---|
1399 | /****************/
|
---|
1400 | /* Function 0x2d */
|
---|
1401 |
|
---|
1402 | /* this is the ADS varient. I don't yet know what the "flags" are for */
|
---|
1403 | NTSTATUS netr_LogonSamLogonWithFlags(
|
---|
1404 | [in,unique] [string,charset(UTF16)] uint16 *server_name,
|
---|
1405 | [in,unique] [string,charset(UTF16)] uint16 *computer_name,
|
---|
1406 | [in,unique] netr_Authenticator *credential,
|
---|
1407 | [in,out,unique] netr_Authenticator *return_authenticator,
|
---|
1408 | [in] netr_LogonLevel logon_level,
|
---|
1409 | [in] [switch_is(logon_level)] netr_LogonInfo logon,
|
---|
1410 | [in] uint16 validation_level,
|
---|
1411 | [out,ref] [switch_is(validation_level)] netr_Validation *validation,
|
---|
1412 | [out,ref] uint8 *authoritative,
|
---|
1413 | [in,out,ref] uint32 *flags
|
---|
1414 | );
|
---|
1415 |
|
---|
1416 | /****************/
|
---|
1417 | /* Function 0x2e */
|
---|
1418 | WERROR netr_NETRSERVERGETTRUSTINFO();
|
---|
1419 | }
|
---|