/// <summary> /// Inserts a 12-byte header into a Rendezvous proxy negotiation packet /// </summary> /// <param name="data">The byte buffer containing the packet</param> /// <param name="command">The <see cref="RendezvousProxyCommand"/> to send</param> /// <param name="index">The offset at which to insert the header</param> private void InsertProxyHeader(byte[] data, RendezvousProxyCommand command, ref int index) { Marshal.InsertUshort(data, (ushort)(data.Length - 2), ref index); Marshal.InsertUshort(data, 0x044A, ref index); Marshal.InsertUshort(data, (ushort)command, ref index); Marshal.InsertUint(data, 0x00000000, ref index); Marshal.InsertUshort(data, 0x0000, ref index); }
/// <summary> /// Inserts a 12-byte header into a Rendezvous proxy negotiation packet /// </summary> /// <param name="data">The byte buffer containing the packet</param> /// <param name="command">The <see cref="RendezvousProxyCommand"/> to send</param> /// <param name="index">The offset at which to insert the header</param> void InsertProxyHeader(byte[] data, RendezvousProxyCommand command, ref int index) { Marshal.InsertUshort(data, (ushort)(data.Length - 2), ref index); Marshal.InsertUshort(data, 0x044A, ref index); Marshal.InsertUshort(data, (ushort)command, ref index); Marshal.InsertUint(data, 0x00000000, ref index); Marshal.InsertUshort(data, 0x0000, ref index); }