ReactOS 0.4.16-dev-289-g096a551
|
#include "pshpack4.h"
#include "poppack.h"
Go to the source code of this file.
#define ALIAS_ALL_ACCESS |
#define ALIAS_EXECUTE |
#define ALIAS_READ |
#define ALIAS_WRITE |
#define DOMAIN_ALL_ACCESS |
#define DOMAIN_EXECUTE |
#define DOMAIN_READ |
#define DOMAIN_WRITE |
#define GROUP_ALL_ACCESS |
#define GROUP_EXECUTE |
#define GROUP_READ |
#define GROUP_WRITE |
#define SAM_HOURS_PER_WEEK (24 * SAM_DAYS_PER_WEEK) |
#define SAM_MINUTES_PER_WEEK (60 * SAM_HOURS_PER_WEEK) |
#define SAM_SERVER_ALL_ACCESS |
#define SAM_SERVER_EXECUTE |
#define SAM_SERVER_READ |
#define SAM_SERVER_WRITE |
#define USER_ALL_ACCESS |
#define USER_ALL_WRITE_FORCE_PASSWORD_CHANGE_MASK 0x0B000000 |
#define USER_EXECUTE |
#define USER_READ |
#define USER_TRUSTED_TO_AUTHENTICATE_FOR_DELEGATION 0x00040000 |
#define USER_WRITE |
typedef struct _GROUP_MEMBERSHIP GROUP_MEMBERSHIP |
typedef struct _LOGON_HOURS LOGON_HOURS |
typedef struct _DOMAIN_DISPLAY_GROUP * PDOMAIN_DISPLAY_GROUP |
typedef struct _DOMAIN_DISPLAY_USER * PDOMAIN_DISPLAY_USER |
typedef enum _DOMAIN_SERVER_ROLE * PDOMAIN_SERVER_ROLE |
typedef struct _GROUP_MEMBERSHIP * PGROUP_MEMBERSHIP |
typedef struct _LOGON_HOURS * PLOGON_HOURS |
typedef ULONG * PSAM_ENUMERATE_HANDLE |
typedef PVOID * PSAM_HANDLE |
typedef struct _SAM_RID_ENUMERATION * PSAM_RID_ENUMERATION |
typedef struct _SAM_SID_ENUMERATION * PSAM_SID_ENUMERATION |
typedef struct _USER_ALL_INFORMATION * PUSER_ALL_INFORMATION |
typedef ULONG SAM_ENUMERATE_HANDLE |
typedef PVOID SAM_HANDLE |
Enumerator | |
---|---|
AliasGeneralInformation | |
AliasNameInformation | |
AliasAdminCommentInformation | |
AliasGeneralInformation | |
AliasNameInformation | |
AliasAdminCommentInformation |
Definition at line 277 of file ntsam.h.
Definition at line 301 of file ntsam.h.
Definition at line 339 of file ntsam.h.
Enumerator | |
---|---|
DomainServerEnabled | |
DomainServerDisabled | |
DomainServerEnabled | |
DomainServerDisabled |
Definition at line 356 of file ntsam.h.
Enumerator | |
---|---|
DomainServerRoleBackup | |
DomainServerRolePrimary | |
DomainServerRoleBackup | |
DomainServerRolePrimary |
Definition at line 362 of file ntsam.h.
Definition at line 462 of file ntsam.h.
Definition at line 512 of file ntsam.h.
Definition at line 235 of file samlib.c.
Referenced by NetLocalGroupAddMembers().
NTSTATUS NTAPI SamAddMemberToGroup | ( | IN SAM_HANDLE | GroupHandle, |
IN ULONG | MemberId, | ||
IN ULONG | Attributes | ||
) |
Definition at line 260 of file samlib.c.
Referenced by NetGroupAddUser(), and NetGroupSetUsers().
NTSTATUS NTAPI SamAddMultipleMembersToAlias | ( | IN SAM_HANDLE | AliasHandle, |
IN PSID * | MemberIds, | ||
IN ULONG | MemberCount | ||
) |
Definition at line 287 of file samlib.c.
NTSTATUS NTAPI SamChangePasswordUser | ( | IN SAM_HANDLE | UserHandle, |
IN PUNICODE_STRING | OldPassword, | ||
IN PUNICODE_STRING | NewPassword | ||
) |
Definition at line 320 of file samlib.c.
NTSTATUS NTAPI SamChangePasswordUser2 | ( | IN PUNICODE_STRING | ServerName, |
IN PUNICODE_STRING | UserName, | ||
IN PUNICODE_STRING | OldPassword, | ||
IN PUNICODE_STRING | NewPassword | ||
) |
NTSTATUS NTAPI SamChangePasswordUser3 | ( | IN PUNICODE_STRING | ServerName, |
IN PUNICODE_STRING | UserName, | ||
IN PUNICODE_STRING | OldPassword, | ||
IN PUNICODE_STRING | NewPassword, | ||
OUT PDOMAIN_PASSWORD_INFORMATION * | EffectivePasswordPolicy, | ||
OUT PUSER_PWD_CHANGE_FAILURE_INFORMATION * | PasswordChangeFailureInfo | ||
) |
NTSTATUS NTAPI SamCloseHandle | ( | IN SAM_HANDLE | SamHandle | ) |
Definition at line 497 of file samlib.c.
Referenced by ApplyAccountSettings(), ApplyLockoutSettings(), ApplyPasswordSettings(), EnableAccount(), NetGetDisplayInformationIndex(), NetGroupAdd(), NetGroupAddUser(), NetGroupDel(), NetGroupDelUser(), NetGroupEnum(), NetGroupGetInfo(), NetGroupGetUsers(), NetGroupSetInfo(), NetGroupSetUsers(), NetLocalGroupAdd(), NetLocalGroupAddMembers(), NetLocalGroupDel(), NetLocalGroupDelMembers(), NetLocalGroupEnum(), NetLocalGroupGetInfo(), NetLocalGroupGetMembers(), NetLocalGroupSetInfo(), NetQueryDisplayInformation(), NetUserAdd(), NetUserDel(), NetUserEnum(), NetUserGetGroups(), NetUserGetInfo(), NetUserGetLocalGroups(), NetUserModalsGet(), NetUserSetInfo(), SetAccountsDomainSid(), SetAdministratorPassword(), and SetNewAccountName().
NTSTATUS NTAPI SamConnect | ( | IN OUT PUNICODE_STRING ServerName | OPTIONAL, |
OUT PSAM_HANDLE | ServerHandle, | ||
IN ACCESS_MASK | DesiredAccess, | ||
IN POBJECT_ATTRIBUTES | ObjectAttributes | ||
) |
Definition at line 519 of file samlib.c.
Referenced by ApplyAccountSettings(), ApplyLockoutSettings(), ApplyPasswordSettings(), NetGetDisplayInformationIndex(), NetGroupAdd(), NetGroupAddUser(), NetGroupDel(), NetGroupDelUser(), NetGroupEnum(), NetGroupGetInfo(), NetGroupGetUsers(), NetGroupSetInfo(), NetGroupSetUsers(), NetLocalGroupAdd(), NetLocalGroupAddMembers(), NetLocalGroupDel(), NetLocalGroupDelMembers(), NetLocalGroupEnum(), NetLocalGroupGetInfo(), NetLocalGroupGetMembers(), NetLocalGroupSetInfo(), NetQueryDisplayInformation(), NetUserAdd(), NetUserDel(), NetUserEnum(), NetUserGetGroups(), NetUserGetInfo(), NetUserGetLocalGroups(), NetUserModalsGet(), NetUserSetInfo(), SetAccountsDomainSid(), and SetAdministratorPassword().
NTSTATUS NTAPI SamCreateAliasInDomain | ( | IN SAM_HANDLE | DomainHandle, |
IN PUNICODE_STRING | AccountName, | ||
IN ACCESS_MASK | DesiredAccess, | ||
OUT PSAM_HANDLE | AliasHandle, | ||
OUT PULONG | RelativeId | ||
) |
Definition at line 562 of file samlib.c.
Referenced by NetLocalGroupAdd().
NTSTATUS NTAPI SamCreateGroupInDomain | ( | IN SAM_HANDLE | DomainHandle, |
IN PUNICODE_STRING | AccountName, | ||
IN ACCESS_MASK | DesiredAccess, | ||
OUT PSAM_HANDLE | GroupHandle, | ||
OUT PULONG | RelativeId | ||
) |
Definition at line 596 of file samlib.c.
Referenced by NetGroupAdd().
NTSTATUS NTAPI SamCreateUser2InDomain | ( | IN SAM_HANDLE | DomainHandle, |
IN PUNICODE_STRING | AccountName, | ||
IN ULONG | AccountType, | ||
IN ACCESS_MASK | DesiredAccess, | ||
OUT PSAM_HANDLE | UserHandle, | ||
OUT PULONG | GrantedAccess, | ||
OUT PULONG | RelativeId | ||
) |
Definition at line 630 of file samlib.c.
Referenced by NetUserAdd().
NTSTATUS NTAPI SamCreateUserInDomain | ( | IN SAM_HANDLE | DomainHandle, |
IN PUNICODE_STRING | AccountName, | ||
IN ACCESS_MASK | DesiredAccess, | ||
OUT PSAM_HANDLE | UserHandle, | ||
OUT PULONG | RelativeId | ||
) |
Definition at line 670 of file samlib.c.
NTSTATUS NTAPI SamDeleteAlias | ( | IN SAM_HANDLE | AliasHandle | ) |
Definition at line 704 of file samlib.c.
Referenced by NetLocalGroupAdd(), and NetLocalGroupDel().
NTSTATUS NTAPI SamDeleteGroup | ( | IN SAM_HANDLE | GroupHandle | ) |
Definition at line 732 of file samlib.c.
Referenced by NetGroupAdd(), and NetGroupDel().
NTSTATUS NTAPI SamDeleteUser | ( | IN SAM_HANDLE | UserHandle | ) |
Definition at line 760 of file samlib.c.
Referenced by NetUserAdd(), and NetUserDel().
NTSTATUS NTAPI SamEnumerateAliasesInDomain | ( | IN SAM_HANDLE | DomainHandle, |
IN OUT PSAM_ENUMERATE_HANDLE | EnumerationContext, | ||
OUT PVOID * | Buffer, | ||
IN ULONG | PreferedMaximumLength, | ||
OUT PULONG | CountReturned | ||
) |
Definition at line 788 of file samlib.c.
Referenced by NetLocalGroupEnum().
NTSTATUS NTAPI SamEnumerateDomainsInSamServer | ( | IN SAM_HANDLE | ServerHandle, |
IN OUT PSAM_ENUMERATE_HANDLE | EnumerationContext, | ||
OUT PVOID * | Buffer, | ||
IN ULONG | PreferedMaximumLength, | ||
OUT PULONG | CountReturned | ||
) |
Definition at line 838 of file samlib.c.
NTSTATUS NTAPI SamEnumerateGroupsInDomain | ( | IN SAM_HANDLE | DomainHandle, |
IN OUT PSAM_ENUMERATE_HANDLE | EnumerationContext, | ||
IN PVOID * | Buffer, | ||
IN ULONG | PreferedMaximumLength, | ||
OUT PULONG | CountReturned | ||
) |
Definition at line 888 of file samlib.c.
Referenced by NetGroupEnum().
NTSTATUS NTAPI SamEnumerateUsersInDomain | ( | IN SAM_HANDLE | DomainHandle, |
IN OUT PSAM_ENUMERATE_HANDLE | EnumerationContext, | ||
IN ULONG | UserAccountControl, | ||
OUT PVOID * | Buffer, | ||
IN ULONG | PreferedMaximumLength, | ||
OUT PULONG | CountReturned | ||
) |
Definition at line 933 of file samlib.c.
Referenced by NetUserEnum().
Definition at line 983 of file samlib.c.
Referenced by ApplyLockoutSettings(), ApplyPasswordSettings(), EnableAccount(), FreeAliasInfo(), FreeGroupInfo(), FreeUserInfo(), GetUserDacl(), GetUserPrivileges(), NetGroupAddUser(), NetGroupDelUser(), NetGroupEnum(), NetGroupGetUsers(), NetGroupSetUsers(), NetLocalGroupEnum(), NetLocalGroupGetMembers(), NetUserEnum(), NetUserGetGroups(), NetUserGetInfo(), NetUserGetLocalGroups(), NetUserModalsGet(), OpenAliasByName(), OpenGroupByName(), OpenUserByName(), and SetAdministratorPassword().
NTSTATUS NTAPI SamGetAliasMembership | ( | IN SAM_HANDLE | DomainHandle, |
IN ULONG | PassedCount, | ||
IN PSID * | Sids, | ||
OUT PULONG | MembershipCount, | ||
OUT PULONG * | Aliases | ||
) |
Definition at line 994 of file samlib.c.
Referenced by GetUserPrivileges(), and NetUserGetLocalGroups().
NTSTATUS NTAPI SamGetDisplayEnumerationIndex | ( | IN SAM_HANDLE | DomainHandle, |
IN DOMAIN_DISPLAY_INFORMATION | DisplayInformation, | ||
IN PUNICODE_STRING | Prefix, | ||
OUT PULONG | Index | ||
) |
Definition at line 1061 of file samlib.c.
Referenced by NetGetDisplayInformationIndex().
NTSTATUS NTAPI SamGetGroupsForUser | ( | IN SAM_HANDLE | UserHandle, |
OUT PGROUP_MEMBERSHIP * | Groups, | ||
OUT PULONG | MembershipCount | ||
) |
Definition at line 1094 of file samlib.c.
Referenced by GetUserPrivileges(), and NetUserGetGroups().
NTSTATUS NTAPI SamGetMembersInAlias | ( | IN SAM_HANDLE | AliasHandle, |
OUT PSID ** | MemberIds, | ||
OUT PULONG | MemberCount | ||
) |
Definition at line 1138 of file samlib.c.
Referenced by NetLocalGroupGetMembers().
NTSTATUS NTAPI SamGetMembersInGroup | ( | IN SAM_HANDLE | GroupHandle, |
OUT PULONG * | MemberIds, | ||
OUT PULONG * | Attributes, | ||
OUT PULONG | MemberCount | ||
) |
Definition at line 1180 of file samlib.c.
Referenced by NetGroupGetUsers(), and NetGroupSetUsers().
NTSTATUS NTAPI SamLookupDomainInSamServer | ( | IN SAM_HANDLE | ServerHandle, |
IN PUNICODE_STRING | Name, | ||
OUT PSID * | DomainId | ||
) |
Definition at line 1229 of file samlib.c.
NTSTATUS NTAPI SamLookupIdsInDomain | ( | IN SAM_HANDLE | DomainHandle, |
IN ULONG | Count, | ||
IN PULONG | RelativeIds, | ||
OUT PUNICODE_STRING * | Names, | ||
OUT PSID_NAME_USE *Use | OPTIONAL | ||
) |
Definition at line 1256 of file samlib.c.
Referenced by NetGroupGetUsers(), and NetUserGetLocalGroups().
NTSTATUS NTAPI SamLookupNamesInDomain | ( | IN SAM_HANDLE | DomainHandle, |
IN ULONG | Count, | ||
IN PUNICODE_STRING | Names, | ||
OUT PULONG * | RelativeIds, | ||
OUT PSID_NAME_USE * | Use | ||
) |
Definition at line 1371 of file samlib.c.
Referenced by NetGroupAddUser(), NetGroupDelUser(), NetGroupSetUsers(), NetUserGetGroups(), NetUserGetInfo(), NetUserGetLocalGroups(), OpenAliasByName(), OpenGroupByName(), and OpenUserByName().
NTSTATUS NTAPI SamOpenAlias | ( | IN SAM_HANDLE | DomainHandle, |
IN ACCESS_MASK | DesiredAccess, | ||
IN ULONG | AliasId, | ||
OUT PSAM_HANDLE | AliasHandle | ||
) |
Definition at line 1448 of file samlib.c.
Referenced by NetLocalGroupEnum(), and OpenAliasByName().
NTSTATUS NTAPI SamOpenDomain | ( | IN SAM_HANDLE | ServerHandle, |
IN ACCESS_MASK | DesiredAccess, | ||
IN PSID | DomainId, | ||
OUT PSAM_HANDLE | DomainHandle | ||
) |
Definition at line 1477 of file samlib.c.
Referenced by ApplyAccountSettings(), ApplyLockoutSettings(), ApplyPasswordSettings(), NetUserEnum(), NetUserGetGroups(), NetUserGetInfo(), NetUserGetLocalGroups(), NetUserModalsGet(), OpenAccountDomain(), OpenBuiltinDomain(), SetAccountsDomainSid(), and SetAdministratorPassword().
NTSTATUS NTAPI SamOpenGroup | ( | IN SAM_HANDLE | DomainHandle, |
IN ACCESS_MASK | DesiredAccess, | ||
IN ULONG | GroupId, | ||
OUT PSAM_HANDLE | GroupHandle | ||
) |
Definition at line 1506 of file samlib.c.
Referenced by NetGroupEnum(), and OpenGroupByName().
NTSTATUS NTAPI SamOpenUser | ( | IN SAM_HANDLE | DomainHandle, |
IN ACCESS_MASK | DesiredAccess, | ||
IN ULONG | UserId, | ||
OUT PSAM_HANDLE | UserHandle | ||
) |
Definition at line 1535 of file samlib.c.
Referenced by EnableAccount(), NetUserEnum(), NetUserGetGroups(), NetUserGetInfo(), OpenUserByName(), SetAdministratorPassword(), and SetNewAccountName().
NTSTATUS NTAPI SamQueryDisplayInformation | ( | IN SAM_HANDLE | DomainHandle, |
IN DOMAIN_DISPLAY_INFORMATION | DisplayInformation, | ||
IN ULONG | Index, | ||
IN ULONG | EntryCount, | ||
IN ULONG | PreferredMaximumLength, | ||
OUT PULONG | TotalAvailable, | ||
OUT PULONG | TotalReturned, | ||
OUT PULONG | ReturnedEntryCount, | ||
OUT PVOID * | SortedBuffer | ||
) |
Definition at line 1564 of file samlib.c.
Referenced by NetQueryDisplayInformation().
NTSTATUS NTAPI SamQueryInformationAlias | ( | IN SAM_HANDLE | AliasHandle, |
IN ALIAS_INFORMATION_CLASS | AliasInformationClass, | ||
OUT PVOID * | Buffer | ||
) |
Definition at line 1650 of file samlib.c.
Referenced by NetLocalGroupEnum(), and NetLocalGroupGetInfo().
NTSTATUS NTAPI SamQueryInformationDomain | ( | IN SAM_HANDLE | DomainHandle, |
IN DOMAIN_INFORMATION_CLASS | DomainInformationClass, | ||
OUT PVOID * | Buffer | ||
) |
Definition at line 1677 of file samlib.c.
Referenced by ApplyLockoutSettings(), ApplyPasswordSettings(), and NetUserModalsGet().
NTSTATUS NTAPI SamQueryInformationGroup | ( | IN SAM_HANDLE | GroupHandle, |
IN GROUP_INFORMATION_CLASS | GroupInformationClass, | ||
OUT PVOID * | Buffer | ||
) |
Definition at line 1704 of file samlib.c.
Referenced by NetGroupEnum(), and NetGroupGetInfo().
NTSTATUS NTAPI SamQueryInformationUser | ( | IN SAM_HANDLE | UserHandle, |
IN USER_INFORMATION_CLASS | UserInformationClass, | ||
OUT PVOID * | Buffer | ||
) |
Definition at line 1731 of file samlib.c.
Referenced by BuildUserInfoBuffer(), EnableAccount(), and SetAdministratorPassword().
NTSTATUS NTAPI SamQuerySecurityObject | ( | IN SAM_HANDLE | ObjectHandle, |
IN SECURITY_INFORMATION | SecurityInformation, | ||
OUT PSECURITY_DESCRIPTOR * | SecurityDescriptor | ||
) |
Definition at line 1758 of file samlib.c.
Referenced by GetUserDacl().
Definition at line 1800 of file samlib.c.
Referenced by NetLocalGroupDelMembers().
Definition at line 1825 of file samlib.c.
Definition at line 1850 of file samlib.c.
Referenced by NetGroupDelUser(), and NetGroupSetUsers().
NTSTATUS NTAPI SamRemoveMultipleMembersFromAlias | ( | IN SAM_HANDLE | AliasHandle, |
IN PSID * | MemberIds, | ||
IN ULONG | MemberCount | ||
) |
Definition at line 1875 of file samlib.c.
NTSTATUS NTAPI SamSetInformationAlias | ( | IN SAM_HANDLE | AliasHandle, |
IN ALIAS_INFORMATION_CLASS | AliasInformationClass, | ||
IN PVOID | Buffer | ||
) |
Definition at line 1919 of file samlib.c.
Referenced by NetLocalGroupAdd(), and NetLocalGroupSetInfo().
NTSTATUS NTAPI SamSetInformationDomain | ( | IN SAM_HANDLE | DomainHandle, |
IN DOMAIN_INFORMATION_CLASS | DomainInformationClass, | ||
IN PVOID | Buffer | ||
) |
Definition at line 1946 of file samlib.c.
Referenced by ApplyLockoutSettings(), ApplyPasswordSettings(), and SetAccountsDomainSid().
NTSTATUS NTAPI SamSetInformationGroup | ( | IN SAM_HANDLE | GroupHandle, |
IN GROUP_INFORMATION_CLASS | GroupInformationClass, | ||
IN PVOID | Buffer | ||
) |
Definition at line 1973 of file samlib.c.
Referenced by NetGroupAdd(), and NetGroupSetInfo().
NTSTATUS NTAPI SamSetInformationUser | ( | IN SAM_HANDLE | UserHandle, |
IN USER_INFORMATION_CLASS | UserInformationClass, | ||
IN PVOID | Buffer | ||
) |
Definition at line 2000 of file samlib.c.
Referenced by EnableAccount(), SetAdministratorPassword(), SetNewAccountName(), and SetUserInfo().
NTSTATUS NTAPI SamSetMemberAttributesOfGroup | ( | IN SAM_HANDLE | GroupHandle, |
IN ULONG | MemberId, | ||
IN ULONG | Attributes | ||
) |
Definition at line 2205 of file samlib.c.
Referenced by NetGroupSetUsers().
NTSTATUS NTAPI SamSetSecurityObject | ( | IN SAM_HANDLE | ObjectHandle, |
IN SECURITY_INFORMATION | SecurityInformation, | ||
IN PSECURITY_DESCRIPTOR | SecurityDescriptor | ||
) |
Definition at line 2232 of file samlib.c.
NTSTATUS NTAPI SamShutdownSamServer | ( | IN SAM_HANDLE | ServerHandle | ) |
Definition at line 2287 of file samlib.c.