none
[MS-RDPEDYC] DVC Create/Close Sequence RRS feed

  • Question

  • Hi,

    I wanted to clarify part of [MS-RDPEDYC] for some time. When the server sends a DYNVC_CREATE_REQ to FreeRDP for an unsupported channel, FreeRDP sends back a DYNVC_CREATE_RSP with a status code of value -1. The spec says that any negative value should be considered as failure:

    "CreationStatus (4 bytes): A 32-bit, signed integer that specifies the HRESULT code that indicates success or failure of the client DVC creation. HRESULT codes are specified in [MS-ERREF] section 2.1. A zero or positive value indicates success; a negative value indicates failure."

    The part which is not so clear is the lifetime of the channel id. With Windows 8, the server sends an explicit DYNVC_CLOSE message for the channels that failed to be created. However, I cannot find a place that clearly explains if a context should remain associated with the given channel id when channel creation fails. In practice, the behavior is different between Windows 8 and Windows 8.1.

    Windows 8: the server automatically sends a DYNVC_CLOSE for each channel id that failed to be created. In order to know validate if we're closing a pre-existing channel, this would imply that a list of channel ids, even those that failed to be created, is maintained.

    Windows 8.1: the server does *not* send a DYNVC_CLOSE for channels that failed to be created. If we maintain a list of those channel ids, they will not be explicitly deleted anytime soon. It is hard to validate properly the expected state for a given channel id given that unlike Windows 8, it does not explicitly close the channels.

    The current implementation assumes that channels that failed to be created never existed, and therefore aren't added to the active channel id list. However, this causes issues with Windows 8 / 2012 as we receive close requests for channels that do not exist, and we print out warnings as a result.

    What is the expected behavior, and what should really be done on the client side? Is there a way to make the distinction between the two types of behaviors?

    Best regards,

    -Marc-Andre

    Monday, June 29, 2015 6:29 PM

All replies

  • Hello Marc,
    Thank you for your inquiry about RDP protocols. I will be researching this issue and will provide you with an update soon.


    Regards,
    Sreekanth Nadendla
    Microsoft Windows Open Specifications
    Monday, June 29, 2015 8:53 PM
    Moderator
  • Hello Marc,
    When a channel creation fails, the server manager may or may not send DYNVC_CLOSE for this channel. The client manager MUST be able to handle both cases. The server manager could immediately reuse the failed channel ID for creating another channel with or without first sending a DYNVC_CLOSE.

     
    To handle this behavior, the client manager SHOULD NOT add a channel into the list of active channel ids unless the channel creation was successful. The client manager SHOULD ignore any DYNVC_CLOSE received for a channel which is not in the list of active channel ids, and SHOULD NOT respond with a DYNVC_CLOSE.

    Regards,
    Sreekanth Nadendla
    Microsoft Windows Open Specifications
    Tuesday, July 28, 2015 6:58 PM
    Moderator