util_strlist: Add some more "const"s - small correction
[Samba/ekacnet.git] / librpc / gen_ndr / samr.h
blobce84b45a9e237bb0927c939521434da303379491
1 /* header auto-generated by pidl */
3 #include <stdint.h>
5 #include "libcli/util/ntstatus.h"
7 #include "librpc/gen_ndr/misc.h"
8 #include "librpc/gen_ndr/lsa.h"
9 #include "librpc/gen_ndr/security.h"
10 #ifndef _HEADER_samr
11 #define _HEADER_samr
13 #define SAMR_ACCESS_ALL_ACCESS ( 0x0000003F )
14 #define GENERIC_RIGHTS_SAM_ALL_ACCESS ( (STANDARD_RIGHTS_REQUIRED_ACCESS|SAMR_ACCESS_ALL_ACCESS) )
15 #define GENERIC_RIGHTS_SAM_READ ( (STANDARD_RIGHTS_READ_ACCESS|SAMR_ACCESS_ENUM_DOMAINS) )
16 #define GENERIC_RIGHTS_SAM_WRITE ( (STANDARD_RIGHTS_WRITE_ACCESS|SAMR_ACCESS_CREATE_DOMAIN|SAMR_ACCESS_INITIALIZE_SERVER|SAMR_ACCESS_SHUTDOWN_SERVER) )
17 #define GENERIC_RIGHTS_SAM_EXECUTE ( (STANDARD_RIGHTS_EXECUTE_ACCESS|SAMR_ACCESS_LOOKUP_DOMAIN|SAMR_ACCESS_CONNECT_TO_SERVER) )
18 #define SAMR_USER_ACCESS_ALL_ACCESS ( 0x000007FF )
19 #define GENERIC_RIGHTS_USER_ALL_ACCESS ( (STANDARD_RIGHTS_REQUIRED_ACCESS|SAMR_USER_ACCESS_ALL_ACCESS) )
20 #define GENERIC_RIGHTS_USER_READ ( (STANDARD_RIGHTS_READ_ACCESS|SAMR_USER_ACCESS_GET_GROUP_MEMBERSHIP|SAMR_USER_ACCESS_GET_GROUPS|SAMR_USER_ACCESS_GET_ATTRIBUTES|SAMR_USER_ACCESS_GET_LOGONINFO|SAMR_USER_ACCESS_GET_LOCALE) )
21 #define GENERIC_RIGHTS_USER_WRITE ( (STANDARD_RIGHTS_WRITE_ACCESS|SAMR_USER_ACCESS_CHANGE_PASSWORD|SAMR_USER_ACCESS_SET_LOC_COM|SAMR_USER_ACCESS_SET_ATTRIBUTES|SAMR_USER_ACCESS_SET_PASSWORD|SAMR_USER_ACCESS_CHANGE_GROUP_MEMBERSHIP) )
22 #define GENERIC_RIGHTS_USER_EXECUTE ( (STANDARD_RIGHTS_EXECUTE_ACCESS|SAMR_USER_ACCESS_CHANGE_PASSWORD|SAMR_USER_ACCESS_GET_NAME_ETC) )
23 #define SAMR_DOMAIN_ACCESS_ALL_ACCESS ( 0x000007FF )
24 #define GENERIC_RIGHTS_DOMAIN_ALL_ACCESS ( (STANDARD_RIGHTS_REQUIRED_ACCESS|SAMR_DOMAIN_ACCESS_ALL_ACCESS) )
25 #define GENERIC_RIGHTS_DOMAIN_READ ( (STANDARD_RIGHTS_READ_ACCESS|SAMR_DOMAIN_ACCESS_LOOKUP_ALIAS|SAMR_DOMAIN_ACCESS_LOOKUP_INFO_2) )
26 #define GENERIC_RIGHTS_DOMAIN_WRITE ( (STANDARD_RIGHTS_WRITE_ACCESS|SAMR_DOMAIN_ACCESS_SET_INFO_3|SAMR_DOMAIN_ACCESS_CREATE_ALIAS|SAMR_DOMAIN_ACCESS_CREATE_GROUP|SAMR_DOMAIN_ACCESS_CREATE_USER|SAMR_DOMAIN_ACCESS_SET_INFO_2|SAMR_DOMAIN_ACCESS_SET_INFO_1) )
27 #define GENERIC_RIGHTS_DOMAIN_EXECUTE ( (STANDARD_RIGHTS_EXECUTE_ACCESS|SAMR_DOMAIN_ACCESS_OPEN_ACCOUNT|SAMR_DOMAIN_ACCESS_ENUM_ACCOUNTS|SAMR_DOMAIN_ACCESS_LOOKUP_INFO_1) )
28 #define SAMR_GROUP_ACCESS_ALL_ACCESS ( 0x0000001F )
29 #define GENERIC_RIGHTS_GROUP_ALL_ACCESS ( (STANDARD_RIGHTS_REQUIRED_ACCESS|SAMR_GROUP_ACCESS_ALL_ACCESS) )
30 #define GENERIC_RIGHTS_GROUP_READ ( (STANDARD_RIGHTS_READ_ACCESS|SAMR_GROUP_ACCESS_GET_MEMBERS) )
31 #define GENERIC_RIGHTS_GROUP_WRITE ( (STANDARD_RIGHTS_WRITE_ACCESS|SAMR_GROUP_ACCESS_REMOVE_MEMBER|SAMR_GROUP_ACCESS_ADD_MEMBER|SAMR_GROUP_ACCESS_SET_INFO) )
32 #define GENERIC_RIGHTS_GROUP_EXECUTE ( (STANDARD_RIGHTS_EXECUTE_ACCESS|SAMR_GROUP_ACCESS_LOOKUP_INFO) )
33 #define SAMR_ALIAS_ACCESS_ALL_ACCESS ( 0x0000001F )
34 #define GENERIC_RIGHTS_ALIAS_ALL_ACCESS ( (STANDARD_RIGHTS_REQUIRED_ACCESS|SAMR_ALIAS_ACCESS_ALL_ACCESS) )
35 #define GENERIC_RIGHTS_ALIAS_READ ( (STANDARD_RIGHTS_READ_ACCESS|SAMR_ALIAS_ACCESS_GET_MEMBERS) )
36 #define GENERIC_RIGHTS_ALIAS_WRITE ( (STANDARD_RIGHTS_WRITE_ACCESS|SAMR_ALIAS_ACCESS_REMOVE_MEMBER|SAMR_ALIAS_ACCESS_ADD_MEMBER|SAMR_ALIAS_ACCESS_SET_INFO) )
37 #define GENERIC_RIGHTS_ALIAS_EXECUTE ( (STANDARD_RIGHTS_EXECUTE_ACCESS|SAMR_ALIAS_ACCESS_LOOKUP_INFO) )
38 #define SAMR_ENUM_USERS_MULTIPLIER ( 54 )
39 #define PASS_MUST_CHANGE_AT_NEXT_LOGON ( 0x01 )
40 #define PASS_DONT_CHANGE_AT_NEXT_LOGON ( 0x00 )
41 enum netr_SamDatabaseID
42 #ifndef USE_UINT_ENUMS
44 SAM_DATABASE_DOMAIN=0,
45 SAM_DATABASE_BUILTIN=1,
46 SAM_DATABASE_PRIVS=2
48 #else
49 { __donnot_use_enum_netr_SamDatabaseID=0x7FFFFFFF}
50 #define SAM_DATABASE_DOMAIN ( 0 )
51 #define SAM_DATABASE_BUILTIN ( 1 )
52 #define SAM_DATABASE_PRIVS ( 2 )
53 #endif
56 enum samr_RejectReason
57 #ifndef USE_UINT_ENUMS
59 SAMR_REJECT_OTHER=0,
60 SAMR_REJECT_TOO_SHORT=1,
61 SAMR_REJECT_IN_HISTORY=2,
62 SAMR_REJECT_COMPLEXITY=5
64 #else
65 { __donnot_use_enum_samr_RejectReason=0x7FFFFFFF}
66 #define SAMR_REJECT_OTHER ( 0 )
67 #define SAMR_REJECT_TOO_SHORT ( 1 )
68 #define SAMR_REJECT_IN_HISTORY ( 2 )
69 #define SAMR_REJECT_COMPLEXITY ( 5 )
70 #endif
73 /* bitmap samr_AcctFlags */
74 #define ACB_DISABLED ( 0x00000001 )
75 #define ACB_HOMDIRREQ ( 0x00000002 )
76 #define ACB_PWNOTREQ ( 0x00000004 )
77 #define ACB_TEMPDUP ( 0x00000008 )
78 #define ACB_NORMAL ( 0x00000010 )
79 #define ACB_MNS ( 0x00000020 )
80 #define ACB_DOMTRUST ( 0x00000040 )
81 #define ACB_WSTRUST ( 0x00000080 )
82 #define ACB_SVRTRUST ( 0x00000100 )
83 #define ACB_PWNOEXP ( 0x00000200 )
84 #define ACB_AUTOLOCK ( 0x00000400 )
85 #define ACB_ENC_TXT_PWD_ALLOWED ( 0x00000800 )
86 #define ACB_SMARTCARD_REQUIRED ( 0x00001000 )
87 #define ACB_TRUSTED_FOR_DELEGATION ( 0x00002000 )
88 #define ACB_NOT_DELEGATED ( 0x00004000 )
89 #define ACB_USE_DES_KEY_ONLY ( 0x00008000 )
90 #define ACB_DONT_REQUIRE_PREAUTH ( 0x00010000 )
91 #define ACB_PW_EXPIRED ( 0x00020000 )
92 #define ACB_NO_AUTH_DATA_REQD ( 0x00080000 )
94 /* bitmap samr_ConnectAccessMask */
95 #define SAMR_ACCESS_CONNECT_TO_SERVER ( 0x00000001 )
96 #define SAMR_ACCESS_SHUTDOWN_SERVER ( 0x00000002 )
97 #define SAMR_ACCESS_INITIALIZE_SERVER ( 0x00000004 )
98 #define SAMR_ACCESS_CREATE_DOMAIN ( 0x00000008 )
99 #define SAMR_ACCESS_ENUM_DOMAINS ( 0x00000010 )
100 #define SAMR_ACCESS_LOOKUP_DOMAIN ( 0x00000020 )
102 /* bitmap samr_UserAccessMask */
103 #define SAMR_USER_ACCESS_GET_NAME_ETC ( 0x00000001 )
104 #define SAMR_USER_ACCESS_GET_LOCALE ( 0x00000002 )
105 #define SAMR_USER_ACCESS_SET_LOC_COM ( 0x00000004 )
106 #define SAMR_USER_ACCESS_GET_LOGONINFO ( 0x00000008 )
107 #define SAMR_USER_ACCESS_GET_ATTRIBUTES ( 0x00000010 )
108 #define SAMR_USER_ACCESS_SET_ATTRIBUTES ( 0x00000020 )
109 #define SAMR_USER_ACCESS_CHANGE_PASSWORD ( 0x00000040 )
110 #define SAMR_USER_ACCESS_SET_PASSWORD ( 0x00000080 )
111 #define SAMR_USER_ACCESS_GET_GROUPS ( 0x00000100 )
112 #define SAMR_USER_ACCESS_GET_GROUP_MEMBERSHIP ( 0x00000200 )
113 #define SAMR_USER_ACCESS_CHANGE_GROUP_MEMBERSHIP ( 0x00000400 )
115 /* bitmap samr_DomainAccessMask */
116 #define SAMR_DOMAIN_ACCESS_LOOKUP_INFO_1 ( 0x00000001 )
117 #define SAMR_DOMAIN_ACCESS_SET_INFO_1 ( 0x00000002 )
118 #define SAMR_DOMAIN_ACCESS_LOOKUP_INFO_2 ( 0x00000004 )
119 #define SAMR_DOMAIN_ACCESS_SET_INFO_2 ( 0x00000008 )
120 #define SAMR_DOMAIN_ACCESS_CREATE_USER ( 0x00000010 )
121 #define SAMR_DOMAIN_ACCESS_CREATE_GROUP ( 0x00000020 )
122 #define SAMR_DOMAIN_ACCESS_CREATE_ALIAS ( 0x00000040 )
123 #define SAMR_DOMAIN_ACCESS_LOOKUP_ALIAS ( 0x00000080 )
124 #define SAMR_DOMAIN_ACCESS_ENUM_ACCOUNTS ( 0x00000100 )
125 #define SAMR_DOMAIN_ACCESS_OPEN_ACCOUNT ( 0x00000200 )
126 #define SAMR_DOMAIN_ACCESS_SET_INFO_3 ( 0x00000400 )
128 /* bitmap samr_GroupAccessMask */
129 #define SAMR_GROUP_ACCESS_LOOKUP_INFO ( 0x00000001 )
130 #define SAMR_GROUP_ACCESS_SET_INFO ( 0x00000002 )
131 #define SAMR_GROUP_ACCESS_ADD_MEMBER ( 0x00000004 )
132 #define SAMR_GROUP_ACCESS_REMOVE_MEMBER ( 0x00000008 )
133 #define SAMR_GROUP_ACCESS_GET_MEMBERS ( 0x00000010 )
135 /* bitmap samr_AliasAccessMask */
136 #define SAMR_ALIAS_ACCESS_ADD_MEMBER ( 0x00000001 )
137 #define SAMR_ALIAS_ACCESS_REMOVE_MEMBER ( 0x00000002 )
138 #define SAMR_ALIAS_ACCESS_GET_MEMBERS ( 0x00000004 )
139 #define SAMR_ALIAS_ACCESS_LOOKUP_INFO ( 0x00000008 )
140 #define SAMR_ALIAS_ACCESS_SET_INFO ( 0x00000010 )
142 struct samr_SamEntry {
143 uint32_t idx;
144 struct lsa_String name;
147 struct samr_SamArray {
148 uint32_t count;
149 struct samr_SamEntry *entries;/* [unique,size_is(count)] */
152 enum samr_DomainInfoClass
153 #ifndef USE_UINT_ENUMS
155 DomainPasswordInformation=1,
156 DomainGeneralInformation=2,
157 DomainLogoffInformation=3,
158 DomainOemInformation=4,
159 DomainNameInformation=5,
160 DomainReplicationInformation=6,
161 DomainServerRoleInformation=7,
162 DomainModifiedInformation=8,
163 DomainStateInformation=9,
164 DomainUasInformation=10,
165 DomainGeneralInformation2=11,
166 DomainLockoutInformation=12,
167 DomainModifiedInformation2=13
169 #else
170 { __donnot_use_enum_samr_DomainInfoClass=0x7FFFFFFF}
171 #define DomainPasswordInformation ( 1 )
172 #define DomainGeneralInformation ( 2 )
173 #define DomainLogoffInformation ( 3 )
174 #define DomainOemInformation ( 4 )
175 #define DomainNameInformation ( 5 )
176 #define DomainReplicationInformation ( 6 )
177 #define DomainServerRoleInformation ( 7 )
178 #define DomainModifiedInformation ( 8 )
179 #define DomainStateInformation ( 9 )
180 #define DomainUasInformation ( 10 )
181 #define DomainGeneralInformation2 ( 11 )
182 #define DomainLockoutInformation ( 12 )
183 #define DomainModifiedInformation2 ( 13 )
184 #endif
187 enum samr_Role
188 #ifndef USE_UINT_ENUMS
190 SAMR_ROLE_STANDALONE=0,
191 SAMR_ROLE_DOMAIN_MEMBER=1,
192 SAMR_ROLE_DOMAIN_BDC=2,
193 SAMR_ROLE_DOMAIN_PDC=3
195 #else
196 { __donnot_use_enum_samr_Role=0x7FFFFFFF}
197 #define SAMR_ROLE_STANDALONE ( 0 )
198 #define SAMR_ROLE_DOMAIN_MEMBER ( 1 )
199 #define SAMR_ROLE_DOMAIN_BDC ( 2 )
200 #define SAMR_ROLE_DOMAIN_PDC ( 3 )
201 #endif
204 /* bitmap samr_PasswordProperties */
205 #define DOMAIN_PASSWORD_COMPLEX ( 0x00000001 )
206 #define DOMAIN_PASSWORD_NO_ANON_CHANGE ( 0x00000002 )
207 #define DOMAIN_PASSWORD_NO_CLEAR_CHANGE ( 0x00000004 )
208 #define DOMAIN_PASSWORD_LOCKOUT_ADMINS ( 0x00000008 )
209 #define DOMAIN_PASSWORD_STORE_CLEARTEXT ( 0x00000010 )
210 #define DOMAIN_REFUSE_PASSWORD_CHANGE ( 0x00000020 )
212 enum samr_DomainServerState
213 #ifndef USE_UINT_ENUMS
215 DOMAIN_SERVER_ENABLED=1,
216 DOMAIN_SERVER_DISABLED=2
218 #else
219 { __donnot_use_enum_samr_DomainServerState=0x7FFFFFFF}
220 #define DOMAIN_SERVER_ENABLED ( 1 )
221 #define DOMAIN_SERVER_DISABLED ( 2 )
222 #endif
225 struct samr_DomInfo1 {
226 uint16_t min_password_length;
227 uint16_t password_history_length;
228 uint32_t password_properties;
229 int64_t max_password_age;
230 int64_t min_password_age;
233 struct samr_DomGeneralInformation {
234 NTTIME force_logoff_time;
235 struct lsa_String oem_information;
236 struct lsa_String domain_name;
237 struct lsa_String primary;
238 uint64_t sequence_num;
239 enum samr_DomainServerState domain_server_state;
240 enum samr_Role role;
241 uint32_t unknown3;
242 uint32_t num_users;
243 uint32_t num_groups;
244 uint32_t num_aliases;
247 struct samr_DomInfo3 {
248 NTTIME force_logoff_time;
251 struct samr_DomOEMInformation {
252 struct lsa_String oem_information;
255 struct samr_DomInfo5 {
256 struct lsa_String domain_name;
259 struct samr_DomInfo6 {
260 struct lsa_String primary;
263 struct samr_DomInfo7 {
264 enum samr_Role role;
267 struct samr_DomInfo8 {
268 uint64_t sequence_num;
269 NTTIME domain_create_time;
272 struct samr_DomInfo9 {
273 enum samr_DomainServerState domain_server_state;
276 struct samr_DomGeneralInformation2 {
277 struct samr_DomGeneralInformation general;
278 uint64_t lockout_duration;
279 uint64_t lockout_window;
280 uint16_t lockout_threshold;
283 struct samr_DomInfo12 {
284 uint64_t lockout_duration;
285 uint64_t lockout_window;
286 uint16_t lockout_threshold;
289 struct samr_DomInfo13 {
290 uint64_t sequence_num;
291 NTTIME domain_create_time;
292 uint64_t modified_count_at_last_promotion;
295 union samr_DomainInfo {
296 struct samr_DomInfo1 info1;/* [case] */
297 struct samr_DomGeneralInformation general;/* [case(2)] */
298 struct samr_DomInfo3 info3;/* [case(3)] */
299 struct samr_DomOEMInformation oem;/* [case(4)] */
300 struct samr_DomInfo5 info5;/* [case(5)] */
301 struct samr_DomInfo6 info6;/* [case(6)] */
302 struct samr_DomInfo7 info7;/* [case(7)] */
303 struct samr_DomInfo8 info8;/* [case(8)] */
304 struct samr_DomInfo9 info9;/* [case(9)] */
305 struct samr_DomGeneralInformation2 general2;/* [case(11)] */
306 struct samr_DomInfo12 info12;/* [case(12)] */
307 struct samr_DomInfo13 info13;/* [case(13)] */
308 }/* [switch_type(uint16)] */;
310 struct samr_Ids {
311 uint32_t count;/* [range(0,1024)] */
312 uint32_t *ids;/* [unique,size_is(count)] */
315 /* bitmap samr_GroupAttrs */
316 #define SE_GROUP_MANDATORY ( 0x00000001 )
317 #define SE_GROUP_ENABLED_BY_DEFAULT ( 0x00000002 )
318 #define SE_GROUP_ENABLED ( 0x00000004 )
319 #define SE_GROUP_OWNER ( 0x00000008 )
320 #define SE_GROUP_USE_FOR_DENY_ONLY ( 0x00000010 )
321 #define SE_GROUP_RESOURCE ( 0x20000000 )
322 #define SE_GROUP_LOGON_ID ( 0xC0000000 )
324 struct samr_GroupInfoAll {
325 struct lsa_String name;
326 uint32_t attributes;
327 uint32_t num_members;
328 struct lsa_String description;
331 struct samr_GroupInfoAttributes {
332 uint32_t attributes;
335 struct samr_GroupInfoDescription {
336 struct lsa_String description;
339 enum samr_GroupInfoEnum
340 #ifndef USE_UINT_ENUMS
342 GROUPINFOALL=1,
343 GROUPINFONAME=2,
344 GROUPINFOATTRIBUTES=3,
345 GROUPINFODESCRIPTION=4,
346 GROUPINFOALL2=5
348 #else
349 { __donnot_use_enum_samr_GroupInfoEnum=0x7FFFFFFF}
350 #define GROUPINFOALL ( 1 )
351 #define GROUPINFONAME ( 2 )
352 #define GROUPINFOATTRIBUTES ( 3 )
353 #define GROUPINFODESCRIPTION ( 4 )
354 #define GROUPINFOALL2 ( 5 )
355 #endif
358 union samr_GroupInfo {
359 struct samr_GroupInfoAll all;/* [case(GROUPINFOALL)] */
360 struct lsa_String name;/* [case(GROUPINFONAME)] */
361 struct samr_GroupInfoAttributes attributes;/* [case(GROUPINFOATTRIBUTES)] */
362 struct lsa_String description;/* [case(GROUPINFODESCRIPTION)] */
363 struct samr_GroupInfoAll all2;/* [case(GROUPINFOALL2)] */
364 }/* [switch_type(samr_GroupInfoEnum)] */;
366 struct samr_RidTypeArray {
367 uint32_t count;
368 uint32_t *rids;/* [unique,size_is(count)] */
369 uint32_t *types;/* [unique,size_is(count)] */
372 struct samr_AliasInfoAll {
373 struct lsa_String name;
374 uint32_t num_members;
375 struct lsa_String description;
378 enum samr_AliasInfoEnum
379 #ifndef USE_UINT_ENUMS
381 ALIASINFOALL=1,
382 ALIASINFONAME=2,
383 ALIASINFODESCRIPTION=3
385 #else
386 { __donnot_use_enum_samr_AliasInfoEnum=0x7FFFFFFF}
387 #define ALIASINFOALL ( 1 )
388 #define ALIASINFONAME ( 2 )
389 #define ALIASINFODESCRIPTION ( 3 )
390 #endif
393 union samr_AliasInfo {
394 struct samr_AliasInfoAll all;/* [case(ALIASINFOALL)] */
395 struct lsa_String name;/* [case(ALIASINFONAME)] */
396 struct lsa_String description;/* [case(ALIASINFODESCRIPTION)] */
397 }/* [switch_type(samr_AliasInfoEnum)] */;
399 enum samr_UserInfoLevel
400 #ifndef USE_UINT_ENUMS
402 UserGeneralInformation=1,
403 UserPreferencesInformation=2,
404 UserLogonInformation=3,
405 UserLogonHoursInformation=4,
406 UserAccountInformation=5,
407 UserNameInformation=6,
408 UserAccountNameInformation=7,
409 UserFullNameInformation=8,
410 UserPrimaryGroupInformation=9,
411 UserHomeInformation=10,
412 UserScriptInformation=11,
413 UserProfileInformation=12,
414 UserAdminCommentInformation=13,
415 UserWorkStationsInformation=14,
416 UserControlInformation=16,
417 UserExpiresInformation=17,
418 UserInternal1Information=18,
419 UserParametersInformation=20,
420 UserAllInformation=21,
421 UserInternal4Information=23,
422 UserInternal5Information=24,
423 UserInternal4InformationNew=25,
424 UserInternal5InformationNew=26
426 #else
427 { __donnot_use_enum_samr_UserInfoLevel=0x7FFFFFFF}
428 #define UserGeneralInformation ( 1 )
429 #define UserPreferencesInformation ( 2 )
430 #define UserLogonInformation ( 3 )
431 #define UserLogonHoursInformation ( 4 )
432 #define UserAccountInformation ( 5 )
433 #define UserNameInformation ( 6 )
434 #define UserAccountNameInformation ( 7 )
435 #define UserFullNameInformation ( 8 )
436 #define UserPrimaryGroupInformation ( 9 )
437 #define UserHomeInformation ( 10 )
438 #define UserScriptInformation ( 11 )
439 #define UserProfileInformation ( 12 )
440 #define UserAdminCommentInformation ( 13 )
441 #define UserWorkStationsInformation ( 14 )
442 #define UserControlInformation ( 16 )
443 #define UserExpiresInformation ( 17 )
444 #define UserInternal1Information ( 18 )
445 #define UserParametersInformation ( 20 )
446 #define UserAllInformation ( 21 )
447 #define UserInternal4Information ( 23 )
448 #define UserInternal5Information ( 24 )
449 #define UserInternal4InformationNew ( 25 )
450 #define UserInternal5InformationNew ( 26 )
451 #endif
454 struct samr_UserInfo1 {
455 struct lsa_String account_name;
456 struct lsa_String full_name;
457 uint32_t primary_gid;
458 struct lsa_String description;
459 struct lsa_String comment;
462 struct samr_UserInfo2 {
463 struct lsa_String comment;
464 struct lsa_String unknown;
465 uint16_t country_code;
466 uint16_t code_page;
469 struct samr_LogonHours {
470 uint16_t units_per_week;
471 uint8_t *bits;/* [unique,length_is(units_per_week/8),size_is(1260)] */
472 }/* [public,flag(LIBNDR_PRINT_ARRAY_HEX)] */;
474 struct samr_UserInfo3 {
475 struct lsa_String account_name;
476 struct lsa_String full_name;
477 uint32_t rid;
478 uint32_t primary_gid;
479 struct lsa_String home_directory;
480 struct lsa_String home_drive;
481 struct lsa_String logon_script;
482 struct lsa_String profile_path;
483 struct lsa_String workstations;
484 NTTIME last_logon;
485 NTTIME last_logoff;
486 NTTIME last_password_change;
487 NTTIME allow_password_change;
488 NTTIME force_password_change;
489 struct samr_LogonHours logon_hours;
490 uint16_t bad_password_count;
491 uint16_t logon_count;
492 uint32_t acct_flags;
495 struct samr_UserInfo4 {
496 struct samr_LogonHours logon_hours;
499 struct samr_UserInfo5 {
500 struct lsa_String account_name;
501 struct lsa_String full_name;
502 uint32_t rid;
503 uint32_t primary_gid;
504 struct lsa_String home_directory;
505 struct lsa_String home_drive;
506 struct lsa_String logon_script;
507 struct lsa_String profile_path;
508 struct lsa_String description;
509 struct lsa_String workstations;
510 NTTIME last_logon;
511 NTTIME last_logoff;
512 struct samr_LogonHours logon_hours;
513 uint16_t bad_password_count;
514 uint16_t logon_count;
515 NTTIME last_password_change;
516 NTTIME acct_expiry;
517 uint32_t acct_flags;
520 struct samr_UserInfo6 {
521 struct lsa_String account_name;
522 struct lsa_String full_name;
525 struct samr_UserInfo7 {
526 struct lsa_String account_name;
529 struct samr_UserInfo8 {
530 struct lsa_String full_name;
533 struct samr_UserInfo9 {
534 uint32_t primary_gid;
537 struct samr_UserInfo10 {
538 struct lsa_String home_directory;
539 struct lsa_String home_drive;
542 struct samr_UserInfo11 {
543 struct lsa_String logon_script;
546 struct samr_UserInfo12 {
547 struct lsa_String profile_path;
550 struct samr_UserInfo13 {
551 struct lsa_String description;
554 struct samr_UserInfo14 {
555 struct lsa_String workstations;
558 struct samr_UserInfo16 {
559 uint32_t acct_flags;
562 struct samr_UserInfo17 {
563 NTTIME acct_expiry;
566 struct samr_Password {
567 uint8_t hash[16];
568 }/* [public,flag(LIBNDR_PRINT_ARRAY_HEX)] */;
570 struct samr_UserInfo18 {
571 struct samr_Password nt_pwd;
572 struct samr_Password lm_pwd;
573 uint8_t nt_pwd_active;
574 uint8_t lm_pwd_active;
575 uint8_t password_expired;
578 struct samr_UserInfo20 {
579 struct lsa_BinaryString parameters;
582 /* bitmap samr_FieldsPresent */
583 #define SAMR_FIELD_ACCOUNT_NAME ( 0x00000001 )
584 #define SAMR_FIELD_FULL_NAME ( 0x00000002 )
585 #define SAMR_FIELD_RID ( 0x00000004 )
586 #define SAMR_FIELD_PRIMARY_GID ( 0x00000008 )
587 #define SAMR_FIELD_DESCRIPTION ( 0x00000010 )
588 #define SAMR_FIELD_COMMENT ( 0x00000020 )
589 #define SAMR_FIELD_HOME_DIRECTORY ( 0x00000040 )
590 #define SAMR_FIELD_HOME_DRIVE ( 0x00000080 )
591 #define SAMR_FIELD_LOGON_SCRIPT ( 0x00000100 )
592 #define SAMR_FIELD_PROFILE_PATH ( 0x00000200 )
593 #define SAMR_FIELD_WORKSTATIONS ( 0x00000400 )
594 #define SAMR_FIELD_LAST_LOGON ( 0x00000800 )
595 #define SAMR_FIELD_LAST_LOGOFF ( 0x00001000 )
596 #define SAMR_FIELD_LOGON_HOURS ( 0x00002000 )
597 #define SAMR_FIELD_BAD_PWD_COUNT ( 0x00004000 )
598 #define SAMR_FIELD_NUM_LOGONS ( 0x00008000 )
599 #define SAMR_FIELD_ALLOW_PWD_CHANGE ( 0x00010000 )
600 #define SAMR_FIELD_FORCE_PWD_CHANGE ( 0x00020000 )
601 #define SAMR_FIELD_LAST_PWD_CHANGE ( 0x00040000 )
602 #define SAMR_FIELD_ACCT_EXPIRY ( 0x00080000 )
603 #define SAMR_FIELD_ACCT_FLAGS ( 0x00100000 )
604 #define SAMR_FIELD_PARAMETERS ( 0x00200000 )
605 #define SAMR_FIELD_COUNTRY_CODE ( 0x00400000 )
606 #define SAMR_FIELD_CODE_PAGE ( 0x00800000 )
607 #define SAMR_FIELD_NT_PASSWORD_PRESENT ( 0x01000000 )
608 #define SAMR_FIELD_LM_PASSWORD_PRESENT ( 0x02000000 )
609 #define SAMR_FIELD_PRIVATE_DATA ( 0x04000000 )
610 #define SAMR_FIELD_EXPIRED_FLAG ( 0x08000000 )
611 #define SAMR_FIELD_SEC_DESC ( 0x10000000 )
612 #define SAMR_FIELD_OWF_PWD ( 0x20000000 )
614 struct samr_UserInfo21 {
615 NTTIME last_logon;
616 NTTIME last_logoff;
617 NTTIME last_password_change;
618 NTTIME acct_expiry;
619 NTTIME allow_password_change;
620 NTTIME force_password_change;
621 struct lsa_String account_name;
622 struct lsa_String full_name;
623 struct lsa_String home_directory;
624 struct lsa_String home_drive;
625 struct lsa_String logon_script;
626 struct lsa_String profile_path;
627 struct lsa_String description;
628 struct lsa_String workstations;
629 struct lsa_String comment;
630 struct lsa_BinaryString parameters;
631 struct lsa_BinaryString lm_owf_password;
632 struct lsa_BinaryString nt_owf_password;
633 struct lsa_String unknown3;
634 uint32_t buf_count;
635 uint8_t *buffer;/* [unique,size_is(buf_count)] */
636 uint32_t rid;
637 uint32_t primary_gid;
638 uint32_t acct_flags;
639 uint32_t fields_present;
640 struct samr_LogonHours logon_hours;
641 uint16_t bad_password_count;
642 uint16_t logon_count;
643 uint16_t country_code;
644 uint16_t code_page;
645 uint8_t lm_password_set;
646 uint8_t nt_password_set;
647 uint8_t password_expired;
648 uint8_t unknown4;
651 struct samr_CryptPassword {
652 uint8_t data[516];
653 }/* [public,flag(LIBNDR_PRINT_ARRAY_HEX)] */;
655 struct samr_UserInfo23 {
656 struct samr_UserInfo21 info;
657 struct samr_CryptPassword password;
660 struct samr_UserInfo24 {
661 struct samr_CryptPassword password;
662 uint8_t password_expired;
665 struct samr_CryptPasswordEx {
666 uint8_t data[532];
667 }/* [flag(LIBNDR_PRINT_ARRAY_HEX)] */;
669 struct samr_UserInfo25 {
670 struct samr_UserInfo21 info;
671 struct samr_CryptPasswordEx password;
674 struct samr_UserInfo26 {
675 struct samr_CryptPasswordEx password;
676 uint8_t password_expired;
679 union samr_UserInfo {
680 struct samr_UserInfo1 info1;/* [case] */
681 struct samr_UserInfo2 info2;/* [case(2)] */
682 struct samr_UserInfo3 info3;/* [case(3)] */
683 struct samr_UserInfo4 info4;/* [case(4)] */
684 struct samr_UserInfo5 info5;/* [case(5)] */
685 struct samr_UserInfo6 info6;/* [case(6)] */
686 struct samr_UserInfo7 info7;/* [case(7)] */
687 struct samr_UserInfo8 info8;/* [case(8)] */
688 struct samr_UserInfo9 info9;/* [case(9)] */
689 struct samr_UserInfo10 info10;/* [case(10)] */
690 struct samr_UserInfo11 info11;/* [case(11)] */
691 struct samr_UserInfo12 info12;/* [case(12)] */
692 struct samr_UserInfo13 info13;/* [case(13)] */
693 struct samr_UserInfo14 info14;/* [case(14)] */
694 struct samr_UserInfo16 info16;/* [case(16)] */
695 struct samr_UserInfo17 info17;/* [case(17)] */
696 struct samr_UserInfo18 info18;/* [case(18)] */
697 struct samr_UserInfo20 info20;/* [case(20)] */
698 struct samr_UserInfo21 info21;/* [case(21)] */
699 struct samr_UserInfo23 info23;/* [case(23)] */
700 struct samr_UserInfo24 info24;/* [case(24)] */
701 struct samr_UserInfo25 info25;/* [case(25)] */
702 struct samr_UserInfo26 info26;/* [case(26)] */
703 }/* [switch_type(uint16)] */;
705 struct samr_RidWithAttribute {
706 uint32_t rid;
707 uint32_t attributes;
708 }/* [public] */;
710 struct samr_RidWithAttributeArray {
711 uint32_t count;
712 struct samr_RidWithAttribute *rids;/* [unique,size_is(count)] */
713 }/* [public] */;
715 struct samr_DispEntryGeneral {
716 uint32_t idx;
717 uint32_t rid;
718 uint32_t acct_flags;
719 struct lsa_String account_name;
720 struct lsa_String description;
721 struct lsa_String full_name;
724 struct samr_DispInfoGeneral {
725 uint32_t count;
726 struct samr_DispEntryGeneral *entries;/* [unique,size_is(count)] */
729 struct samr_DispEntryFull {
730 uint32_t idx;
731 uint32_t rid;
732 uint32_t acct_flags;
733 struct lsa_String account_name;
734 struct lsa_String description;
737 struct samr_DispInfoFull {
738 uint32_t count;
739 struct samr_DispEntryFull *entries;/* [unique,size_is(count)] */
742 struct samr_DispEntryFullGroup {
743 uint32_t idx;
744 uint32_t rid;
745 uint32_t acct_flags;
746 struct lsa_String account_name;
747 struct lsa_String description;
750 struct samr_DispInfoFullGroups {
751 uint32_t count;
752 struct samr_DispEntryFullGroup *entries;/* [unique,size_is(count)] */
755 struct samr_DispEntryAscii {
756 uint32_t idx;
757 struct lsa_AsciiStringLarge account_name;
760 struct samr_DispInfoAscii {
761 uint32_t count;
762 struct samr_DispEntryAscii *entries;/* [unique,size_is(count)] */
765 union samr_DispInfo {
766 struct samr_DispInfoGeneral info1;/* [case] */
767 struct samr_DispInfoFull info2;/* [case(2)] */
768 struct samr_DispInfoFullGroups info3;/* [case(3)] */
769 struct samr_DispInfoAscii info4;/* [case(4)] */
770 struct samr_DispInfoAscii info5;/* [case(5)] */
771 }/* [switch_type(uint16)] */;
773 struct samr_PwInfo {
774 uint16_t min_password_length;
775 uint32_t password_properties;
778 enum samr_ConnectVersion
779 #ifndef USE_UINT_ENUMS
781 SAMR_CONNECT_PRE_W2K=1,
782 SAMR_CONNECT_W2K=2,
783 SAMR_CONNECT_AFTER_W2K=3
785 #else
786 { __donnot_use_enum_samr_ConnectVersion=0x7FFFFFFF}
787 #define SAMR_CONNECT_PRE_W2K ( 1 )
788 #define SAMR_CONNECT_W2K ( 2 )
789 #define SAMR_CONNECT_AFTER_W2K ( 3 )
790 #endif
793 struct samr_ChangeReject {
794 enum samr_RejectReason reason;
795 uint32_t unknown1;
796 uint32_t unknown2;
799 struct samr_ConnectInfo1 {
800 enum samr_ConnectVersion client_version;
801 uint32_t unknown2;
804 union samr_ConnectInfo {
805 struct samr_ConnectInfo1 info1;/* [case] */
808 /* bitmap samr_ValidateFieldsPresent */
809 #define SAMR_VALIDATE_FIELD_PASSWORD_LAST_SET ( 0x00000001 )
810 #define SAMR_VALIDATE_FIELD_BAD_PASSWORD_TIME ( 0x00000002 )
811 #define SAMR_VALIDATE_FIELD_LOCKOUT_TIME ( 0x00000004 )
812 #define SAMR_VALIDATE_FIELD_BAD_PASSWORD_COUNT ( 0x00000008 )
813 #define SAMR_VALIDATE_FIELD_PASSWORD_HISTORY_LENGTH ( 0x00000010 )
814 #define SAMR_VALIDATE_FIELD_PASSWORD_HISTORY ( 0x00000020 )
816 enum samr_ValidatePasswordLevel
817 #ifndef USE_UINT_ENUMS
819 NetValidateAuthentication=1,
820 NetValidatePasswordChange=2,
821 NetValidatePasswordReset=3
823 #else
824 { __donnot_use_enum_samr_ValidatePasswordLevel=0x7FFFFFFF}
825 #define NetValidateAuthentication ( 1 )
826 #define NetValidatePasswordChange ( 2 )
827 #define NetValidatePasswordReset ( 3 )
828 #endif
831 enum samr_ValidationStatus
832 #ifndef USE_UINT_ENUMS
834 SAMR_VALIDATION_STATUS_SUCCESS=0,
835 SAMR_VALIDATION_STATUS_PASSWORD_MUST_CHANGE=1,
836 SAMR_VALIDATION_STATUS_ACCOUNT_LOCKED_OUT=2,
837 SAMR_VALIDATION_STATUS_PASSWORD_EXPIRED=3,
838 SAMR_VALIDATION_STATUS_BAD_PASSWORD=4,
839 SAMR_VALIDATION_STATUS_PWD_HISTORY_CONFLICT=5,
840 SAMR_VALIDATION_STATUS_PWD_TOO_SHORT=6,
841 SAMR_VALIDATION_STATUS_PWD_TOO_LONG=7,
842 SAMR_VALIDATION_STATUS_NOT_COMPLEX_ENOUGH=8,
843 SAMR_VALIDATION_STATUS_PASSWORD_TOO_RECENT=9,
844 SAMR_VALIDATION_STATUS_PASSWORD_FILTER_ERROR=10
846 #else
847 { __donnot_use_enum_samr_ValidationStatus=0x7FFFFFFF}
848 #define SAMR_VALIDATION_STATUS_SUCCESS ( 0 )
849 #define SAMR_VALIDATION_STATUS_PASSWORD_MUST_CHANGE ( 1 )
850 #define SAMR_VALIDATION_STATUS_ACCOUNT_LOCKED_OUT ( 2 )
851 #define SAMR_VALIDATION_STATUS_PASSWORD_EXPIRED ( 3 )
852 #define SAMR_VALIDATION_STATUS_BAD_PASSWORD ( 4 )
853 #define SAMR_VALIDATION_STATUS_PWD_HISTORY_CONFLICT ( 5 )
854 #define SAMR_VALIDATION_STATUS_PWD_TOO_SHORT ( 6 )
855 #define SAMR_VALIDATION_STATUS_PWD_TOO_LONG ( 7 )
856 #define SAMR_VALIDATION_STATUS_NOT_COMPLEX_ENOUGH ( 8 )
857 #define SAMR_VALIDATION_STATUS_PASSWORD_TOO_RECENT ( 9 )
858 #define SAMR_VALIDATION_STATUS_PASSWORD_FILTER_ERROR ( 10 )
859 #endif
862 struct samr_ValidationBlob {
863 uint32_t length;
864 uint8_t *data;/* [unique,size_is(length)] */
867 struct samr_ValidatePasswordInfo {
868 uint32_t fields_present;
869 NTTIME last_password_change;
870 NTTIME bad_password_time;
871 NTTIME lockout_time;
872 uint32_t bad_pwd_count;
873 uint32_t pwd_history_len;
874 struct samr_ValidationBlob *pwd_history;/* [unique,size_is(pwd_history_len)] */
877 struct samr_ValidatePasswordRepCtr {
878 struct samr_ValidatePasswordInfo info;
879 enum samr_ValidationStatus status;
882 union samr_ValidatePasswordRep {
883 struct samr_ValidatePasswordRepCtr ctr1;/* [case] */
884 struct samr_ValidatePasswordRepCtr ctr2;/* [case(2)] */
885 struct samr_ValidatePasswordRepCtr ctr3;/* [case(3)] */
886 }/* [switch_type(uint16)] */;
888 struct samr_ValidatePasswordReq3 {
889 struct samr_ValidatePasswordInfo info;
890 struct lsa_StringLarge password;
891 struct lsa_StringLarge account;
892 struct samr_ValidationBlob hash;
893 uint8_t pwd_must_change_at_next_logon;
894 uint8_t clear_lockout;
897 struct samr_ValidatePasswordReq2 {
898 struct samr_ValidatePasswordInfo info;
899 struct lsa_StringLarge password;
900 struct lsa_StringLarge account;
901 struct samr_ValidationBlob hash;
902 uint8_t password_matched;
905 struct samr_ValidatePasswordReq1 {
906 struct samr_ValidatePasswordInfo info;
907 uint8_t password_matched;
910 union samr_ValidatePasswordReq {
911 struct samr_ValidatePasswordReq1 req1;/* [case] */
912 struct samr_ValidatePasswordReq2 req2;/* [case(2)] */
913 struct samr_ValidatePasswordReq3 req3;/* [case(3)] */
914 }/* [switch_type(uint16)] */;
917 struct samr_Connect {
918 struct {
919 uint16_t *system_name;/* [unique] */
920 uint32_t access_mask;
921 } in;
923 struct {
924 struct policy_handle *connect_handle;/* [ref] */
925 NTSTATUS result;
926 } out;
931 struct samr_Close {
932 struct {
933 struct policy_handle *handle;/* [ref] */
934 } in;
936 struct {
937 struct policy_handle *handle;/* [ref] */
938 NTSTATUS result;
939 } out;
944 struct samr_SetSecurity {
945 struct {
946 struct policy_handle *handle;/* [ref] */
947 uint32_t sec_info;
948 struct sec_desc_buf *sdbuf;/* [ref] */
949 } in;
951 struct {
952 NTSTATUS result;
953 } out;
958 struct samr_QuerySecurity {
959 struct {
960 struct policy_handle *handle;/* [ref] */
961 uint32_t sec_info;
962 } in;
964 struct {
965 struct sec_desc_buf **sdbuf;/* [ref] */
966 NTSTATUS result;
967 } out;
972 struct samr_Shutdown {
973 struct {
974 struct policy_handle *connect_handle;/* [ref] */
975 } in;
977 struct {
978 NTSTATUS result;
979 } out;
984 struct samr_LookupDomain {
985 struct {
986 struct policy_handle *connect_handle;/* [ref] */
987 struct lsa_String *domain_name;/* [ref] */
988 } in;
990 struct {
991 struct dom_sid2 **sid;/* [ref] */
992 NTSTATUS result;
993 } out;
998 struct samr_EnumDomains {
999 struct {
1000 struct policy_handle *connect_handle;/* [ref] */
1001 uint32_t buf_size;
1002 uint32_t *resume_handle;/* [ref] */
1003 } in;
1005 struct {
1006 struct samr_SamArray **sam;/* [ref] */
1007 uint32_t *num_entries;/* [ref] */
1008 uint32_t *resume_handle;/* [ref] */
1009 NTSTATUS result;
1010 } out;
1015 struct samr_OpenDomain {
1016 struct {
1017 struct policy_handle *connect_handle;/* [ref] */
1018 uint32_t access_mask;
1019 struct dom_sid2 *sid;/* [ref] */
1020 } in;
1022 struct {
1023 struct policy_handle *domain_handle;/* [ref] */
1024 NTSTATUS result;
1025 } out;
1030 struct samr_QueryDomainInfo {
1031 struct {
1032 struct policy_handle *domain_handle;/* [ref] */
1033 enum samr_DomainInfoClass level;
1034 } in;
1036 struct {
1037 union samr_DomainInfo **info;/* [ref,switch_is(level)] */
1038 NTSTATUS result;
1039 } out;
1044 struct samr_SetDomainInfo {
1045 struct {
1046 struct policy_handle *domain_handle;/* [ref] */
1047 enum samr_DomainInfoClass level;
1048 union samr_DomainInfo *info;/* [ref,switch_is(level)] */
1049 } in;
1051 struct {
1052 NTSTATUS result;
1053 } out;
1058 struct samr_CreateDomainGroup {
1059 struct {
1060 struct policy_handle *domain_handle;/* [ref] */
1061 struct lsa_String *name;/* [ref] */
1062 uint32_t access_mask;
1063 } in;
1065 struct {
1066 struct policy_handle *group_handle;/* [ref] */
1067 uint32_t *rid;/* [ref] */
1068 NTSTATUS result;
1069 } out;
1074 struct samr_EnumDomainGroups {
1075 struct {
1076 struct policy_handle *domain_handle;/* [ref] */
1077 uint32_t max_size;
1078 uint32_t *resume_handle;/* [ref] */
1079 } in;
1081 struct {
1082 struct samr_SamArray **sam;/* [ref] */
1083 uint32_t *num_entries;/* [ref] */
1084 uint32_t *resume_handle;/* [ref] */
1085 NTSTATUS result;
1086 } out;
1091 struct samr_CreateUser {
1092 struct {
1093 struct policy_handle *domain_handle;/* [ref] */
1094 struct lsa_String *account_name;/* [ref] */
1095 uint32_t access_mask;
1096 } in;
1098 struct {
1099 struct policy_handle *user_handle;/* [ref] */
1100 uint32_t *rid;/* [ref] */
1101 NTSTATUS result;
1102 } out;
1107 struct samr_EnumDomainUsers {
1108 struct {
1109 struct policy_handle *domain_handle;/* [ref] */
1110 uint32_t acct_flags;
1111 uint32_t max_size;
1112 uint32_t *resume_handle;/* [ref] */
1113 } in;
1115 struct {
1116 struct samr_SamArray **sam;/* [ref] */
1117 uint32_t *num_entries;/* [ref] */
1118 uint32_t *resume_handle;/* [ref] */
1119 NTSTATUS result;
1120 } out;
1125 struct samr_CreateDomAlias {
1126 struct {
1127 struct policy_handle *domain_handle;/* [ref] */
1128 struct lsa_String *alias_name;/* [ref] */
1129 uint32_t access_mask;
1130 } in;
1132 struct {
1133 struct policy_handle *alias_handle;/* [ref] */
1134 uint32_t *rid;/* [ref] */
1135 NTSTATUS result;
1136 } out;
1141 struct samr_EnumDomainAliases {
1142 struct {
1143 struct policy_handle *domain_handle;/* [ref] */
1144 uint32_t max_size;
1145 uint32_t *resume_handle;/* [ref] */
1146 } in;
1148 struct {
1149 struct samr_SamArray **sam;/* [ref] */
1150 uint32_t *num_entries;/* [ref] */
1151 uint32_t *resume_handle;/* [ref] */
1152 NTSTATUS result;
1153 } out;
1158 struct samr_GetAliasMembership {
1159 struct {
1160 struct policy_handle *domain_handle;/* [ref] */
1161 struct lsa_SidArray *sids;/* [ref] */
1162 } in;
1164 struct {
1165 struct samr_Ids *rids;/* [ref] */
1166 NTSTATUS result;
1167 } out;
1172 struct samr_LookupNames {
1173 struct {
1174 struct policy_handle *domain_handle;/* [ref] */
1175 uint32_t num_names;/* [range(0,1000)] */
1176 struct lsa_String *names;/* [length_is(num_names),size_is(1000)] */
1177 } in;
1179 struct {
1180 struct samr_Ids *rids;/* [ref] */
1181 struct samr_Ids *types;/* [ref] */
1182 NTSTATUS result;
1183 } out;
1188 struct samr_LookupRids {
1189 struct {
1190 struct policy_handle *domain_handle;/* [ref] */
1191 uint32_t num_rids;/* [range(0,1000)] */
1192 uint32_t *rids;/* [length_is(num_rids),size_is(1000)] */
1193 } in;
1195 struct {
1196 struct lsa_Strings *names;/* [ref] */
1197 struct samr_Ids *types;/* [ref] */
1198 NTSTATUS result;
1199 } out;
1204 struct samr_OpenGroup {
1205 struct {
1206 struct policy_handle *domain_handle;/* [ref] */
1207 uint32_t access_mask;
1208 uint32_t rid;
1209 } in;
1211 struct {
1212 struct policy_handle *group_handle;/* [ref] */
1213 NTSTATUS result;
1214 } out;
1219 struct samr_QueryGroupInfo {
1220 struct {
1221 struct policy_handle *group_handle;/* [ref] */
1222 enum samr_GroupInfoEnum level;
1223 } in;
1225 struct {
1226 union samr_GroupInfo **info;/* [ref,switch_is(level)] */
1227 NTSTATUS result;
1228 } out;
1233 struct samr_SetGroupInfo {
1234 struct {
1235 struct policy_handle *group_handle;/* [ref] */
1236 enum samr_GroupInfoEnum level;
1237 union samr_GroupInfo *info;/* [ref,switch_is(level)] */
1238 } in;
1240 struct {
1241 NTSTATUS result;
1242 } out;
1247 struct samr_AddGroupMember {
1248 struct {
1249 struct policy_handle *group_handle;/* [ref] */
1250 uint32_t rid;
1251 uint32_t flags;
1252 } in;
1254 struct {
1255 NTSTATUS result;
1256 } out;
1261 struct samr_DeleteDomainGroup {
1262 struct {
1263 struct policy_handle *group_handle;/* [ref] */
1264 } in;
1266 struct {
1267 struct policy_handle *group_handle;/* [ref] */
1268 NTSTATUS result;
1269 } out;
1274 struct samr_DeleteGroupMember {
1275 struct {
1276 struct policy_handle *group_handle;/* [ref] */
1277 uint32_t rid;
1278 } in;
1280 struct {
1281 NTSTATUS result;
1282 } out;
1287 struct samr_QueryGroupMember {
1288 struct {
1289 struct policy_handle *group_handle;/* [ref] */
1290 } in;
1292 struct {
1293 struct samr_RidTypeArray **rids;/* [ref] */
1294 NTSTATUS result;
1295 } out;
1300 struct samr_SetMemberAttributesOfGroup {
1301 struct {
1302 struct policy_handle *group_handle;/* [ref] */
1303 uint32_t unknown1;
1304 uint32_t unknown2;
1305 } in;
1307 struct {
1308 NTSTATUS result;
1309 } out;
1314 struct samr_OpenAlias {
1315 struct {
1316 struct policy_handle *domain_handle;/* [ref] */
1317 uint32_t access_mask;
1318 uint32_t rid;
1319 } in;
1321 struct {
1322 struct policy_handle *alias_handle;/* [ref] */
1323 NTSTATUS result;
1324 } out;
1329 struct samr_QueryAliasInfo {
1330 struct {
1331 struct policy_handle *alias_handle;/* [ref] */
1332 enum samr_AliasInfoEnum level;
1333 } in;
1335 struct {
1336 union samr_AliasInfo **info;/* [ref,switch_is(level)] */
1337 NTSTATUS result;
1338 } out;
1343 struct samr_SetAliasInfo {
1344 struct {
1345 struct policy_handle *alias_handle;/* [ref] */
1346 enum samr_AliasInfoEnum level;
1347 union samr_AliasInfo *info;/* [ref,switch_is(level)] */
1348 } in;
1350 struct {
1351 NTSTATUS result;
1352 } out;
1357 struct samr_DeleteDomAlias {
1358 struct {
1359 struct policy_handle *alias_handle;/* [ref] */
1360 } in;
1362 struct {
1363 struct policy_handle *alias_handle;/* [ref] */
1364 NTSTATUS result;
1365 } out;
1370 struct samr_AddAliasMember {
1371 struct {
1372 struct policy_handle *alias_handle;/* [ref] */
1373 struct dom_sid2 *sid;/* [ref] */
1374 } in;
1376 struct {
1377 NTSTATUS result;
1378 } out;
1383 struct samr_DeleteAliasMember {
1384 struct {
1385 struct policy_handle *alias_handle;/* [ref] */
1386 struct dom_sid2 *sid;/* [ref] */
1387 } in;
1389 struct {
1390 NTSTATUS result;
1391 } out;
1396 struct samr_GetMembersInAlias {
1397 struct {
1398 struct policy_handle *alias_handle;/* [ref] */
1399 } in;
1401 struct {
1402 struct lsa_SidArray *sids;/* [ref] */
1403 NTSTATUS result;
1404 } out;
1409 struct samr_OpenUser {
1410 struct {
1411 struct policy_handle *domain_handle;/* [ref] */
1412 uint32_t access_mask;
1413 uint32_t rid;
1414 } in;
1416 struct {
1417 struct policy_handle *user_handle;/* [ref] */
1418 NTSTATUS result;
1419 } out;
1424 struct samr_DeleteUser {
1425 struct {
1426 struct policy_handle *user_handle;/* [ref] */
1427 } in;
1429 struct {
1430 struct policy_handle *user_handle;/* [ref] */
1431 NTSTATUS result;
1432 } out;
1437 struct samr_QueryUserInfo {
1438 struct {
1439 struct policy_handle *user_handle;/* [ref] */
1440 enum samr_UserInfoLevel level;
1441 } in;
1443 struct {
1444 union samr_UserInfo **info;/* [ref,switch_is(level)] */
1445 NTSTATUS result;
1446 } out;
1451 struct samr_SetUserInfo {
1452 struct {
1453 struct policy_handle *user_handle;/* [ref] */
1454 enum samr_UserInfoLevel level;
1455 union samr_UserInfo *info;/* [ref,switch_is(level)] */
1456 } in;
1458 struct {
1459 NTSTATUS result;
1460 } out;
1465 struct samr_ChangePasswordUser {
1466 struct {
1467 struct policy_handle *user_handle;/* [ref] */
1468 uint8_t lm_present;
1469 struct samr_Password *old_lm_crypted;/* [unique] */
1470 struct samr_Password *new_lm_crypted;/* [unique] */
1471 uint8_t nt_present;
1472 struct samr_Password *old_nt_crypted;/* [unique] */
1473 struct samr_Password *new_nt_crypted;/* [unique] */
1474 uint8_t cross1_present;
1475 struct samr_Password *nt_cross;/* [unique] */
1476 uint8_t cross2_present;
1477 struct samr_Password *lm_cross;/* [unique] */
1478 } in;
1480 struct {
1481 NTSTATUS result;
1482 } out;
1487 struct samr_GetGroupsForUser {
1488 struct {
1489 struct policy_handle *user_handle;/* [ref] */
1490 } in;
1492 struct {
1493 struct samr_RidWithAttributeArray **rids;/* [ref] */
1494 NTSTATUS result;
1495 } out;
1500 struct samr_QueryDisplayInfo {
1501 struct {
1502 struct policy_handle *domain_handle;/* [ref] */
1503 uint16_t level;
1504 uint32_t start_idx;
1505 uint32_t max_entries;
1506 uint32_t buf_size;
1507 } in;
1509 struct {
1510 uint32_t *total_size;/* [ref] */
1511 uint32_t *returned_size;/* [ref] */
1512 union samr_DispInfo *info;/* [ref,switch_is(level)] */
1513 NTSTATUS result;
1514 } out;
1519 struct samr_GetDisplayEnumerationIndex {
1520 struct {
1521 struct policy_handle *domain_handle;/* [ref] */
1522 uint16_t level;
1523 struct lsa_String *name;/* [ref] */
1524 } in;
1526 struct {
1527 uint32_t *idx;/* [ref] */
1528 NTSTATUS result;
1529 } out;
1534 struct samr_TestPrivateFunctionsDomain {
1535 struct {
1536 struct policy_handle *domain_handle;/* [ref] */
1537 } in;
1539 struct {
1540 NTSTATUS result;
1541 } out;
1546 struct samr_TestPrivateFunctionsUser {
1547 struct {
1548 struct policy_handle *user_handle;/* [ref] */
1549 } in;
1551 struct {
1552 NTSTATUS result;
1553 } out;
1558 struct samr_GetUserPwInfo {
1559 struct {
1560 struct policy_handle *user_handle;/* [ref] */
1561 } in;
1563 struct {
1564 struct samr_PwInfo *info;/* [ref] */
1565 NTSTATUS result;
1566 } out;
1571 struct samr_RemoveMemberFromForeignDomain {
1572 struct {
1573 struct policy_handle *domain_handle;/* [ref] */
1574 struct dom_sid2 *sid;/* [ref] */
1575 } in;
1577 struct {
1578 NTSTATUS result;
1579 } out;
1584 struct samr_QueryDomainInfo2 {
1585 struct {
1586 struct policy_handle *domain_handle;/* [ref] */
1587 enum samr_DomainInfoClass level;
1588 } in;
1590 struct {
1591 union samr_DomainInfo **info;/* [ref,switch_is(level)] */
1592 NTSTATUS result;
1593 } out;
1598 struct samr_QueryUserInfo2 {
1599 struct {
1600 struct policy_handle *user_handle;/* [ref] */
1601 enum samr_UserInfoLevel level;
1602 } in;
1604 struct {
1605 union samr_UserInfo **info;/* [ref,switch_is(level)] */
1606 NTSTATUS result;
1607 } out;
1612 struct samr_QueryDisplayInfo2 {
1613 struct {
1614 struct policy_handle *domain_handle;/* [ref] */
1615 uint16_t level;
1616 uint32_t start_idx;
1617 uint32_t max_entries;
1618 uint32_t buf_size;
1619 } in;
1621 struct {
1622 uint32_t *total_size;/* [ref] */
1623 uint32_t *returned_size;/* [ref] */
1624 union samr_DispInfo *info;/* [ref,switch_is(level)] */
1625 NTSTATUS result;
1626 } out;
1631 struct samr_GetDisplayEnumerationIndex2 {
1632 struct {
1633 struct policy_handle *domain_handle;/* [ref] */
1634 uint16_t level;
1635 struct lsa_String *name;/* [ref] */
1636 } in;
1638 struct {
1639 uint32_t *idx;/* [ref] */
1640 NTSTATUS result;
1641 } out;
1646 struct samr_CreateUser2 {
1647 struct {
1648 struct policy_handle *domain_handle;/* [ref] */
1649 struct lsa_String *account_name;/* [ref] */
1650 uint32_t acct_flags;
1651 uint32_t access_mask;
1652 } in;
1654 struct {
1655 struct policy_handle *user_handle;/* [ref] */
1656 uint32_t *access_granted;/* [ref] */
1657 uint32_t *rid;/* [ref] */
1658 NTSTATUS result;
1659 } out;
1664 struct samr_QueryDisplayInfo3 {
1665 struct {
1666 struct policy_handle *domain_handle;/* [ref] */
1667 uint16_t level;
1668 uint32_t start_idx;
1669 uint32_t max_entries;
1670 uint32_t buf_size;
1671 } in;
1673 struct {
1674 uint32_t *total_size;/* [ref] */
1675 uint32_t *returned_size;/* [ref] */
1676 union samr_DispInfo *info;/* [ref,switch_is(level)] */
1677 NTSTATUS result;
1678 } out;
1683 struct samr_AddMultipleMembersToAlias {
1684 struct {
1685 struct policy_handle *alias_handle;/* [ref] */
1686 struct lsa_SidArray *sids;/* [ref] */
1687 } in;
1689 struct {
1690 NTSTATUS result;
1691 } out;
1696 struct samr_RemoveMultipleMembersFromAlias {
1697 struct {
1698 struct policy_handle *alias_handle;/* [ref] */
1699 struct lsa_SidArray *sids;/* [ref] */
1700 } in;
1702 struct {
1703 NTSTATUS result;
1704 } out;
1709 struct samr_OemChangePasswordUser2 {
1710 struct {
1711 struct lsa_AsciiString *server;/* [unique] */
1712 struct lsa_AsciiString *account;/* [ref] */
1713 struct samr_CryptPassword *password;/* [unique] */
1714 struct samr_Password *hash;/* [unique] */
1715 } in;
1717 struct {
1718 NTSTATUS result;
1719 } out;
1724 struct samr_ChangePasswordUser2 {
1725 struct {
1726 struct lsa_String *server;/* [unique] */
1727 struct lsa_String *account;/* [ref] */
1728 struct samr_CryptPassword *nt_password;/* [unique] */
1729 struct samr_Password *nt_verifier;/* [unique] */
1730 uint8_t lm_change;
1731 struct samr_CryptPassword *lm_password;/* [unique] */
1732 struct samr_Password *lm_verifier;/* [unique] */
1733 } in;
1735 struct {
1736 NTSTATUS result;
1737 } out;
1742 struct samr_GetDomPwInfo {
1743 struct {
1744 struct lsa_String *domain_name;/* [unique] */
1745 } in;
1747 struct {
1748 struct samr_PwInfo *info;/* [ref] */
1749 NTSTATUS result;
1750 } out;
1755 struct samr_Connect2 {
1756 struct {
1757 const char *system_name;/* [unique,charset(UTF16)] */
1758 uint32_t access_mask;
1759 } in;
1761 struct {
1762 struct policy_handle *connect_handle;/* [ref] */
1763 NTSTATUS result;
1764 } out;
1769 struct samr_SetUserInfo2 {
1770 struct {
1771 struct policy_handle *user_handle;/* [ref] */
1772 enum samr_UserInfoLevel level;
1773 union samr_UserInfo *info;/* [ref,switch_is(level)] */
1774 } in;
1776 struct {
1777 NTSTATUS result;
1778 } out;
1783 struct samr_SetBootKeyInformation {
1784 struct {
1785 struct policy_handle *connect_handle;/* [ref] */
1786 uint32_t unknown1;
1787 uint32_t unknown2;
1788 uint32_t unknown3;
1789 } in;
1791 struct {
1792 NTSTATUS result;
1793 } out;
1798 struct samr_GetBootKeyInformation {
1799 struct {
1800 struct policy_handle *domain_handle;/* [ref] */
1801 } in;
1803 struct {
1804 uint32_t *unknown;/* [ref] */
1805 NTSTATUS result;
1806 } out;
1811 struct samr_Connect3 {
1812 struct {
1813 const char *system_name;/* [unique,charset(UTF16)] */
1814 uint32_t unknown;
1815 uint32_t access_mask;
1816 } in;
1818 struct {
1819 struct policy_handle *connect_handle;/* [ref] */
1820 NTSTATUS result;
1821 } out;
1826 struct samr_Connect4 {
1827 struct {
1828 const char *system_name;/* [unique,charset(UTF16)] */
1829 enum samr_ConnectVersion client_version;
1830 uint32_t access_mask;
1831 } in;
1833 struct {
1834 struct policy_handle *connect_handle;/* [ref] */
1835 NTSTATUS result;
1836 } out;
1841 struct samr_ChangePasswordUser3 {
1842 struct {
1843 struct lsa_String *server;/* [unique] */
1844 struct lsa_String *account;/* [ref] */
1845 struct samr_CryptPassword *nt_password;/* [unique] */
1846 struct samr_Password *nt_verifier;/* [unique] */
1847 uint8_t lm_change;
1848 struct samr_CryptPassword *lm_password;/* [unique] */
1849 struct samr_Password *lm_verifier;/* [unique] */
1850 struct samr_CryptPassword *password3;/* [unique] */
1851 } in;
1853 struct {
1854 struct samr_DomInfo1 **dominfo;/* [ref] */
1855 struct samr_ChangeReject **reject;/* [ref] */
1856 NTSTATUS result;
1857 } out;
1862 struct samr_Connect5 {
1863 struct {
1864 const char *system_name;/* [unique,charset(UTF16)] */
1865 uint32_t access_mask;
1866 uint32_t level_in;
1867 union samr_ConnectInfo *info_in;/* [ref,switch_is(level_in)] */
1868 } in;
1870 struct {
1871 uint32_t *level_out;/* [ref] */
1872 union samr_ConnectInfo *info_out;/* [ref,switch_is(*level_out)] */
1873 struct policy_handle *connect_handle;/* [ref] */
1874 NTSTATUS result;
1875 } out;
1880 struct samr_RidToSid {
1881 struct {
1882 struct policy_handle *domain_handle;/* [ref] */
1883 uint32_t rid;
1884 } in;
1886 struct {
1887 struct dom_sid2 **sid;/* [ref] */
1888 NTSTATUS result;
1889 } out;
1894 struct samr_SetDsrmPassword {
1895 struct {
1896 struct lsa_String *name;/* [unique] */
1897 uint32_t unknown;
1898 struct samr_Password *hash;/* [unique] */
1899 } in;
1901 struct {
1902 NTSTATUS result;
1903 } out;
1908 struct samr_ValidatePassword {
1909 struct {
1910 enum samr_ValidatePasswordLevel level;
1911 union samr_ValidatePasswordReq *req;/* [ref,switch_is(level)] */
1912 } in;
1914 struct {
1915 union samr_ValidatePasswordRep **rep;/* [ref,switch_is(level)] */
1916 NTSTATUS result;
1917 } out;
1921 #endif /* _HEADER_samr */