DigestFunction callback function

An application-defined callback function used by the ImageGetDigestStream function to process data.

The DIGEST_FUNCTION type defines a pointer to this callback function. DigestFunction is a placeholder for the application-defined function name.


BOOL DigestFunction(
  _In_ DIGEST_HANDLE refdata,
  _In_ PBYTE         pData,
  _In_ DWORD         dwLength


refdata [in]

A user-supplied handle to the digest. This value is passed as a parameter to the ImageGetDigestStream function.

pData [in]

The data stream.

dwLength [in]

The size of the data stream, in bytes.

Return value

If the function succeeds, the return value should be TRUE. If the function fails, the return value should be FALSE.


All ImageHlp functions, such as this one, are single threaded. Therefore, calls from more than one thread to this function will likely result in unexpected behavior or memory corruption. To avoid this, you must synchronize all concurrent calls from more than one thread to this function.


Minimum supported client

Windows XP [desktop apps only]

Minimum supported server

Windows Server 2003 [desktop apps only]



See also

ImageHlp Functions