99 SIZE_T AccountNameLength, DomainNameLength;
103 AccountNameLength =
wcslen(AccountName);
104 DomainNameLength =
wcslen(DomainName);
112 if (SidEntry ==
NULL)
133 *
p = SubAuthorities[
i];
175 *SidPtr = SidEntry->
Sid;
184 WCHAR szAccountName[80];
185 WCHAR szDomainName[80];
186 ULONG SubAuthorities[8];
714 ListEntry = ListEntry->
Flink;
738 ListEntry = ListEntry->
Flink;
764 ListEntry = ListEntry->
Flink;
787 if (DomainsBuffer ==
NULL)
794 if (AccountsBuffer ==
NULL)
828 AccountLength = (
Names[
i].Length /
sizeof(
WCHAR)) - DomainLength - 1;
832 if (DomainLength > 0)
872 if (AccountsBuffer !=
NULL)
883 if (DomainsBuffer !=
NULL)
896 *DomainNames = DomainsBuffer;
897 *AccountNames = AccountsBuffer;
913 while (i < ReferencedDomains->
Entries &&
943 Name->MaximumLength);
966 while (i < ReferencedDomains->
Entries &&
1073 for (
i = 0;
i < (
ULONG)RidCount;
i++)
1103 if (DomainSid ==
NULL)
1110 for (
i = 0;
i < (
ULONG)RidCount;
i++)
1141 for (
i = 0;
i < (
ULONG)RidCount;
i++)
1175 if (DomainNames[
i].
Length != 0)
1178 TRACE(
"Mapping name: %wZ\n", &AccountNames[
i]);
1223 if (DomainSid ==
NULL)
1234 if (DomainSid !=
NULL)
1338 TRACE(
"SamrConnect failed (Status %08lx)\n",
Status);
1348 TRACE(
"SamOpenDomain failed (Status %08lx)\n",
Status);
1359 if (DomainNames[
i].
Length != 0)
1362 TRACE(
"Mapping name: %wZ\n", &AccountNames[
i]);
1371 TRACE(
"Found relative ID: %lu\n", RelativeIds.
Element[0]);
1402 if (DomainHandle !=
NULL)
1405 if (ServerHandle !=
NULL)
1436 TRACE(
"SamrConnect failed (Status %08lx)\n",
Status);
1446 TRACE(
"SamOpenDomain failed (Status %08lx)\n",
Status);
1457 if (DomainNames[
i].
Length != 0)
1460 TRACE(
"Mapping name: %wZ\n", &AccountNames[
i]);
1469 TRACE(
"Found relative ID: %lu\n", RelativeIds.
Element[0]);
1500 if (DomainHandle !=
NULL)
1503 if (ServerHandle !=
NULL)
1533 if (DomainNames[
i].
Length == 0)
1536 TRACE(
"Mapping name: %wZ\\%wZ\n", &DomainNames[
i], &AccountNames[
i]);
1543 TRACE(
"Found it! (%wZ\\%wZ)\n", &
ptr->DomainName, &
ptr->AccountName);
1584 if (DomainSid ==
NULL)
1595 if (DomainSid !=
NULL)
1640 TRACE(
"SamrConnect failed (Status %08lx)\n",
Status);
1650 TRACE(
"SamOpenDomain failed (Status %08lx)\n",
Status);
1661 if (DomainNames[
i].
Length == 0)
1667 TRACE(
"Mapping name: %wZ\\%wZ\n", &DomainNames[
i], &AccountNames[
i]);
1705 if (DomainHandle !=
NULL)
1708 if (ServerHandle !=
NULL)
1737 TRACE(
"SamrConnect failed (Status %08lx)\n",
Status);
1747 TRACE(
"SamOpenDomain failed (Status %08lx)\n",
Status);
1758 if (DomainNames[
i].
Length == 0)
1764 TRACE(
"Mapping name: %wZ\\%wZ\n", &DomainNames[
i], &AccountNames[
i]);
1802 if (DomainHandle !=
NULL)
1805 if (ServerHandle !=
NULL)
1819 DWORD LookupOptions,
1820 DWORD ClientRevision)
1826 ULONG SidsBufferLength;
1835 *ReferencedDomains =
NULL;
1839 if (SidsBuffer ==
NULL)
1847 if (DomainsBuffer ==
NULL)
1878 TRACE(
"LsapSplitNames failed! (Status %lx)\n",
Status);
1893 TRACE(
"LsapLookupIsolatedNames failed! (Status %lx)\n",
Status);
1897 if (Mapped ==
Count)
1911 TRACE(
"LsapLookupIsolatedBuiltinNames failed! (Status %lx)\n",
Status);
1915 if (Mapped ==
Count)
1929 TRACE(
"LsapLookupIsolatedAccountNames failed! (Status %lx)\n",
Status);
1933 if (Mapped ==
Count)
1946 TRACE(
"LsapLookupFullyQualifiedWellKnownNames failed! (Status %lx)\n",
Status);
1950 if (Mapped ==
Count)
1963 TRACE(
"LsapLookupBuiltinNames failed! (Status %lx)\n",
Status);
1967 if (Mapped ==
Count)
1981 TRACE(
"LsapLookupAccountNames failed! (Status %lx)\n",
Status);
1985 if (Mapped ==
Count)
1991 if (DomainNames !=
NULL)
2003 if (AccountNames !=
NULL)
2023 if (DomainsBuffer !=
NULL)
2032 if (SidsBuffer !=
NULL)
2039 *ReferencedDomains = DomainsBuffer;
2041 TranslatedSids->
Sids = SidsBuffer;
2042 *MappedCount = Mapped;
2046 else if (Mapped <
Count)
2075 TRACE(
"Mapping SID: %S\n", SidString);
2082 NamesBuffer[
i].
Use =
ptr->Use;
2083 NamesBuffer[
i].
Flags = 0;
2096 if (
ptr->DomainName.Length == 0)
2122 TRACE(
"Mapped to: %wZ\n", &NamesBuffer[
i].
Name);
2145 ULONG RelativeIds[1];
2154 TRACE(
"SamrConnect failed (Status %08lx)\n",
Status);
2164 TRACE(
"SamOpenDomain failed (Status %08lx)\n",
Status);
2175 TRACE(
"Mapping SID: %S\n", SidString);
2181 TRACE(
"Found builtin domain!\n");
2184 NamesBuffer[
i].
Flags = 0;
2206 TRACE(
"Mapped to: %wZ\n", &NamesBuffer[
i].
Name);
2212 TRACE(
"Found builtin domain account!\n");
2224 NamesBuffer[
i].
Flags = 0;
2239 Names.Element[0].Buffer,
2240 Names.Element[0].MaximumLength);
2254 TRACE(
"Mapped to: %wZ\n", &NamesBuffer[
i].
Name);
2262 if (DomainHandle !=
NULL)
2265 if (ServerHandle !=
NULL)
2284 ULONG RelativeIds[1];
2293 TRACE(
"SamrConnect failed (Status %08lx)\n",
Status);
2303 TRACE(
"SamOpenDomain failed (Status %08lx)\n",
Status);
2314 TRACE(
"Mapping SID: %S\n", SidString);
2320 TRACE(
"Found account domain!\n");
2323 NamesBuffer[
i].
Flags = 0;
2345 TRACE(
"Mapped to: %wZ\n", &NamesBuffer[
i].
Name);
2351 TRACE(
"Found account domain account!\n");
2363 NamesBuffer[
i].
Flags = 0;
2378 Names.Element[0].Buffer,
2379 Names.Element[0].MaximumLength);
2393 TRACE(
"Mapped to: %wZ\n", &NamesBuffer[
i].
Name);
2401 if (DomainHandle !=
NULL)
2404 if (ServerHandle !=
NULL)
2417 DWORD LookupOptions,
2418 DWORD ClientRevision)
2422 ULONG NamesBufferLength;
2429 if (NamesBuffer ==
NULL)
2436 if (DomainsBuffer ==
NULL)
2460 NamesBuffer[
i].
Flags = 0;
2473 if (Mapped == SidEnumBuffer->
Entries)
2486 if (Mapped == SidEnumBuffer->
Entries)
2499 if (Mapped == SidEnumBuffer->
Entries)
2503 TRACE(
"done Status: %lx Mapped: %lu\n",
Status, Mapped);
2507 if (DomainsBuffer !=
NULL)
2515 if (NamesBuffer !=
NULL)
2520 *ReferencedDomains = DomainsBuffer;
2522 TranslatedNames->
Names = NamesBuffer;
2523 *MappedCount = Mapped;
2527 else if (Mapped < SidEnumBuffer->
Entries)
static const ENTRY Entries[]
wchar_t * PSAMPR_SERVER_NAME
static SID_IDENTIFIER_AUTHORITY NtAuthority
PVOID NTAPI RtlAllocateHeap(IN PVOID HeapHandle, IN ULONG Flags, IN SIZE_T Size)
BOOLEAN NTAPI RtlFreeHeap(IN PVOID HeapHandle, IN ULONG Flags, IN PVOID HeapBase)
#define NT_SUCCESS(StatCode)
BOOL WINAPI ConvertSidToStringSidW(PSID Sid, LPWSTR *StringSid)
HMODULE WINAPI GetModuleHandleW(LPCWSTR lpModuleName)
SID_IDENTIFIER_AUTHORITY CreatorSidAuthority
UNICODE_STRING BuiltinDomainName
UNICODE_STRING AccountDomainName
SID_IDENTIFIER_AUTHORITY NullSidAuthority
SID_IDENTIFIER_AUTHORITY LocalSidAuthority
SID_IDENTIFIER_AUTHORITY WorldSidAuthority
struct _SAMPR_RETURNED_USTRING_ARRAY * PSAMPR_RETURNED_USTRING_ARRAY
PWELL_KNOWN_SID LsapLookupWellKnownSid(PSID Sid)
struct _SAMPR_RETURNED_USTRING_ARRAY SAMPR_RETURNED_USTRING_ARRAY
static NTSTATUS LsapAddAuthorityToDomainsList(PLSAPR_REFERENCED_DOMAIN_LIST ReferencedDomains, PSID Sid, PULONG Index)
static NTSTATUS LsapLookupBuiltinNames(DWORD Count, PRPC_UNICODE_STRING DomainNames, PRPC_UNICODE_STRING AccountNames, PLSAPR_REFERENCED_DOMAIN_LIST DomainsBuffer, PLSAPR_TRANSLATED_SID_EX2 SidsBuffer, PULONG Mapped)
static NTSTATUS LsapLookupWellKnownSids(PLSAPR_SID_ENUM_BUFFER SidEnumBuffer, PLSAPR_TRANSLATED_NAME_EX NamesBuffer, PLSAPR_REFERENCED_DOMAIN_LIST DomainsBuffer, PULONG Mapped)
static PSID CreateDomainSidFromAccountSid(PSID AccountSid)
LIST_ENTRY WellKnownSidListHead
PSID LsapAdministratorsSid
VOID NTAPI SamIFree_SAMPR_ULONG_ARRAY(PSAMPR_ULONG_ARRAY Ptr)
ULONG LsapGetRelativeIdFromSid(PSID Sid_)
PWELL_KNOWN_SID LsapLookupFullyQualifiedWellKnownName(PUNICODE_STRING AccountName, PUNICODE_STRING DomainName)
static NTSTATUS LsapLookupFullyQualifiedWellKnownNames(DWORD Count, PRPC_UNICODE_STRING DomainNames, PRPC_UNICODE_STRING AccountNames, PLSAPR_REFERENCED_DOMAIN_LIST DomainsBuffer, PLSAPR_TRANSLATED_SID_EX2 SidsBuffer, PULONG Mapped)
static PSID LsapCopySid(PSID SrcSid)
PWELL_KNOWN_SID LsapLookupIsolatedWellKnownName(PUNICODE_STRING AccountName)
static NTSTATUS LsapLookupBuiltinDomainSids(PLSAPR_SID_ENUM_BUFFER SidEnumBuffer, PLSAPR_TRANSLATED_NAME_EX NamesBuffer, PLSAPR_REFERENCED_DOMAIN_LIST DomainsBuffer, PULONG Mapped)
NTSTATUS LsapLookupNames(DWORD Count, PRPC_UNICODE_STRING Names, PLSAPR_REFERENCED_DOMAIN_LIST *ReferencedDomains, PLSAPR_TRANSLATED_SIDS_EX2 TranslatedSids, LSAP_LOOKUP_LEVEL LookupLevel, DWORD *MappedCount, DWORD LookupOptions, DWORD ClientRevision)
static BOOLEAN LsapIsPrefixSid(IN PSID PrefixSid, IN PSID Sid)
NTSTATUS NTAPI SamrLookupIdsInDomain(IN SAMPR_HANDLE DomainHandle, IN ULONG Count, IN ULONG *RelativeIds, OUT PSAMPR_RETURNED_USTRING_ARRAY Names, OUT PSAMPR_ULONG_ARRAY Use)
static NTSTATUS LsapSplitNames(DWORD Count, PRPC_UNICODE_STRING Names, PRPC_UNICODE_STRING *DomainNames, PRPC_UNICODE_STRING *AccountNames)
static PSID CreateSidFromSidAndRid(PSID SrcSid, ULONG RelativeId)
static NTSTATUS LsapLookupAccountNames(DWORD Count, PRPC_UNICODE_STRING DomainNames, PRPC_UNICODE_STRING AccountNames, PLSAPR_REFERENCED_DOMAIN_LIST DomainsBuffer, PLSAPR_TRANSLATED_SID_EX2 SidsBuffer, PULONG Mapped)
BOOLEAN LsapCreateSid(PSID_IDENTIFIER_AUTHORITY IdentifierAuthority, UCHAR SubAuthorityCount, PULONG SubAuthorities, PWSTR AccountName, PWSTR DomainName, SID_NAME_USE Use, PSID *SidPtr)
static NTSTATUS LsapLookupIsolatedAccountNames(DWORD Count, PRPC_UNICODE_STRING DomainNames, PRPC_UNICODE_STRING AccountNames, PLSAPR_REFERENCED_DOMAIN_LIST DomainsBuffer, PLSAPR_TRANSLATED_SID_EX2 SidsBuffer, PULONG Mapped)
static NTSTATUS LsapLookupAccountDomainSids(PLSAPR_SID_ENUM_BUFFER SidEnumBuffer, PLSAPR_TRANSLATED_NAME_EX NamesBuffer, PLSAPR_REFERENCED_DOMAIN_LIST DomainsBuffer, PULONG Mapped)
NTSTATUS NTAPI SamrLookupNamesInDomain(IN SAMPR_HANDLE DomainHandle, IN ULONG Count, IN RPC_UNICODE_STRING Names[], OUT PSAMPR_ULONG_ARRAY RelativeIds, OUT PSAMPR_ULONG_ARRAY Use)
NTSTATUS NTAPI SamrOpenDomain(IN SAMPR_HANDLE ServerHandle, IN ACCESS_MASK DesiredAccess, IN PRPC_SID DomainId, OUT SAMPR_HANDLE *DomainHandle)
wchar_t * PSAMPR_SERVER_NAME
NTSTATUS NTAPI SamrCloseHandle(IN OUT SAMPR_HANDLE *SamHandle)
NTSTATUS LsapLookupSids(PLSAPR_SID_ENUM_BUFFER SidEnumBuffer, PLSAPR_REFERENCED_DOMAIN_LIST *ReferencedDomains, PLSAPR_TRANSLATED_NAMES_EX TranslatedNames, LSAP_LOOKUP_LEVEL LookupLevel, DWORD *MappedCount, DWORD LookupOptions, DWORD ClientRevision)
static NTSTATUS LsapLookupIsolatedNames(DWORD Count, PRPC_UNICODE_STRING DomainNames, PRPC_UNICODE_STRING AccountNames, PLSAPR_REFERENCED_DOMAIN_LIST DomainsBuffer, PLSAPR_TRANSLATED_SID_EX2 SidsBuffer, PULONG Mapped)
struct _WELL_KNOWN_SID * PWELL_KNOWN_SID
static NTSTATUS LsapLookupIsolatedBuiltinNames(DWORD Count, PRPC_UNICODE_STRING DomainNames, PRPC_UNICODE_STRING AccountNames, PLSAPR_REFERENCED_DOMAIN_LIST DomainsBuffer, PLSAPR_TRANSLATED_SID_EX2 SidsBuffer, PULONG Mapped)
struct _WELL_KNOWN_SID WELL_KNOWN_SID
VOID NTAPI SamIFree_SAMPR_RETURNED_USTRING_ARRAY(PSAMPR_RETURNED_USTRING_ARRAY Ptr)
NTSTATUS NTAPI SamrConnect(IN PSAMPR_SERVER_NAME ServerName, OUT SAMPR_HANDLE *ServerHandle, IN ACCESS_MASK DesiredAccess)
NTSTATUS LsapInitSids(VOID)
static NTSTATUS LsapAddDomainToDomainsList(PLSAPR_REFERENCED_DOMAIN_LIST ReferencedDomains, PUNICODE_STRING Name, PSID Sid, PULONG Index)
INT LsapLoadString(HINSTANCE hInstance, UINT uId, LPWSTR lpBuffer, INT nBufferMax)
#define IDS_PRINCIPAL_SELF_RID
#define IDS_ALIAS_RID_ADMINS
#define IDS_ALIAS_RID_RAS_SERVERS
#define IDS_TERMINAL_SERVER_RID
#define IDS_ALIAS_RID_POWER_USERS
#define IDS_ALIAS_RID_PREW2KCOMPACCESS
#define IDS_REMOTE_LOGON_RID
#define IDS_CREATOR_GROUP_RID
#define IDS_CREATOR_OWNER_SERVER_RID
#define IDS_ALIAS_RID_GUESTS
#define IDS_RESTRICTED_CODE_RID
#define IDS_ALIAS_RID_ACCOUNT_OPS
#define IDS_CREATOR_GROUP_SERVER_RID
#define IDS_NETWORK_SERVICE_RID
#define IDS_ALIAS_RID_USERS
#define IDS_AUTHENTICATED_USER_RID
#define IDS_ANONYMOUS_LOGON_RID
#define IDS_ENTERPRISE_CONTROLLERS_RID
#define IDS_ALIAS_RID_PRINT_OPS
#define IDS_BUILTIN_DOMAIN_RID
#define IDS_LOCAL_SERVICE_RID
#define IDS_THIS_ORGANIZATION_RID
#define IDS_INTERACTIVE_RID
#define IDS_ALIAS_RID_REMOTE_DESKTOP_USERS
#define IDS_CREATOR_OWNER_RID
#define IDS_ALIAS_RID_SYSTEM_OPS
#define IDS_LOCAL_SYSTEM_RID
#define IDS_ALIAS_RID_REPLICATOR
#define IDS_ALIAS_RID_NETWORK_CONFIGURATION_OPS
#define IDS_ALIAS_RID_BACKUP_OPS
#define InsertTailList(ListHead, Entry)
#define InitializeListHead(ListHead)
_Must_inspect_result_ _In_ PFSRTL_PER_STREAM_CONTEXT Ptr
GLdouble GLdouble GLdouble GLdouble q
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
HLOCAL NTAPI LocalFree(HLOCAL hMem)
_CRTIMP size_t __cdecl wcslen(_In_z_ const wchar_t *_Str)
NTSYSAPI BOOLEAN WINAPI RtlCopySid(DWORD, PSID, PSID)
void *__RPC_USER MIDL_user_allocate(SIZE_T size)
void __RPC_USER MIDL_user_free(void *p)
enum _SID_NAME_USE SID_NAME_USE
struct _LSAPR_TRANSLATED_SID_EX2 LSAPR_TRANSLATED_SID_EX2
struct _LSAPR_TRANSLATED_NAME_EX LSAPR_TRANSLATED_NAME_EX
enum _LSAP_LOOKUP_LEVEL LSAP_LOOKUP_LEVEL
NTSYSAPI PULONG NTAPI RtlSubAuthoritySid(_In_ PSID Sid, _In_ ULONG SubAuthority)
NTSYSAPI ULONG NTAPI RtlLengthRequiredSid(IN ULONG SubAuthorityCount)
_In_ PSID_IDENTIFIER_AUTHORITY _In_ UCHAR SubAuthorityCount
NTSYSAPI ULONG NTAPI RtlLengthSid(IN PSID Sid)
_In_ ULONG _In_ ACCESS_MASK _In_ PSID Sid
NTSYSAPI PSID_IDENTIFIER_AUTHORITY NTAPI RtlIdentifierAuthoritySid(PSID Sid)
NTSYSAPI BOOLEAN NTAPI RtlEqualSid(_In_ PSID Sid1, _In_ PSID Sid2)
_In_ PSID_IDENTIFIER_AUTHORITY IdentifierAuthority
NTSYSAPI BOOLEAN NTAPI RtlEqualUnicodeString(PUNICODE_STRING String1, PUNICODE_STRING String2, BOOLEAN CaseInSensitive)
#define UNICODE_STRING_MAX_CHARS
_In_ ULONG _In_ ULONG _In_ ULONG Length
NTSYSAPI PUCHAR NTAPI RtlSubAuthorityCountSid(IN PSID Sid)
NTSYSAPI NTSTATUS NTAPI RtlInitializeSid(IN OUT PSID Sid, IN PSID_IDENTIFIER_AUTHORITY IdentifierAuthority, IN UCHAR SubAuthorityCount)
#define SAM_SERVER_LOOKUP_DOMAIN
#define SAM_SERVER_CONNECT
#define STATUS_NONE_MAPPED
#define STATUS_SOME_NOT_MAPPED
_CRTIMP wchar_t *__cdecl wcscpy(_Out_writes_z_(_String_length_(_Source)+1) wchar_t *_Dest, _In_z_ const wchar_t *_Source)
struct _LIST_ENTRY * Flink
PLSAPR_TRUST_INFORMATION Domains
PLSAPR_SID_INFORMATION SidInfo
PLSAPR_TRANSLATED_NAME_EX Names
PLSAPR_TRANSLATED_SID_EX2 Sids
unsigned short MaximumLength
PRPC_UNICODE_STRING Element
SID_IDENTIFIER_AUTHORITY IdentifierAuthority
UNICODE_STRING AccountName
UNICODE_STRING DomainName
#define RTL_CONSTANT_STRING(s)
#define RtlCopyMemory(Destination, Source, Length)
#define CONTAINING_RECORD(address, type, field)
#define STATUS_INSUFFICIENT_RESOURCES
_In_ WDFCOLLECTION _In_ ULONG Index
_Must_inspect_result_ _In_ WDFDEVICE _In_ ULONG _In_ ACCESS_MASK DesiredAccess
_In_ WDFDMATRANSACTION _In_ size_t MaximumLength
#define SECURITY_ANONYMOUS_LOGON_RID
#define DOMAIN_ALIAS_RID_USERS
#define DOMAIN_ALIAS_RID_GUESTS
#define DOMAIN_ALIAS_RID_NETWORK_CONFIGURATION_OPS
#define SECURITY_BUILTIN_DOMAIN_RID
#define SECURITY_LOCAL_RID
#define SECURITY_DIALUP_RID
#define SECURITY_SERVICE_RID
#define SECURITY_PROXY_RID
#define SECURITY_INTERACTIVE_RID
#define SECURITY_WORLD_RID
#define SECURITY_CREATOR_GROUP_SERVER_RID
#define DOMAIN_ALIAS_RID_REMOTE_DESKTOP_USERS
#define DOMAIN_ALIAS_RID_SYSTEM_OPS
#define SECURITY_LOCAL_SYSTEM_RID
#define SECURITY_AUTHENTICATED_USER_RID
#define SECURITY_NULL_RID
#define DOMAIN_ALIAS_RID_ACCOUNT_OPS
#define SECURITY_RESTRICTED_CODE_RID
#define DOMAIN_ALIAS_RID_RAS_SERVERS
#define SECURITY_TERMINAL_SERVER_RID
#define DOMAIN_ALIAS_RID_BACKUP_OPS
#define SECURITY_BATCH_RID
#define DOMAIN_ALIAS_RID_PRINT_OPS
#define SECURITY_CREATOR_OWNER_SERVER_RID
#define DOMAIN_ALIAS_RID_REPLICATOR
#define SECURITY_LOCAL_SERVICE_RID
#define SECURITY_THIS_ORGANIZATION_RID
#define SECURITY_PRINCIPAL_SELF_RID
* PSID_IDENTIFIER_AUTHORITY
#define SECURITY_CREATOR_OWNER_RID
#define DOMAIN_ALIAS_RID_POWER_USERS
#define DOMAIN_ALIAS_RID_PREW2KCOMPACCESS
#define SECURITY_ENTERPRISE_CONTROLLERS_RID
#define SECURITY_NETWORK_RID
#define SECURITY_NETWORK_SERVICE_RID
#define DOMAIN_ALIAS_RID_ADMINS
#define SECURITY_REMOTE_LOGON_RID
#define SECURITY_CREATOR_GROUP_RID