11typedef struct _RPC_STRING
13 unsigned short Length;
14 unsigned short MaximumLength;
15 [size_is(MaximumLength), length_is(Length)] char *Buffer;
16} RPC_STRING, *PRPC_STRING;
18typedef struct _OLD_LARGE_INTEGER
20 unsigned long LowPart;
22} OLD_LARGE_INTEGER, *POLD_LARGE_INTEGER;
24typedef [handle] wchar_t *PSAMPR_SERVER_NAME;
26typedef [context_handle] void *SAMPR_HANDLE;
28typedef struct _ENCRYPTED_LM_OWF_PASSWORD
31} LM_OWF_PASSWORD, *PLM_OWF_PASSWORD,
32 NT_OWF_PASSWORD, *PNT_OWF_PASSWORD,
33 ENCRYPTED_LM_OWF_PASSWORD, *PENCRYPTED_LM_OWF_PASSWORD,
34 ENCRYPTED_NT_OWF_PASSWORD, *PENCRYPTED_NT_OWF_PASSWORD;
36typedef struct _SAMPR_ULONG_ARRAY
39 [size_is(Count)] unsigned long *Element;
40} SAMPR_ULONG_ARRAY, *PSAMPR_ULONG_ARRAY;
42typedef struct _SAMPR_SID_INFORMATION
45} SAMPR_SID_INFORMATION, *PSAMPR_SID_INFORMATION;
47typedef struct _SAMPR_PSID_ARRAY
49 [range(0, 1024)] unsigned long Count;
50 [size_is(Count)] PSAMPR_SID_INFORMATION Sids;
51} SAMPR_PSID_ARRAY, *PSAMPR_PSID_ARRAY;
53typedef struct _SAMPR_PSID_ARRAY_OUT
56 [size_is(Count)] PSAMPR_SID_INFORMATION Sids;
57} SAMPR_PSID_ARRAY_OUT, *PSAMPR_PSID_ARRAY_OUT;
59typedef struct _SAMPR_RETURNED_USTRING_ARRAY
62 [size_is(Count)] PRPC_UNICODE_STRING Element;
63} SAMPR_RETURNED_USTRING_ARRAY, *PSAMPR_RETURNED_USTRING_ARRAY;
65cpp_quote("#ifndef _WINNT_")
66typedef enum _SID_NAME_USE
72 SidTypeWellKnownGroup,
73 SidTypeDeletedAccount,
76} SID_NAME_USE, *PSID_NAME_USE;
79typedef struct RPC_SHORT_BLOB
81 unsigned short Length;
82 unsigned short MaximumLength;
83 [size_is(MaximumLength/2), length_is(Length/2)]
84 unsigned short* Buffer;
85} RPC_SHORT_BLOB, *PRPC_SHORT_BLOB;
87typedef struct _SAMPR_RID_ENUMERATION
89 unsigned long RelativeId;
90 RPC_UNICODE_STRING Name;
91} SAMPR_RID_ENUMERATION, *PSAMPR_RID_ENUMERATION;
93typedef struct _SAMPR_ENUMERATION_BUFFER
95 unsigned long EntriesRead;
96 [size_is(EntriesRead)] PSAMPR_RID_ENUMERATION Buffer;
97} SAMPR_ENUMERATION_BUFFER, *PSAMPR_ENUMERATION_BUFFER;
99typedef struct _SAMPR_SR_SECURITY_DESCRIPTOR
101 [range(0, 256 * 1024)] unsigned long Length;
102 [size_is(Length)] unsigned char* SecurityDescriptor;
103} SAMPR_SR_SECURITY_DESCRIPTOR, *PSAMPR_SR_SECURITY_DESCRIPTOR;
105cpp_quote("#ifndef _NTSAM_")
106typedef struct _GROUP_MEMBERSHIP
108 unsigned long RelativeId;
109 unsigned long Attributes;
110} GROUP_MEMBERSHIP, *PGROUP_MEMBERSHIP;
113typedef struct _SAMPR_GET_GROUPS_BUFFER
115 unsigned long MembershipCount;
116 [size_is(MembershipCount)] PGROUP_MEMBERSHIP Groups;
117} SAMPR_GET_GROUPS_BUFFER, *PSAMPR_GET_GROUPS_BUFFER;
119typedef struct _SAMPR_GET_MEMBERS_BUFFER
121 unsigned long MemberCount;
122 [size_is(MemberCount)] unsigned long* Members;
123 [size_is(MemberCount)] unsigned long* Attributes;
124} SAMPR_GET_MEMBERS_BUFFER, *PSAMPR_GET_MEMBERS_BUFFER;
126typedef struct _SAMPR_REVISION_INFO_V1
128 unsigned long Revision;
129 unsigned long SupportedFeatures;
130} SAMPR_REVISION_INFO_V1, *PSAMPR_REVISION_INFO_V1;
132typedef [switch_type(unsigned long)] union
134 [case(1)] SAMPR_REVISION_INFO_V1 V1;
135}SAMPR_REVISION_INFO, *PSAMPR_REVISION_INFO;
137typedef struct _USER_DOMAIN_PASSWORD_INFORMATION
139 unsigned short MinPasswordLength;
140 unsigned long PasswordProperties;
141} USER_DOMAIN_PASSWORD_INFORMATION, *PUSER_DOMAIN_PASSWORD_INFORMATION;
143cpp_quote("#ifndef _NTSAM_")
144typedef enum _DOMAIN_SERVER_ENABLE_STATE
146 DomainServerEnabled = 1,
148} DOMAIN_SERVER_ENABLE_STATE, *PDOMAIN_SERVER_ENABLE_STATE;
150typedef struct _DOMAIN_STATE_INFORMATION
152 DOMAIN_SERVER_ENABLE_STATE DomainServerState;
153} DOMAIN_STATE_INFORMATION, *PDOMAIN_STATE_INFORMATION;
156cpp_quote("#ifndef _NTSAM_")
157typedef enum _DOMAIN_SERVER_ROLE
159 DomainServerRoleBackup = 2,
160 DomainServerRolePrimary = 3
161} DOMAIN_SERVER_ROLE, *PDOMAIN_SERVER_ROLE;
164cpp_quote("#if !defined(_NTSECAPI_H) && !defined(_NTSAM_)")
165typedef struct _DOMAIN_PASSWORD_INFORMATION
167 USHORT MinPasswordLength;
168 USHORT PasswordHistoryLength;
169 ULONG PasswordProperties;
170 OLD_LARGE_INTEGER MaxPasswordAge;
171 OLD_LARGE_INTEGER MinPasswordAge;
172} DOMAIN_PASSWORD_INFORMATION, *PDOMAIN_PASSWORD_INFORMATION;
175cpp_quote("#ifndef _NTSAM_")
176typedef struct _DOMAIN_LOGOFF_INFORMATION
178 OLD_LARGE_INTEGER ForceLogoff;
179} DOMAIN_LOGOFF_INFORMATION, *PDOMAIN_LOGOFF_INFORMATION;
181typedef struct _DOMAIN_SERVER_ROLE_INFORMATION
183 DOMAIN_SERVER_ROLE DomainServerRole;
184} DOMAIN_SERVER_ROLE_INFORMATION, *PDOMAIN_SERVER_ROLE_INFORMATION;
186typedef struct _DOMAIN_MODIFIED_INFORMATION
188 OLD_LARGE_INTEGER DomainModifiedCount;
189 OLD_LARGE_INTEGER CreationTime;
190} DOMAIN_MODIFIED_INFORMATION, *PDOMAIN_MODIFIED_INFORMATION;
192typedef struct _DOMAIN_MODIFIED_INFORMATION2
194 OLD_LARGE_INTEGER DomainModifiedCount;
195 OLD_LARGE_INTEGER CreationTime;
196 OLD_LARGE_INTEGER ModifiedCountAtLastPromotion;
197} DOMAIN_MODIFIED_INFORMATION2, *PDOMAIN_MODIFIED_INFORMATION2;
200cpp_quote("#include <pshpack4.h>")
201typedef struct _SAMPR_DOMAIN_GENERAL_INFORMATION
203 OLD_LARGE_INTEGER ForceLogoff;
204 RPC_UNICODE_STRING OemInformation;
205 RPC_UNICODE_STRING DomainName;
206 RPC_UNICODE_STRING ReplicaSourceNodeName;
207 OLD_LARGE_INTEGER DomainModifiedCount;
208 unsigned long DomainServerState;
209 unsigned long DomainServerRole;
210 unsigned char UasCompatibilityRequired;
211 unsigned long UserCount;
212 unsigned long GroupCount;
213 unsigned long AliasCount;
214} SAMPR_DOMAIN_GENERAL_INFORMATION, *PSAMPR_DOMAIN_GENERAL_INFORMATION;
216typedef struct _SAMPR_DOMAIN_GENERAL_INFORMATION2
218 SAMPR_DOMAIN_GENERAL_INFORMATION I1;
219 LARGE_INTEGER LockoutDuration;
220 LARGE_INTEGER LockoutObservationWindow;
221 unsigned short LockoutThreshold;
222} SAMPR_DOMAIN_GENERAL_INFORMATION2, *PSAMPR_DOMAIN_GENERAL_INFORMATION2;
223cpp_quote("#include <poppack.h>")
225typedef struct _SAMPR_DOMAIN_OEM_INFORMATION
227 RPC_UNICODE_STRING OemInformation;
228} SAMPR_DOMAIN_OEM_INFORMATION, *PSAMPR_DOMAIN_OEM_INFORMATION;
230typedef struct _SAMPR_DOMAIN_NAME_INFORMATION
232 RPC_UNICODE_STRING DomainName;
233} SAMPR_DOMAIN_NAME_INFORMATION, *PSAMPR_DOMAIN_NAME_INFORMATION;
235typedef struct SAMPR_DOMAIN_REPLICATION_INFORMATION
237 RPC_UNICODE_STRING ReplicaSourceNodeName;
238} SAMPR_DOMAIN_REPLICATION_INFORMATION, *PSAMPR_DOMAIN_REPLICATION_INFORMATION;
240typedef struct _SAMPR_DOMAIN_LOCKOUT_INFORMATION
242 LARGE_INTEGER LockoutDuration;
243 LARGE_INTEGER LockoutObservationWindow;
244 unsigned short LockoutThreshold;
245} SAMPR_DOMAIN_LOCKOUT_INFORMATION, *PSAMPR_DOMAIN_LOCKOUT_INFORMATION;
247cpp_quote("#ifndef _NTSAM_")
248typedef enum _DOMAIN_INFORMATION_CLASS
250 DomainPasswordInformation = 1,
251 DomainGeneralInformation = 2,
252 DomainLogoffInformation = 3,
253 DomainOemInformation = 4,
254 DomainNameInformation = 5,
255 DomainReplicationInformation = 6,
256 DomainServerRoleInformation = 7,
257 DomainModifiedInformation = 8,
258 DomainStateInformation = 9,
259 DomainGeneralInformation2 = 11,
260 DomainLockoutInformation = 12,
261 DomainModifiedInformation2 = 13
262} DOMAIN_INFORMATION_CLASS;
265typedef [switch_type(DOMAIN_INFORMATION_CLASS)] union _SAMPR_DOMAIN_INFO_BUFFER
267 [case(DomainPasswordInformation)] DOMAIN_PASSWORD_INFORMATION Password;
268 [case(DomainGeneralInformation)] SAMPR_DOMAIN_GENERAL_INFORMATION General;
269 [case(DomainLogoffInformation)] DOMAIN_LOGOFF_INFORMATION Logoff;
270 [case(DomainOemInformation)] SAMPR_DOMAIN_OEM_INFORMATION Oem;
271 [case(DomainNameInformation)] SAMPR_DOMAIN_NAME_INFORMATION Name;
272 [case(DomainServerRoleInformation)] DOMAIN_SERVER_ROLE_INFORMATION Role;
273 [case(DomainReplicationInformation)] SAMPR_DOMAIN_REPLICATION_INFORMATION Replication;
274 [case(DomainModifiedInformation)] DOMAIN_MODIFIED_INFORMATION Modified;
275 [case(DomainStateInformation)] DOMAIN_STATE_INFORMATION State;
276 [case(DomainGeneralInformation2)] SAMPR_DOMAIN_GENERAL_INFORMATION2 General2;
277 [case(DomainLockoutInformation)] SAMPR_DOMAIN_LOCKOUT_INFORMATION Lockout;
278 [case(DomainModifiedInformation2)] DOMAIN_MODIFIED_INFORMATION2 Modified2;
279} SAMPR_DOMAIN_INFO_BUFFER, *PSAMPR_DOMAIN_INFO_BUFFER;
281cpp_quote("#ifndef _NTSAM_")
282typedef enum _DOMAIN_DISPLAY_INFORMATION
284 DomainDisplayUser = 1,
285 DomainDisplayMachine,
287 DomainDisplayOemUser,
288 DomainDisplayOemGroup,
290} DOMAIN_DISPLAY_INFORMATION, *PDOMAIN_DISPLAY_INFORMATION;
293typedef struct _SAMPR_DOMAIN_DISPLAY_USER
297 unsigned long AccountControl;
298 RPC_UNICODE_STRING AccountName;
299 RPC_UNICODE_STRING AdminComment;
300 RPC_UNICODE_STRING FullName;
301} SAMPR_DOMAIN_DISPLAY_USER, *PSAMPR_DOMAIN_DISPLAY_USER;
303typedef struct _SAMPR_DOMAIN_DISPLAY_MACHINE
307 unsigned long AccountControl;
308 RPC_UNICODE_STRING AccountName;
309 RPC_UNICODE_STRING AdminComment;
310} SAMPR_DOMAIN_DISPLAY_MACHINE, *PSAMPR_DOMAIN_DISPLAY_MACHINE;
312typedef struct _SAMPR_DOMAIN_DISPLAY_GROUP
316 unsigned long Attributes;
317 RPC_UNICODE_STRING AccountName;
318 RPC_UNICODE_STRING AdminComment;
319} SAMPR_DOMAIN_DISPLAY_GROUP, *PSAMPR_DOMAIN_DISPLAY_GROUP;
321typedef struct _SAMPR_DOMAIN_DISPLAY_OEM_USER
324 RPC_STRING OemAccountName;
325} SAMPR_DOMAIN_DISPLAY_OEM_USER, *PSAMPR_DOMAIN_DISPLAY_OEM_USER;
327typedef struct _SAMPR_DOMAIN_DISPLAY_OEM_GROUP
330 RPC_STRING OemAccountName;
331} SAMPR_DOMAIN_DISPLAY_OEM_GROUP, *PSAMPR_DOMAIN_DISPLAY_OEM_GROUP;
333typedef struct _SAMPR_DOMAIN_DISPLAY_USER_BUFFER
335 unsigned long EntriesRead;
336 [size_is(EntriesRead)] PSAMPR_DOMAIN_DISPLAY_USER Buffer;
337} SAMPR_DOMAIN_DISPLAY_USER_BUFFER, *PSAMPR_DOMAIN_DISPLAY_USER_BUFFER;
339typedef struct _SAMPR_DOMAIN_DISPLAY_MACHINE_BUFFER
341 unsigned long EntriesRead;
342 [size_is(EntriesRead)] PSAMPR_DOMAIN_DISPLAY_MACHINE Buffer;
343} SAMPR_DOMAIN_DISPLAY_MACHINE_BUFFER, *PSAMPR_DOMAIN_DISPLAY_MACHINE_BUFFER;
345typedef struct _SAMPR_DOMAIN_DISPLAY_GROUP_BUFFER
347 unsigned long EntriesRead;
348 [size_is(EntriesRead)] PSAMPR_DOMAIN_DISPLAY_GROUP Buffer;
349} SAMPR_DOMAIN_DISPLAY_GROUP_BUFFER, *PSAMPR_DOMAIN_DISPLAY_GROUP_BUFFER;
351typedef struct _SAMPR_DOMAIN_DISPLAY_OEM_USER_BUFFER
353 unsigned long EntriesRead;
354 [size_is(EntriesRead)] PSAMPR_DOMAIN_DISPLAY_OEM_USER Buffer;
355} SAMPR_DOMAIN_DISPLAY_OEM_USER_BUFFER, *PSAMPR_DOMAIN_DISPLAY_OEM_USER_BUFFER;
357typedef struct _SAMPR_DOMAIN_DISPLAY_OEM_GROUP_BUFFER
359 unsigned long EntriesRead;
360 [size_is(EntriesRead)] PSAMPR_DOMAIN_DISPLAY_OEM_GROUP Buffer;
361} SAMPR_DOMAIN_DISPLAY_OEM_GROUP_BUFFER, *PSAMPR_DOMAIN_DISPLAY_OEM_GROUP_BUFFER;
363typedef [switch_type(DOMAIN_DISPLAY_INFORMATION)] union _SAMPR_DISPLAY_INFO_BUFFER
365 [case(DomainDisplayUser)] SAMPR_DOMAIN_DISPLAY_USER_BUFFER UserInformation;
366 [case(DomainDisplayMachine)] SAMPR_DOMAIN_DISPLAY_MACHINE_BUFFER MachineInformation;
367 [case(DomainDisplayGroup)] SAMPR_DOMAIN_DISPLAY_GROUP_BUFFER GroupInformation;
368 [case(DomainDisplayOemUser)] SAMPR_DOMAIN_DISPLAY_OEM_USER_BUFFER OemUserInformation;
369 [case(DomainDisplayOemGroup)] SAMPR_DOMAIN_DISPLAY_OEM_GROUP_BUFFER OemGroupInformation;
370} SAMPR_DISPLAY_INFO_BUFFER, *PSAMPR_DISPLAY_INFO_BUFFER;
372typedef struct _SAMPR_GROUP_ATTRIBUTE_INFORMATION
374 unsigned long Attributes;
375} SAMPR_GROUP_ATTRIBUTE_INFORMATION, *PSAMPR_GROUP_ATTRIBUTE_INFORMATION;
377typedef struct _SAMPR_GROUP_GENERAL_INFORMATION
379 RPC_UNICODE_STRING Name;
380 unsigned long Attributes;
381 unsigned long MemberCount;
382 RPC_UNICODE_STRING AdminComment;
383} SAMPR_GROUP_GENERAL_INFORMATION, *PSAMPR_GROUP_GENERAL_INFORMATION;
385typedef struct _SAMPR_GROUP_NAME_INFORMATION
387 RPC_UNICODE_STRING Name;
388} SAMPR_GROUP_NAME_INFORMATION, *PSAMPR_GROUP_NAME_INFORMATION;
390typedef struct _SAMPR_GROUP_ADM_COMMENT_INFORMATION
392 RPC_UNICODE_STRING AdminComment;
393} SAMPR_GROUP_ADM_COMMENT_INFORMATION, *PSAMPR_GROUP_ADM_COMMENT_INFORMATION;
395cpp_quote("#ifndef _NTSAM_")
396typedef enum _GROUP_INFORMATION_CLASS
398 GroupGeneralInformation = 1,
399 GroupNameInformation,
400 GroupAttributeInformation,
401 GroupAdminCommentInformation,
402 GroupReplicationInformation
403} GROUP_INFORMATION_CLASS;
406typedef [switch_type(GROUP_INFORMATION_CLASS)] union _SAMPR_GROUP_INFO_BUFFER
408 [case(GroupGeneralInformation)] SAMPR_GROUP_GENERAL_INFORMATION General;
409 [case(GroupNameInformation)] SAMPR_GROUP_NAME_INFORMATION Name;
410 [case(GroupAttributeInformation)] SAMPR_GROUP_ATTRIBUTE_INFORMATION Attribute;
411 [case(GroupAdminCommentInformation)] SAMPR_GROUP_ADM_COMMENT_INFORMATION AdminComment;
412 [case(GroupReplicationInformation)] SAMPR_GROUP_GENERAL_INFORMATION DoNotUse;
413} SAMPR_GROUP_INFO_BUFFER, *PSAMPR_GROUP_INFO_BUFFER;
415typedef struct _SAMPR_ALIAS_GENERAL_INFORMATION
417 RPC_UNICODE_STRING Name;
419 RPC_UNICODE_STRING AdminComment;
420} SAMPR_ALIAS_GENERAL_INFORMATION, *PSAMPR_ALIAS_GENERAL_INFORMATION;
422typedef struct _SAMPR_ALIAS_NAME_INFORMATION
424 RPC_UNICODE_STRING Name;
425} SAMPR_ALIAS_NAME_INFORMATION, *PSAMPR_ALIAS_NAME_INFORMATION;
427typedef struct _SAMPR_ALIAS_ADM_COMMENT_INFORMATION
429 RPC_UNICODE_STRING AdminComment;
430} SAMPR_ALIAS_ADM_COMMENT_INFORMATION, *PSAMPR_ALIAS_ADM_COMMENT_INFORMATION;
432cpp_quote("#ifndef _NTSAM_")
433typedef enum _ALIAS_INFORMATION_CLASS
435 AliasGeneralInformation = 1,
436 AliasNameInformation,
437 AliasAdminCommentInformation,
438} ALIAS_INFORMATION_CLASS;
441typedef [switch_type(ALIAS_INFORMATION_CLASS)] union _SAMPR_ALIAS_INFO_BUFFER
443 [case(AliasGeneralInformation)] SAMPR_ALIAS_GENERAL_INFORMATION General;
444 [case(AliasNameInformation)] SAMPR_ALIAS_NAME_INFORMATION Name;
445 [case(AliasAdminCommentInformation)] SAMPR_ALIAS_ADM_COMMENT_INFORMATION AdminComment;
446} SAMPR_ALIAS_INFO_BUFFER, *PSAMPR_ALIAS_INFO_BUFFER;
448typedef struct _SAMPR_ENCRYPTED_USER_PASSWORD
450 unsigned char Buffer[(256 * 2) + 4];
451} SAMPR_ENCRYPTED_USER_PASSWORD, *PSAMPR_ENCRYPTED_USER_PASSWORD;
453typedef struct _SAMPR_ENCRYPTED_USER_PASSWORD_NEW
455 unsigned char Buffer[(256 * 2) + 4 + 16];
456} SAMPR_ENCRYPTED_USER_PASSWORD_NEW, *PSAMPR_ENCRYPTED_USER_PASSWORD_NEW;
458cpp_quote("#ifndef _NTSAM_")
459typedef struct _USER_PRIMARY_GROUP_INFORMATION
461 unsigned long PrimaryGroupId;
462} USER_PRIMARY_GROUP_INFORMATION, *PUSER_PRIMARY_GROUP_INFORMATION;
464typedef struct _USER_CONTROL_INFORMATION
466 unsigned long UserAccountControl;
467} USER_CONTROL_INFORMATION, *PUSER_CONTROL_INFORMATION;
469typedef struct _USER_EXPIRES_INFORMATION
471 OLD_LARGE_INTEGER AccountExpires;
472} USER_EXPIRES_INFORMATION, *PUSER_EXPIRES_INFORMATION;
475typedef struct _SAMPR_LOGON_HOURS
477 unsigned short UnitsPerWeek;
478 [size_is(1260), length_is((UnitsPerWeek + 7) / 8)] unsigned char *LogonHours; // FIXME
479} SAMPR_LOGON_HOURS, *PSAMPR_LOGON_HOURS;
481typedef struct _SAMPR_USER_ALL_INFORMATION
483 OLD_LARGE_INTEGER LastLogon;
484 OLD_LARGE_INTEGER LastLogoff;
485 OLD_LARGE_INTEGER PasswordLastSet;
486 OLD_LARGE_INTEGER AccountExpires;
487 OLD_LARGE_INTEGER PasswordCanChange;
488 OLD_LARGE_INTEGER PasswordMustChange;
489 RPC_UNICODE_STRING UserName;
490 RPC_UNICODE_STRING FullName;
491 RPC_UNICODE_STRING HomeDirectory;
492 RPC_UNICODE_STRING HomeDirectoryDrive;
493 RPC_UNICODE_STRING ScriptPath;
494 RPC_UNICODE_STRING ProfilePath;
495 RPC_UNICODE_STRING AdminComment;
496 RPC_UNICODE_STRING WorkStations;
497 RPC_UNICODE_STRING UserComment;
498 RPC_UNICODE_STRING Parameters;
499 RPC_SHORT_BLOB LmOwfPassword;
500 RPC_SHORT_BLOB NtOwfPassword;
501 RPC_UNICODE_STRING PrivateData;
502 SAMPR_SR_SECURITY_DESCRIPTOR SecurityDescriptor;
503 unsigned long UserId;
504 unsigned long PrimaryGroupId;
505 unsigned long UserAccountControl;
506 unsigned long WhichFields;
507 SAMPR_LOGON_HOURS LogonHours;
508 unsigned short BadPasswordCount;
509 unsigned short LogonCount;
510 unsigned short CountryCode;
511 unsigned short CodePage;
512 unsigned char LmPasswordPresent;
513 unsigned char NtPasswordPresent;
514 unsigned char PasswordExpired;
515 unsigned char PrivateDataSensitive;
516} SAMPR_USER_ALL_INFORMATION, *PSAMPR_USER_ALL_INFORMATION;
518typedef struct _SAMPR_USER_GENERAL_INFORMATION
520 RPC_UNICODE_STRING UserName;
521 RPC_UNICODE_STRING FullName;
522 unsigned long PrimaryGroupId;
523 RPC_UNICODE_STRING AdminComment;
524 RPC_UNICODE_STRING UserComment;
525} SAMPR_USER_GENERAL_INFORMATION, *PSAMPR_USER_GENERAL_INFORMATION;
527typedef struct _SAMPR_USER_PREFERENCES_INFORMATION
529 RPC_UNICODE_STRING UserComment;
530 RPC_UNICODE_STRING Reserved1;
531 unsigned short CountryCode;
532 unsigned short CodePage;
533} SAMPR_USER_PREFERENCES_INFORMATION, *PSAMPR_USER_PREFERENCES_INFORMATION;
535typedef struct _SAMPR_USER_PARAMETERS_INFORMATION
537 RPC_UNICODE_STRING Parameters;
538} SAMPR_USER_PARAMETERS_INFORMATION, *PSAMPR_USER_PARAMETERS_INFORMATION;
540typedef struct _SAMPR_USER_LOGON_INFORMATION
542 RPC_UNICODE_STRING UserName;
543 RPC_UNICODE_STRING FullName;
544 unsigned long UserId;
545 unsigned long PrimaryGroupId;
546 RPC_UNICODE_STRING HomeDirectory;
547 RPC_UNICODE_STRING HomeDirectoryDrive;
548 RPC_UNICODE_STRING ScriptPath;
549 RPC_UNICODE_STRING ProfilePath;
550 RPC_UNICODE_STRING WorkStations;
551 OLD_LARGE_INTEGER LastLogon;
552 OLD_LARGE_INTEGER LastLogoff;
553 OLD_LARGE_INTEGER PasswordLastSet;
554 OLD_LARGE_INTEGER PasswordCanChange;
555 OLD_LARGE_INTEGER PasswordMustChange;
556 SAMPR_LOGON_HOURS LogonHours;
557 unsigned short BadPasswordCount;
558 unsigned short LogonCount;
559 unsigned long UserAccountControl;
560} SAMPR_USER_LOGON_INFORMATION, *PSAMPR_USER_LOGON_INFORMATION;
562typedef struct _SAMPR_USER_ACCOUNT_INFORMATION
564 RPC_UNICODE_STRING UserName;
565 RPC_UNICODE_STRING FullName;
566 unsigned long UserId;
567 unsigned long PrimaryGroupId;
568 RPC_UNICODE_STRING HomeDirectory;
569 RPC_UNICODE_STRING HomeDirectoryDrive;
570 RPC_UNICODE_STRING ScriptPath;
571 RPC_UNICODE_STRING ProfilePath;
572 RPC_UNICODE_STRING AdminComment;
573 RPC_UNICODE_STRING WorkStations;
574 OLD_LARGE_INTEGER LastLogon;
575 OLD_LARGE_INTEGER LastLogoff;
576 SAMPR_LOGON_HOURS LogonHours;
577 unsigned short BadPasswordCount;
578 unsigned short LogonCount;
579 OLD_LARGE_INTEGER PasswordLastSet;
580 OLD_LARGE_INTEGER AccountExpires;
581 unsigned long UserAccountControl;
582} SAMPR_USER_ACCOUNT_INFORMATION, *PSAMPR_USER_ACCOUNT_INFORMATION;
584typedef struct _SAMPR_USER_A_NAME_INFORMATION
586 RPC_UNICODE_STRING UserName;
587} SAMPR_USER_A_NAME_INFORMATION, *PSAMPR_USER_A_NAME_INFORMATION;
589typedef struct _SAMPR_USER_F_NAME_INFORMATION
591 RPC_UNICODE_STRING FullName;
592} SAMPR_USER_F_NAME_INFORMATION, *PSAMPR_USER_F_NAME_INFORMATION;
594typedef struct _SAMPR_USER_NAME_INFORMATION
596 RPC_UNICODE_STRING UserName;
597 RPC_UNICODE_STRING FullName;
598} SAMPR_USER_NAME_INFORMATION, *PSAMPR_USER_NAME_INFORMATION;
600typedef struct _SAMPR_USER_HOME_INFORMATION
602 RPC_UNICODE_STRING HomeDirectory;
603 RPC_UNICODE_STRING HomeDirectoryDrive;
604} SAMPR_USER_HOME_INFORMATION, *PSAMPR_USER_HOME_INFORMATION;
606typedef struct _SAMPR_USER_SCRIPT_INFORMATION
608 RPC_UNICODE_STRING ScriptPath;
609} SAMPR_USER_SCRIPT_INFORMATION, *PSAMPR_USER_SCRIPT_INFORMATION;
611typedef struct _SAMPR_USER_PROFILE_INFORMATION
613 RPC_UNICODE_STRING ProfilePath;
614} SAMPR_USER_PROFILE_INFORMATION, *PSAMPR_USER_PROFILE_INFORMATION;
616typedef struct _SAMPR_USER_ADMIN_COMMENT_INFORMATION
618 RPC_UNICODE_STRING AdminComment;
619} SAMPR_USER_ADMIN_COMMENT_INFORMATION, *PSAMPR_USER_ADMIN_COMMENT_INFORMATION;
621typedef struct _SAMPR_USER_WORKSTATIONS_INFORMATION
623 RPC_UNICODE_STRING WorkStations;
624} SAMPR_USER_WORKSTATIONS_INFORMATION, *PSAMPR_USER_WORKSTATIONS_INFORMATION;
626typedef struct _SAMPR_USER_SET_PASSWORD_INFORMATION
628// SAMPR_ENCRYPTED_USER_PASSWORD Password;
629 RPC_UNICODE_STRING Password;
630 BOOLEAN PasswordExpired;
631} SAMPR_USER_SET_PASSWORD_INFORMATION, *PSAMPR_USER_SET_PASSWORD_INFORMATION;
633typedef struct _SAMPR_USER_LOGON_HOURS_INFORMATION
635 SAMPR_LOGON_HOURS LogonHours;
636} SAMPR_USER_LOGON_HOURS_INFORMATION, *PSAMPR_USER_LOGON_HOURS_INFORMATION;
638typedef struct _SAMPR_USER_INTERNAL1_INFORMATION
640 ENCRYPTED_NT_OWF_PASSWORD EncryptedNtOwfPassword;
641 ENCRYPTED_LM_OWF_PASSWORD EncryptedLmOwfPassword;
642 BOOLEAN NtPasswordPresent;
643 BOOLEAN LmPasswordPresent;
644 BOOLEAN PasswordExpired;
645} SAMPR_USER_INTERNAL1_INFORMATION, *PSAMPR_USER_INTERNAL1_INFORMATION;
647/* SAMPR_USER_INTERNAL2_INFORMATION.Flags values */
648cpp_quote("#define USER_LOGON_BAD_PASSWORD 0x08000000")
649cpp_quote("#define USER_LOGON_SUCCESS 0x10000000")
651typedef struct _SAMPR_USER_INTERNAL2_INFORMATION
654 OLD_LARGE_INTEGER LastLogon;
655 OLD_LARGE_INTEGER LastLogoff;
656 unsigned short BadPasswordCount;
657 unsigned short LogonCount;
658} SAMPR_USER_INTERNAL2_INFORMATION, *PSAMPR_USER_INTERNAL2_INFORMATION;
660typedef struct _SAMPR_USER_INTERNAL4_INFORMATION
662 SAMPR_USER_ALL_INFORMATION I1;
663 SAMPR_ENCRYPTED_USER_PASSWORD UserPassword;
664} SAMPR_USER_INTERNAL4_INFORMATION, *PSAMPR_USER_INTERNAL4_INFORMATION;
666typedef struct _SAMPR_USER_INTERNAL4_INFORMATION_NEW
668 SAMPR_USER_ALL_INFORMATION I1;
669 SAMPR_ENCRYPTED_USER_PASSWORD_NEW UserPassword;
670} SAMPR_USER_INTERNAL4_INFORMATION_NEW, *PSAMPR_USER_INTERNAL4_INFORMATION_NEW;
672typedef struct _SAMPR_USER_INTERNAL5_INFORMATION
674 SAMPR_ENCRYPTED_USER_PASSWORD UserPassword;
675 BOOLEAN PasswordExpired;
676} SAMPR_USER_INTERNAL5_INFORMATION, *PSAMPR_USER_INTERNAL5_INFORMATION;
678typedef struct _SAMPR_USER_INTERNAL5_INFORMATION_NEW
680 SAMPR_ENCRYPTED_USER_PASSWORD_NEW UserPassword;
681 BOOLEAN PasswordExpired;
682} SAMPR_USER_INTERNAL5_INFORMATION_NEW, *PSAMPR_USER_INTERNAL5_INFORMATION_NEW;
684cpp_quote("#ifndef _NTSAM_")
685typedef enum _USER_INFORMATION_CLASS
687 UserGeneralInformation = 1,
688 UserPreferencesInformation = 2,
689 UserLogonInformation = 3,
690 UserLogonHoursInformation = 4,
691 UserAccountInformation = 5,
692 UserNameInformation = 6,
693 UserAccountNameInformation = 7,
694 UserFullNameInformation = 8,
695 UserPrimaryGroupInformation = 9,
696 UserHomeInformation = 10,
697 UserScriptInformation = 11,
698 UserProfileInformation = 12,
699 UserAdminCommentInformation = 13,
700 UserWorkStationsInformation = 14,
701 UserSetPasswordInformation = 15, /* This is missing from the SAM RPC documentation */
702 UserControlInformation = 16,
703 UserExpiresInformation = 17,
704 UserInternal1Information = 18,
705 UserInternal2Information = 19, /* This is missing from the SAM RPC documentation */
706 UserParametersInformation = 20,
707 UserAllInformation = 21,
708 UserInternal3Information = 22, /* This is missing from the SAM RPC documentation */
709 UserInternal4Information = 23,
710 UserInternal5Information = 24,
711 UserInternal4InformationNew = 25,
712 UserInternal5InformationNew = 26,
713 UserInternal6Information, /* This is missing from the SAM RPC documentation */
714 UserExtendedInformation, /* This is missing from the SAM RPC documentation */
715 UserLogonUIInformation, /* This is missing from the SAM RPC documentation */
716} USER_INFORMATION_CLASS, *PUSER_INFORMATION_CLASS;
719typedef [switch_type(USER_INFORMATION_CLASS)] union _SAMPR_USER_INFO_BUFFER
721 [case(UserGeneralInformation)] SAMPR_USER_GENERAL_INFORMATION General;
722 [case(UserPreferencesInformation)] SAMPR_USER_PREFERENCES_INFORMATION Preferences;
723 [case(UserLogonInformation)] SAMPR_USER_LOGON_INFORMATION Logon;
724 [case(UserLogonHoursInformation)] SAMPR_USER_LOGON_HOURS_INFORMATION LogonHours;
725 [case(UserAccountInformation)] SAMPR_USER_ACCOUNT_INFORMATION Account;
726 [case(UserNameInformation)] SAMPR_USER_NAME_INFORMATION Name;
727 [case(UserAccountNameInformation)] SAMPR_USER_A_NAME_INFORMATION AccountName;
728 [case(UserFullNameInformation)] SAMPR_USER_F_NAME_INFORMATION FullName;
729 [case(UserPrimaryGroupInformation)] USER_PRIMARY_GROUP_INFORMATION PrimaryGroup;
730 [case(UserHomeInformation)] SAMPR_USER_HOME_INFORMATION Home;
731 [case(UserScriptInformation)] SAMPR_USER_SCRIPT_INFORMATION Script;
732 [case(UserProfileInformation)] SAMPR_USER_PROFILE_INFORMATION Profile;
733 [case(UserAdminCommentInformation)] SAMPR_USER_ADMIN_COMMENT_INFORMATION AdminComment;
734 [case(UserWorkStationsInformation)] SAMPR_USER_WORKSTATIONS_INFORMATION WorkStations;
735 [case(UserSetPasswordInformation)] SAMPR_USER_SET_PASSWORD_INFORMATION SetPassword;
736 [case(UserControlInformation)] USER_CONTROL_INFORMATION Control;
737 [case(UserExpiresInformation)] USER_EXPIRES_INFORMATION Expires;
738 [case(UserInternal1Information)] SAMPR_USER_INTERNAL1_INFORMATION Internal1;
739 [case(UserInternal2Information)] SAMPR_USER_INTERNAL2_INFORMATION Internal2;
740 [case(UserParametersInformation)] SAMPR_USER_PARAMETERS_INFORMATION Parameters;
741 [case(UserAllInformation)] SAMPR_USER_ALL_INFORMATION All;
742 [case(UserInternal4Information)] SAMPR_USER_INTERNAL4_INFORMATION Internal4;
743 [case(UserInternal5Information)] SAMPR_USER_INTERNAL5_INFORMATION Internal5;
744 [case(UserInternal4InformationNew)] SAMPR_USER_INTERNAL4_INFORMATION_NEW Internal4New;
745 [case(UserInternal5InformationNew)] SAMPR_USER_INTERNAL5_INFORMATION_NEW Internal5New;
746} SAMPR_USER_INFO_BUFFER, *PSAMPR_USER_INFO_BUFFER;
748typedef enum _PASSWORD_POLICY_VALIDATION_TYPE
750 SamValidateAuthentication = 1,
751 SamValidatePasswordChange,
752 SamValidatePasswordReset
753} PASSWORD_POLICY_VALIDATION_TYPE;
755typedef struct _SAM_VALIDATE_PASSWORD_HASH
757 unsigned long Length;
758 [unique,size_is(Length)] unsigned char* Hash;
759} SAM_VALIDATE_PASSWORD_HASH, *PSAM_VALIDATE_PASSWORD_HASH;
761typedef struct _SAM_VALIDATE_PERSISTED_FIELDS
763 unsigned long PresentFields;
764 LARGE_INTEGER PasswordLastSet;
765 LARGE_INTEGER BadPasswordTime;
766 LARGE_INTEGER LockoutTime;
767 unsigned long BadPasswordCount;
768 unsigned long PasswordHistoryLength;
769 [unique,size_is(PasswordHistoryLength)] PSAM_VALIDATE_PASSWORD_HASH PasswordHistory;
770} SAM_VALIDATE_PERSISTED_FIELDS, *PSAM_VALIDATE_PERSISTED_FIELDS;
772typedef enum _SAM_VALIDATE_VALIDATION_STATUS
774 SamValidateSuccess = 0,
775 SamValidatePasswordMustChange,
776 SamValidateAccountLockedOut,
777 SamValidatePasswordExpired,
778 SamValidatePasswordIncorrect,
779 SamValidatePasswordIsInHistory,
780 SamValidatePasswordTooShort,
781 SamValidatePasswordTooLong,
782 SamValidatePasswordNotComplexEnough,
783 SamValidatePasswordTooRecent,
784 SamValidatePasswordFilterError
785} SAM_VALIDATE_VALIDATION_STATUS, *PSAM_VALIDATE_VALIDATION_STATUS;
787typedef struct _SAM_VALIDATE_STANDARD_OUTPUT_ARG
789 SAM_VALIDATE_PERSISTED_FIELDS ChangedPersistedFields;
790 SAM_VALIDATE_VALIDATION_STATUS ValidationStatus;
791} SAM_VALIDATE_STANDARD_OUTPUT_ARG, *PSAM_VALIDATE_STANDARD_OUTPUT_ARG;
793typedef struct _SAM_VALIDATE_AUTHENTICATION_INPUT_ARG
795 SAM_VALIDATE_PERSISTED_FIELDS InputPersistedFields;
796 unsigned char PasswordMatched;
797} SAM_VALIDATE_AUTHENTICATION_INPUT_ARG, *PSAM_VALIDATE_AUTHENTICATION_INPUT_ARG;
799typedef struct _SAM_VALIDATE_PASSWORD_CHANGE_INPUT_ARG
801 SAM_VALIDATE_PERSISTED_FIELDS InputPersistedFields;
802 RPC_UNICODE_STRING ClearPassword;
803 RPC_UNICODE_STRING UserAccountName;
804 SAM_VALIDATE_PASSWORD_HASH HashedPassword;
805 unsigned char PasswordMatch;
806} SAM_VALIDATE_PASSWORD_CHANGE_INPUT_ARG, *PSAM_VALIDATE_PASSWORD_CHANGE_INPUT_ARG;
808typedef struct _SAM_VALIDATE_PASSWORD_RESET_INPUT_ARG
810 SAM_VALIDATE_PERSISTED_FIELDS InputPersistedFields;
811 RPC_UNICODE_STRING ClearPassword;
812 RPC_UNICODE_STRING UserAccountName;
813 SAM_VALIDATE_PASSWORD_HASH HashedPassword;
814 unsigned char PasswordMustChangeAtNextLogon;
815 unsigned char ClearLockout;
816} SAM_VALIDATE_PASSWORD_RESET_INPUT_ARG, *PSAM_VALIDATE_PASSWORD_RESET_INPUT_ARG;
818typedef [switch_type(PASSWORD_POLICY_VALIDATION_TYPE)] union _SAM_VALIDATE_INPUT_ARG
820 [case(SamValidateAuthentication)] SAM_VALIDATE_AUTHENTICATION_INPUT_ARG ValidateAuthenticationInput;
821 [case(SamValidatePasswordChange)] SAM_VALIDATE_PASSWORD_CHANGE_INPUT_ARG ValidatePasswordChangeInput;
822 [case(SamValidatePasswordReset)] SAM_VALIDATE_PASSWORD_RESET_INPUT_ARG ValidatePasswordResetInput;
823} SAM_VALIDATE_INPUT_ARG, *PSAM_VALIDATE_INPUT_ARG;
825typedef [switch_type(PASSWORD_POLICY_VALIDATION_TYPE)] union _SAM_VALIDATE_OUTPUT_ARG
827 [case(SamValidateAuthentication)] SAM_VALIDATE_STANDARD_OUTPUT_ARG ValidateAuthenticationOutput;
828 [case(SamValidatePasswordChange)] SAM_VALIDATE_STANDARD_OUTPUT_ARG ValidatePasswordChangeOutput;
829 [case(SamValidatePasswordReset)] SAM_VALIDATE_STANDARD_OUTPUT_ARG ValidatePasswordResetOutput;
830} SAM_VALIDATE_OUTPUT_ARG, *PSAM_VALIDATE_OUTPUT_ARG;
833 uuid(12345778-1234-ABCD-EF00-0123456789AC),
835 pointer_default(unique),
836 endpoint("ncacn_np:[\\pipe\\samr]")
847 [in, unique] PSAMPR_SERVER_NAME ServerName,
848 [out] SAMPR_HANDLE *ServerHandle,
849 [in] ACCESS_MASK DesiredAccess);
855 [in, out] SAMPR_HANDLE *SamHandle);
860 SamrSetSecurityObject(
861 [in] SAMPR_HANDLE ObjectHandle,
862 [in] SECURITY_INFORMATION SecurityInformation,
863 [in] PSAMPR_SR_SECURITY_DESCRIPTOR SecurityDescriptor);
868 SamrQuerySecurityObject(
869 [in] SAMPR_HANDLE ObjectHandle,
870 [in] SECURITY_INFORMATION SecurityInformation,
871 [out] PSAMPR_SR_SECURITY_DESCRIPTOR *SecurityDescriptor);
876 SamrShutdownSamServer(
877 [in] SAMPR_HANDLE ServerHandle);
882 SamrLookupDomainInSamServer(
883 [in] SAMPR_HANDLE ServerHandle,
884 [in] PRPC_UNICODE_STRING Name,
885 [out] PRPC_SID *DomainId);
890 SamrEnumerateDomainsInSamServer(
891 [in] SAMPR_HANDLE ServerHandle,
892 [in, out] unsigned long *EnumerationContext,
893 [out] PSAMPR_ENUMERATION_BUFFER *Buffer,
894 [in] unsigned long PreferedMaximumLength,
895 [out] unsigned long *CountReturned);
901 [in] SAMPR_HANDLE ServerHandle,
902 [in] ACCESS_MASK DesiredAccess,
903 [in] PRPC_SID DomainId,
904 [out] SAMPR_HANDLE *DomainHandle);
909 SamrQueryInformationDomain(
910 [in] SAMPR_HANDLE DomainHandle,
911 [in] DOMAIN_INFORMATION_CLASS DomainInformationClass,
912 [out, switch_is(DomainInformationClass)] PSAMPR_DOMAIN_INFO_BUFFER *Buffer);
917 SamrSetInformationDomain(
918 [in] SAMPR_HANDLE DomainHandle,
919 [in] DOMAIN_INFORMATION_CLASS DomainInformationClass,
920 [in, switch_is(DomainInformationClass)] PSAMPR_DOMAIN_INFO_BUFFER DomainInformation);
925 SamrCreateGroupInDomain(
926 [in] SAMPR_HANDLE DomainHandle,
927 [in] PRPC_UNICODE_STRING Name,
928 [in] ACCESS_MASK DesiredAccess,
929 [out] SAMPR_HANDLE *GroupHandle,
930 [out] unsigned long *RelativeId);
935 SamrEnumerateGroupsInDomain(
936 [in] SAMPR_HANDLE DomainHandle,
937 [in, out] unsigned long *EnumerationContext,
938 [out] PSAMPR_ENUMERATION_BUFFER *Buffer,
939 [in] unsigned long PreferedMaximumLength,
940 [out] unsigned long *CountReturned);
945 SamrCreateUserInDomain(
946 [in] SAMPR_HANDLE DomainHandle,
947 [in] PRPC_UNICODE_STRING Name,
948 [in] ACCESS_MASK DesiredAccess,
949 [out] SAMPR_HANDLE *UserHandle,
950 [out] unsigned long *RelativeId);
955 SamrEnumerateUsersInDomain(
956 [in] SAMPR_HANDLE DomainHandle,
957 [in, out] unsigned long *EnumerationContext,
958 [in] unsigned long UserAccountControl,
959 [out] PSAMPR_ENUMERATION_BUFFER *Buffer,
960 [in] unsigned long PreferedMaximumLength,
961 [out] unsigned long *CountReturned);
966 SamrCreateAliasInDomain(
967 [in] SAMPR_HANDLE DomainHandle,
968 [in] PRPC_UNICODE_STRING AccountName,
969 [in] ACCESS_MASK DesiredAccess,
970 [out] SAMPR_HANDLE *AliasHandle,
971 [out] unsigned long *RelativeId);
976 SamrEnumerateAliasesInDomain(
977 [in] SAMPR_HANDLE DomainHandle,
978 [in, out] unsigned long *EnumerationContext,
979 [out] PSAMPR_ENUMERATION_BUFFER *Buffer,
980 [in] unsigned long PreferedMaximumLength,
981 [out] unsigned long *CountReturned);
986 SamrGetAliasMembership(
987 [in] SAMPR_HANDLE DomainHandle,
988 [in] PSAMPR_PSID_ARRAY SidArray,
989 [out] PSAMPR_ULONG_ARRAY Membership);
994 SamrLookupNamesInDomain(
995 [in] SAMPR_HANDLE DomainHandle,
996 [in, range(0, 1000)] unsigned long Count,
997 [in, size_is(1000), length_is(Count)] RPC_UNICODE_STRING Names[*],
998 [out] PSAMPR_ULONG_ARRAY RelativeIds,
999 [out] PSAMPR_ULONG_ARRAY Use);
1004 SamrLookupIdsInDomain(
1005 [in] SAMPR_HANDLE DomainHandle,
1006 [in, range(0, 1000)] unsigned long Count,
1007 [in, size_is(1000), length_is(Count)] unsigned long *RelativeIds,
1008 [out] PSAMPR_RETURNED_USTRING_ARRAY Names,
1009 [out] PSAMPR_ULONG_ARRAY Use);
1015 [in] SAMPR_HANDLE DomainHandle,
1016 [in] ACCESS_MASK DesiredAccess,
1017 [in] unsigned long GroupId,
1018 [out] SAMPR_HANDLE *GroupHandle);
1023 SamrQueryInformationGroup(
1024 [in] SAMPR_HANDLE GroupHandle,
1025 [in] GROUP_INFORMATION_CLASS GroupInformationClass,
1026 [out, switch_is(GroupInformationClass)] PSAMPR_GROUP_INFO_BUFFER *Buffer);
1031 SamrSetInformationGroup(
1032 [in] SAMPR_HANDLE GroupHandle,
1033 [in] GROUP_INFORMATION_CLASS GroupInformationClass,
1034 [in, switch_is(GroupInformationClass)] PSAMPR_GROUP_INFO_BUFFER Buffer);
1039 SamrAddMemberToGroup(
1040 [in] SAMPR_HANDLE GroupHandle,
1041 [in] unsigned long MemberId,
1042 [in] unsigned long Attributes);
1048 [in, out] SAMPR_HANDLE *GroupHandle);
1053 SamrRemoveMemberFromGroup(
1054 [in] SAMPR_HANDLE GroupHandle,
1055 [in] unsigned long MemberId);
1060 SamrGetMembersInGroup(
1061 [in] SAMPR_HANDLE GroupHandle,
1062 [out] PSAMPR_GET_MEMBERS_BUFFER *Members);
1067 SamrSetMemberAttributesOfGroup(
1068 [in] SAMPR_HANDLE GroupHandle,
1069 [in] unsigned long MemberId,
1070 [in] unsigned long Attributes);
1076 [in] SAMPR_HANDLE DomainHandle,
1077 [in] ACCESS_MASK DesiredAccess,
1079 [out] SAMPR_HANDLE *AliasHandle);
1084 SamrQueryInformationAlias(
1085 [in] SAMPR_HANDLE AliasHandle,
1086 [in] ALIAS_INFORMATION_CLASS AliasInformationClass,
1087 [out, switch_is(AliasInformationClass)] PSAMPR_ALIAS_INFO_BUFFER *Buffer);
1092 SamrSetInformationAlias(
1093 [in] SAMPR_HANDLE AliasHandle,
1094 [in] ALIAS_INFORMATION_CLASS AliasInformationClass,
1095 [in, switch_is(AliasInformationClass)] PSAMPR_ALIAS_INFO_BUFFER Buffer);
1101 [in, out] SAMPR_HANDLE *AliasHandle);
1106 SamrAddMemberToAlias(
1107 [in] SAMPR_HANDLE AliasHandle,
1108 [in] PRPC_SID MemberId);
1113 SamrRemoveMemberFromAlias(
1114 [in] SAMPR_HANDLE AliasHandle,
1115 [in] PRPC_SID MemberId);
1120 SamrGetMembersInAlias(
1121 [in] SAMPR_HANDLE AliasHandle,
1122 [out] PSAMPR_PSID_ARRAY_OUT Members);
1128 [in] SAMPR_HANDLE DomainHandle,
1129 [in] ACCESS_MASK DesiredAccess,
1131 [out] SAMPR_HANDLE *UserHandle);
1137 [in,out] SAMPR_HANDLE *UserHandle);
1142 SamrQueryInformationUser(
1143 [in] SAMPR_HANDLE UserHandle,
1144 [in] USER_INFORMATION_CLASS UserInformationClass,
1145 [out, switch_is(UserInformationClass)] PSAMPR_USER_INFO_BUFFER *Buffer);
1150 SamrSetInformationUser(
1151 [in] SAMPR_HANDLE UserHandle,
1152 [in] USER_INFORMATION_CLASS UserInformationClass,
1153 [in, switch_is(UserInformationClass)] PSAMPR_USER_INFO_BUFFER Buffer);
1158 SamrChangePasswordUser(
1159 [in] SAMPR_HANDLE UserHandle,
1160 [in] unsigned char LmPresent,
1161 [in, unique] PENCRYPTED_LM_OWF_PASSWORD OldLmEncryptedWithNewLm,
1162 [in, unique] PENCRYPTED_LM_OWF_PASSWORD NewLmEncryptedWithOldLm,
1163 [in] unsigned char NtPresent,
1164 [in, unique] PENCRYPTED_NT_OWF_PASSWORD OldNtEncryptedWithNewNt,
1165 [in, unique] PENCRYPTED_NT_OWF_PASSWORD NewNtEncryptedWithOldNt,
1166 [in] unsigned char NtCrossEncryptionPresent,
1167 [in, unique] PENCRYPTED_NT_OWF_PASSWORD NewNtEncryptedWithNewLm,
1168 [in] unsigned char LmCrossEncryptionPresent,
1169 [in, unique] PENCRYPTED_LM_OWF_PASSWORD NewLmEncryptedWithNewNt);
1174 SamrGetGroupsForUser(
1175 [in] SAMPR_HANDLE UserHandle,
1176 [out] PSAMPR_GET_GROUPS_BUFFER *Groups);
1181 SamrQueryDisplayInformation(
1182 [in] SAMPR_HANDLE DomainHandle,
1183 [in] DOMAIN_DISPLAY_INFORMATION DisplayInformationClass,
1184 [in] unsigned long Index,
1185 [in] unsigned long EntryCount,
1186 [in] unsigned long PreferredMaximumLength,
1187 [out] unsigned long * TotalAvailable,
1188 [out] unsigned long * TotalReturned,
1189 [out, switch_is(DisplayInformationClass)] PSAMPR_DISPLAY_INFO_BUFFER Buffer);
1194 SamrGetDisplayEnumerationIndex(
1195 [in] SAMPR_HANDLE DomainHandle,
1196 [in] DOMAIN_DISPLAY_INFORMATION DisplayInformationClass,
1197 [in] PRPC_UNICODE_STRING Prefix,
1198 [out] unsigned long *Index);
1203 SamrTestPrivateFunctionsDomain(
1204 [in] SAMPR_HANDLE DomainHandle);
1209 SamrTestPrivateFunctionsUser(
1210 [in] SAMPR_HANDLE UserHandle);
1215 SamrGetUserDomainPasswordInformation(
1216 [in] SAMPR_HANDLE UserHandle,
1217 [out] PUSER_DOMAIN_PASSWORD_INFORMATION PasswordInformation);
1222 SamrRemoveMemberFromForeignDomain(
1223 [in] SAMPR_HANDLE DomainHandle,
1224 [in] PRPC_SID MemberSid);
1229 SamrQueryInformationDomain2(
1230 [in] SAMPR_HANDLE DomainHandle,
1231 [in] DOMAIN_INFORMATION_CLASS DomainInformationClass,
1232 [out, switch_is(DomainInformationClass)] PSAMPR_DOMAIN_INFO_BUFFER *Buffer);
1237 SamrQueryInformationUser2(
1238 [in] SAMPR_HANDLE UserHandle,
1239 [in] USER_INFORMATION_CLASS UserInformationClass,
1240 [out, switch_is(UserInformationClass)] PSAMPR_USER_INFO_BUFFER *Buffer);
1245 SamrQueryDisplayInformation2(
1246 [in] SAMPR_HANDLE DomainHandle,
1247 [in] DOMAIN_DISPLAY_INFORMATION DisplayInformationClass,
1248 [in] unsigned long Index,
1249 [in] unsigned long EntryCount,
1250 [in] unsigned long PreferredMaximumLength,
1251 [out] unsigned long *TotalAvailable,
1252 [out] unsigned long *TotalReturned,
1253 [out, switch_is(DisplayInformationClass)] PSAMPR_DISPLAY_INFO_BUFFER Buffer);
1258 SamrGetDisplayEnumerationIndex2(
1259 [in] SAMPR_HANDLE DomainHandle,
1260 [in] DOMAIN_DISPLAY_INFORMATION DisplayInformationClass,
1261 [in] PRPC_UNICODE_STRING Prefix,
1262 [out] unsigned long *Index);
1267 SamrCreateUser2InDomain(
1268 [in] SAMPR_HANDLE DomainHandle,
1269 [in] PRPC_UNICODE_STRING Name,
1270 [in] unsigned long AccountType,
1271 [in] ACCESS_MASK DesiredAccess,
1272 [out] SAMPR_HANDLE *UserHandle,
1273 [out] unsigned long *GrantedAccess,
1274 [out] unsigned long *RelativeId);
1279 SamrQueryDisplayInformation3(
1280 [in] SAMPR_HANDLE DomainHandle,
1281 [in] DOMAIN_DISPLAY_INFORMATION DisplayInformationClass,
1282 [in] unsigned long Index,
1283 [in] unsigned long EntryCount,
1284 [in] unsigned long PreferredMaximumLength,
1285 [out] unsigned long *TotalAvailable,
1286 [out] unsigned long *TotalReturned,
1287 [out, switch_is(DisplayInformationClass)] PSAMPR_DISPLAY_INFO_BUFFER Buffer);
1292 SamrAddMultipleMembersToAlias(
1293 [in] SAMPR_HANDLE AliasHandle,
1294 [in] PSAMPR_PSID_ARRAY MembersBuffer);
1299 SamrRemoveMultipleMembersFromAlias(
1300 [in] SAMPR_HANDLE AliasHandle,
1301 [in] PSAMPR_PSID_ARRAY MembersBuffer);
1306 SamrOemChangePasswordUser2(
1307 [in] handle_t BindingHandle,
1308 [in, unique] PRPC_STRING ServerName,
1309 [in] PRPC_STRING UserName,
1310 [in, unique] PSAMPR_ENCRYPTED_USER_PASSWORD NewPasswordEncryptedWithOldLm,
1311 [in, unique] PENCRYPTED_LM_OWF_PASSWORD OldLmOwfPasswordEncryptedWithNewLm);
1316 SamrUnicodeChangePasswordUser2(
1317 [in] handle_t BindingHandle,
1318 [in, unique] PRPC_UNICODE_STRING ServerName,
1319 [in] PRPC_UNICODE_STRING UserName,
1320 [in, unique] PSAMPR_ENCRYPTED_USER_PASSWORD NewPasswordEncryptedWithOldNt,
1321 [in, unique] PENCRYPTED_NT_OWF_PASSWORD OldNtOwfPasswordEncryptedWithNewNt,
1322 [in] unsigned char LmPresent,
1323 [in, unique] PSAMPR_ENCRYPTED_USER_PASSWORD NewPasswordEncryptedWithOldLm,
1324 [in, unique] PENCRYPTED_LM_OWF_PASSWORD OldLmOwfPasswordEncryptedWithNewNt);
1329 SamrGetDomainPasswordInformation(
1330 [in] handle_t BindingHandle,
1331 [in, unique] PRPC_UNICODE_STRING Unused,
1332 [out] PUSER_DOMAIN_PASSWORD_INFORMATION PasswordInformation);
1338 [in, unique, string] PSAMPR_SERVER_NAME ServerName,
1339 [out] SAMPR_HANDLE *ServerHandle,
1340 [in] ACCESS_MASK DesiredAccess);
1345 SamrSetInformationUser2(
1346 [in] SAMPR_HANDLE UserHandle,
1347 [in] USER_INFORMATION_CLASS UserInformationClass,
1348 [in, switch_is(UserInformationClass)] PSAMPR_USER_INFO_BUFFER Buffer);
1353 SamrSetBootKeyInformation(
1354 [in] handle_t BindingHandle); /* FIXME */
1359 SamrGetBootKeyInformation(
1360 [in] handle_t BindingHandle); /* FIXME */
1366 [in] handle_t BindingHandle); /* FIXME */
1372 [in, unique, string] PSAMPR_SERVER_NAME ServerName,
1373 [out] SAMPR_HANDLE *ServerHandle,
1374 [in] unsigned long ClientRevision,
1375 [in] ACCESS_MASK DesiredAccess);
1380 SamrUnicodeChangePasswordUser3(
1381 [in] handle_t BindingHandle); /* FIXME */
1387 [in, unique, string] PSAMPR_SERVER_NAME ServerName,
1388 [in] ACCESS_MASK DesiredAccess,
1389 [in] unsigned long InVersion,
1390 [in, switch_is(InVersion)] SAMPR_REVISION_INFO *InRevisionInfo,
1391 [out] unsigned long *OutVersion,
1392 [out, switch_is(*OutVersion)] SAMPR_REVISION_INFO *OutRevisionInfo,
1393 [out] SAMPR_HANDLE *ServerHandle);
1399 [in] SAMPR_HANDLE ObjectHandle,
1400 [in] unsigned long Rid,
1401 [out] PRPC_SID *Sid);
1406 SamrSetDSRMPassword(
1407 [in] handle_t BindingHandle,
1408 [in, unique] PRPC_UNICODE_STRING Unused,
1409 [in] unsigned long UserId,
1410 [in, unique] PENCRYPTED_NT_OWF_PASSWORD EncryptedNtOwfPassword);
1415 SamrValidatePassword(
1416 [in] handle_t Handle,
1417 [in] PASSWORD_POLICY_VALIDATION_TYPE ValidationType,
1418 [in, switch_is(ValidationType)] PSAM_VALIDATE_INPUT_ARG InputArg,
1419 [out, switch_is(ValidationType)] PSAM_VALIDATE_OUTPUT_ARG *OutputArg);
CD3D10_BUFFER_DESC D3D10_BUFFER_DESC cpp_quote(" ~CD3D10_BUFFER_DESC() {}") operator const D3D10_BUFFER_DESC &() const