none
Can I establish a handshake by just using InitializeSecurityContext? RRS feed

  • Question

  • For example, I send a Client Hello message with InitializeSecurityContext() and receive an output buffer, can I send this buffer back to the server by just again calling InitializeSecurityContext()?

    Or do I have to send it using the winsock.send() method, and then use winsock.recv() method to receive the token and THEN call InitializeSecurityContext()?

    Wednesday, November 20, 2019 3:21 PM

All replies

  • Hi KSSEM,

    The general flow is :

    1.InitializeSecurityContext - first call return a pointer to a SecBufferDesc structure.
    2.Call to send(WinSock API) function with the output buffers.
    3.Call to recv function
    4.Call to InitializeSecurityContext again with the buffers.


    Best regards,

    Jeffrey


    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.



    • Edited by Jeffrey Shao Thursday, November 21, 2019 2:53 AM
    • Proposed as answer by Jeffrey Shao Friday, November 29, 2019 7:05 AM
    Thursday, November 21, 2019 2:35 AM