Click or drag to resize
Xcalibur Systems LLC Logo

SecurityHelperConvertStringSidToSid Method

The ConvertStringSidToSid function converts a string-format security identifier (SID) into a valid, functional SID.

ConvertStringSidToSid function


Namespace: Xcalibur.NativeMethods.V2.Security
Assembly: Xcalibur.NativeMethods.V2 (in Xcalibur.NativeMethods.V2.dll) Version: 1.0.1.0
Syntax
[DllImportAttribute("advapi32.dll", CharSet = CharSet.Auto)]
public static bool ConvertStringSidToSid(
	string sid,
	ref IntPtr sidPointer
)

Parameters

sid  String
A pointer to a null-terminated string containing the string-format SID to convert. The SID string can use either the standard S-R-I-S-S… format for SID strings, or the SID string constant format, such as "BA" for built-in administrators.
sidPointer  IntPtr
A pointer to a variable that receives a pointer to the converted SID.

Return Value

Boolean
If the function succeeds, the return value is nonzero. To determine whether the function adjusted all of the specified privileges, call .
See Also