GetSidLengthRequired function
The GetSidLengthRequired function returns the length, in bytes, of the buffer required to store a SID with a specified number of subauthorities.
Syntax
DWORD WINAPI GetSidLengthRequired( _In_ UCHAR nSubAuthorityCount );
Parameters
- nSubAuthorityCount [in]
-
Specifies the number of subauthorities to be stored in the SID structure.
Return value
The return value is the length, in bytes, of the buffer required to store the SID structure. This function cannot fail.
Remarks
The SID structure specified in nSubAuthorityCount uses a 32-bit RID value. For applications that require longer RID values, use CreateWellKnownSid and related functions.
Requirements
|
Minimum supported client |
Windows XP [desktop apps only] |
|---|---|
|
Minimum supported server |
Windows Server 2003 [desktop apps only] |
|
Header |
|
|
Library |
|
|
DLL |
|
See also
- Access Control Overview
- Basic Access Control Functions
- AllocateAndInitializeSid
- CreateWellKnownSid
- GetLengthSid
- GetSidIdentifierAuthority
- GetSidSubAuthority
- GetSidSubAuthorityCount
- InitializeSid
- IsValidSid
- SID
Show: