LSA_CRACK_SINGLE_NAME callback function (ntsecpkg.h)
The CrackSingleName function converts a name from one format to another.
Syntax
LSA_CRACK_SINGLE_NAME LsaCrackSingleName;
NTSTATUS LsaCrackSingleName(
[in] ULONG FormatOffered,
[in] BOOLEAN PerformAtGC,
[in] PUNICODE_STRING NameInput,
[in, optional] PUNICODE_STRING Prefix,
[in] ULONG RequestedFormat,
[out] PUNICODE_STRING CrackedName,
[out] PUNICODE_STRING DnsDomainName,
[out] PULONG SubStatus
)
{...}
Parameters
[in] FormatOffered
The format of the input name. The following table contains the valid values for this parameter.
Value | Meaning |
---|---|
|
Complete canonical name (for example, example.microsoft.com/software/someone). The domain-only version includes a trailing forward slash (/). |
|
Same as DS_CANONICAL_NAME except that the rightmost forward slash (/) is replaced with a newline character (\n), even in a domain-only case (for example, example.microsoft.com/software\nsomeone). |
|
A "friendly" display name. The display name is not necessarily the defining relative distinguished name (RDN). |
|
Fully qualified distinguished name (for example, CN=NameOfPerson,OU=Users,DC=Example,DC=Fabrikam,DC=Com). |
|
Windows account name (for example, Example\Name). The domain-only version includes trailing backslashes (\\). |
|
Generalized service principal name (for example, www/www.microsoft.com@microsoft.com). |
|
A security identifier (SID) for the object. This can be either the current SID or a SID from the object's SID history. The SID string can use either the standard string representation of a SID, or one of the string constants defined in Sddl.h. For information about converting a binary SID into a SID string, see SID Strings. This value is not valid for the formatDesired parameter. |
|
GUID string that the IIDFromString function returns (for example, {4fa050f0-f561-11cf-bdd9-00aa003a77b6}). |
|
Unknown name type. |
|
User principal name (for example, someone@example.microsoft.com). |
[in] PerformAtGC
Specifies whether to perform the translation at a global catalog server.
[in] NameInput
A pointer to a UNICODE_STRING structure that contains the name to convert.
[in, optional] Prefix
A pointer to a UNICODE_STRING structure that specifies a prefix for the name.
[in] RequestedFormat
The requested format of the cracked name. For a list of valid values, see the FormatOffered parameter.
[out] CrackedName
A pointer to a UNICODE_STRING structure that receives the reformatted name.
[out] DnsDomainName
A pointer to a UNICODE_STRING structure that receives the name of the domain that owns the name specified by the NameInput parameter.
[out] SubStatus
A pointer to a variable that receives additional information about the return value of the function call.
Return value
If the function succeeds, the function returns STATUS_SUCCESS.
If the function fails, it returns STATUS_UNSUCCESSFUL. For more information, see the value returned in the SubStatus parameter.
Remarks
A pointer to the CrackSingleName function is available in the LSA_SECPKG_FUNCTION_TABLE structure received by the SpInitialize function.
Requirements
Requirement | Value |
---|---|
Minimum supported client | Windows XP [desktop apps only] |
Minimum supported server | Windows Server 2003 [desktop apps only] |
Target Platform | Windows |
Header | ntsecpkg.h |