Microsoft.Protocols.TestTools.StackSdk.RemoteDesktop.Rdpbcgr.RdpbcgrServerDecoder.DecodeMcsChannelJoinRequestPDU C# (CSharp) Method

DecodeMcsChannelJoinRequestPDU() public method

Decode MCS Channel Join Request PDU
public DecodeMcsChannelJoinRequestPDU ( byte data ) : Microsoft.Protocols.TestTools.StackSdk.StackPacket
data byte data to be parsed
return Microsoft.Protocols.TestTools.StackSdk.StackPacket
        public StackPacket DecodeMcsChannelJoinRequestPDU(byte[] data)
        {
            // initialize
            int currentIndex = 0;
            Client_MCS_Channel_Join_Request pdu = new Client_MCS_Channel_Join_Request();

            // McsChannelJoinConfirm: TpktHeader
            pdu.tpktHeader = ParseTpktHeader(data, ref currentIndex);

            // McsChannelJoinConfirm: x224Data
            pdu.x224Data = ParseX224Data(data, ref currentIndex);

            // McsChannelJoinConfirm: channelJoinConfirm
            ChannelJoinRequest channelJoinReq = (ChannelJoinRequest)ParseMcsDomainPdu(data, ref currentIndex).GetData();
            pdu.userChannelId = (long)channelJoinReq.initiator.Value;
            pdu.mcsChannelId = (long)channelJoinReq.channelId.Value;

            // Check if data length exceeded expectation
            VerifyDataLength(data.Length, currentIndex, ConstValue.ERROR_MESSAGE_DATA_LENGTH_EXCEEDED);
            return pdu;
        }
RdpbcgrServerDecoder