Available in LEADTOOLS Medical Imaging toolkits. |
LDicomNet::GetPeerAuthDataISCL
#include "ltdic.h"
L_UINT32 LDicomNet::GetPeerAuthDataISCL(pBuffer, nLength);
L_VOID *pBuffer; |
/* pointer to a buffer */ |
L_UINT32 *nLength; |
/* pointer to a 32-bit unsigned integer */ |
Gets the authentication data the peer computer sent during mutual authentication. This function is available in the PACS Imaging toolkits.
Parameter |
Description |
pBuffer |
Pointer to a buffer to be updated with the authentication data of the peer computer. This buffer must be 128 bytes long to hold the longest possible authentication data. |
nLength |
Pointer to an integer variable. This variable contains initially the size of the pBuffer array. After this function returns, it is updated with the actual size of the peer authentication data. |
Returns
DICOM_SUCCESS |
Success. The peer authentication data were copied into pBuffer and the variable pointed to by pLength was updated with the length of the authentication data. |
DICOM_ERROR_PARAMETER |
A parameter error occurred. The authentication data could not be retrieved. (pBuffer is NULL, or the value pointed to by pLength is not large enough to contain the entire peer authentication data.) |
Comments
If pBuffer is NULL or the value pointed to by pLength (size of pBuffer) is too small for the peer authentication data, the return value is DICOM_ERROR_PARAMETER and *nLength is updated with the required length of the peer authentication data. No other actions are performed.
This function can only be called by the receiver of a message, if the message is not successfully received.
Required DLLs and Libraries
LTDIC For a listing of the exact DLLs and Libraries needed, based on the toolkit version, refer to Files To Be Included With Your Application |
Win32, x64
See Also
Example
// LMyDicomNet is derived from LDicomNet L_VOID LMyDicomNet::OnSecureLinkReady(L_UINT32 nError) { if(nError != DICOM_SUCCESS) { AfxMessageBox(TEXT("ISCL parameter negotiation and mutual authentication failed")); return; } L_CHAR peerAuthData[128]; L_UINT32 n = 128; GetPeerAuthDataISCL(peerAuthData, &n); CString strMsg; strMsg.Format(TEXT("Connected with the peer identified by: %s\n"), peerAuthData); AfxMessageBox(strMsg); };