Events
May 19, 6 PM - May 23, 12 AM
Calling all developers, creators, and AI innovators to join us in Seattle @Microsoft Build May 19-22.
Register todayThis browser is no longer supported.
Upgrade to Microsoft Edge to take advantage of the latest features, security updates, and technical support.
The CreateWellKnownSid function creates a SID for predefined aliases.
BOOL CreateWellKnownSid(
[in] WELL_KNOWN_SID_TYPE WellKnownSidType,
[in, optional] PSID DomainSid,
[out, optional] PSID pSid,
[in, out] DWORD *cbSid
);
[in] WellKnownSidType
Member of the WELL_KNOWN_SID_TYPE enumeration that specifies what the SID will identify.
[in, optional] DomainSid
A pointer to a SID that identifies the domain to use when creating the SID. Pass NULL to use the local computer.
[out, optional] pSid
A pointer to memory where CreateWellKnownSid will store the new SID.
[in, out] cbSid
A pointer to a DWORD that contains the number of bytes available at pSid. The CreateWellKnownSid function stores the number of bytes actually used at this location.
If the function succeeds, the return value is nonzero.
If the function fails, the return value is zero. For extended error information, call GetLastError.
Requirement | Value |
---|---|
Minimum supported client | Windows XP [desktop apps | UWP apps] |
Minimum supported server | Windows Server 2003 [desktop apps | UWP apps] |
Target Platform | Windows |
Header | securitybaseapi.h (include Windows.h) |
Library | Advapi32.lib |
DLL | Advapi32.dll |
Events
May 19, 6 PM - May 23, 12 AM
Calling all developers, creators, and AI innovators to join us in Seattle @Microsoft Build May 19-22.
Register today