QuerySecurityPackageInfoA function (sspi.h)
Retrieves information about a specified security package. This information includes the bounds on sizes of authentication information, credentials, and contexts.
Syntax
SECURITY_STATUS SEC_ENTRY QuerySecurityPackageInfoA(
[in] LPSTR pszPackageName,
[out] PSecPkgInfoA *ppPackageInfo
);
Parameters
[in] pszPackageName
Pointer to a null-terminated string that specifies the name of the security package.
[out] ppPackageInfo
Pointer to a variable that receives a pointer to a SecPkgInfo structure containing information about the specified security package.
Return value
If the function succeeds, the return value is SEC_E_OK.
If the function fails, the return value is a nonzero error code.
Remarks
The caller must call the FreeContextBuffer function to free the buffer returned in ppPackageInfo.
Note
The sspi.h header defines QuerySecurityPackageInfo as an alias that automatically selects the ANSI or Unicode version of this function based on the definition of the UNICODE preprocessor constant. Mixing usage of the encoding-neutral alias with code that is not encoding-neutral can lead to mismatches that result in compilation or runtime errors. For more information, see Conventions for Function Prototypes.
Requirements
Requirement | Value |
---|---|
Minimum supported client | Windows XP [desktop apps only] |
Minimum supported server | Windows Server 2003 [desktop apps only] |
Target Platform | Windows |
Header | sspi.h (include Security.h) |
Library | Secur32.lib |
DLL | Secur32.dll |