IEnroll2::GetKeyLen method (xenroll.h)
[This method is no longer available for use as of Windows Server 2008 and Windows Vista.]
The GetKeyLen method retrieves the minimum and maximum key lengths for the signature and exchange keys. This method was first defined in the IEnroll2 interface. The values retrieved by this method are dependent upon the current cryptographic service provider.
HRESULT GetKeyLen( [in] BOOL fMin, [in] BOOL fExchange, [out] LONG *pdwKeySize );
Boolean value indicating which key length (minimum or maximum) is retrieved. If fMin is TRUE, the minimum key length is retrieved; if it is FALSE, the maximum key length is retrieved.
Boolean value indicating the type of key. If fExchange is TRUE, the exchange key length is retrieved; if it is FALSE, the signature key length is retrieved.
Pointer that receives the key's minimum or maximum length, in bits.
The return value is an HRESULT. A value of S_OK indicates success, and *pdwKeySize will be the value representing the length (in bits) for the key's minimum or maximum length.
Call this method to determine the minimum and maximum key lengths. If a CSP does not support this method, an error is returned.
|Minimum supported client||Windows XP [desktop apps only]|
|Minimum supported server||Windows Server 2003 [desktop apps only]|