I'm trying to use the function AddCertificateHashEntry (part of the PTHICommand class defined in PTHICommand.cpp). I pass in the right parameters, but I never get a response buffer from HECI. I realize the ZtcLocalAgent sample as written never calls this function, so could this be a SDK bug? Also, is this API function similar to the same named function defined in the network interface? If so, certain parts of the structure are missing from the command buffer (e.g. hashtypetype) and the ordering seems different.
Specifically, what happens is the command gets sent and bytesWritten is correct. Then, when I step through HECIWin::ReceiveMessage the ReadFile call gets a response of 1 but bytesRead is 0 for this command. It's is silently failing without any error code from the HECI. If I call ReadFile a second time by modifying the code, ReadFile returns 0 and GetLastError is 997, overlapped I/O in progress. Then GetOverlappedResult just hangs forever waiting for it.
So, I think the driver is writing a zero sized response to the command, since the first ReadFile works and returns immediately with no data. API bug?