2.2.1 Shared Message Header (SHARED_MSG_HEADER)
Every packet in this extension contains a common header.<1>
|
|
|
|
|
|
|
|
|
|
1 |
|
|
|
|
|
|
|
|
|
2 |
|
|
|
|
|
|
|
|
|
3 |
|
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
InterfaceId |
Mask |
||||||||||||||||||||||||||||||
MessageId |
|||||||||||||||||||||||||||||||
FunctionId (optional) |
|||||||||||||||||||||||||||||||
messagePayload (variable) |
|||||||||||||||||||||||||||||||
... |
InterfaceId (30 bits): A 30-bit field that represents the common identifier for the interface. Some interfaces have predefined default IDs. If the message uses a default interface ID, the message is interpreted for the associated interface. All other values MUST be retrieved either from a Query Interface response (QI_RSP) ([MS-RDPEXPS] section 2.2.2.1.2) or from responses that contain interface IDs. The highest two bits of the NetInterfaceId field in a QI_RSP message MUST be ignored.
-
This interface ID is valid until it is sent or received in an Interface Release (IFACE_RELEASE) message ([MS-RDPEXPS] section 2.2.2.2). After an IFACE_RELEASE message is processed, the ID is considered invalid.
Mask (2 bits): The 2 bits of the Mask field MUST be set to one of the following values.
-
Value
Meaning
STREAM_ID_STUB
0x2
Indicates that the SHARED_MSG_HEADER is being used in a response message.
STREAM_ID_PROXY
0x1
Indicates that the SHARED_MSG_HEADER is not being used in a response message.
STREAM_ID_NONE
0x0
Indicates that the SHARED_MSG_HEADER is being used for interface manipulation capabilities exchange as specified in section 2.2.3. This value MUST NOT be used for any other messages.
MessageId (4 bytes): A 32-bit unsigned integer. A unique ID for the request or response pair. Requests and responses are matched based on this ID coupled with the InterfaceId.
FunctionId (4 bytes): A 32-bit unsigned integer. This field MUST be present in all packets except response packets. Its value is either used in interface manipulation messages or defined for a specific interface. The following values are categorized by the interface for which they are defined.
-
Common IDs for all interfaces are as follows.
-
Value
Meaning
RIMCALL_RELEASE
0x00000001
Release the given interface ID.
RIMCALL_QUERYINTERFACE
0x00000002
Query for a new interface.
-
Capabilities Negotiator Interface IDs are as follows.
-
Value
Meaning
RIM_EXCHANGE_CAPABILITY_REQUEST
0x00000100
The server sends the Interface Manipulation Exchange Capabilities Request message.
-
Client Request Completion Interface IDs are as follows.
-
Value
Meaning
IOCONTROL_COMPLETION
0x00000100
The client sends the IO Control Completion message.
URB_COMPLETION
0x00000101
The client sends the URB Completion message.
URB_COMPLETION_NO_DATA
0x00000102
The client sends the URB Completion No Data message.
-
Server USB Device Interface IDs are as follows.
-
Value
Meaning
CANCEL_REQUEST
0x00000100
The server sends the Cancel Request message.
REGISTER_REQUEST_CALLBACK
0x00000101
The server sends the Register Request Callback message.
IO_CONTROL
0x00000102
The server sends the IO Control message.
INTERNAL_IO_CONTROL
0x00000103
The server sends the Internal IO Control message.
QUERY_DEVICE_TEXT
0x00000104
The server sends the Query Device Text message.
TRANSFER_IN_REQUEST
0x00000105
The server sends the Transfer In Request message.
TRANSFER_OUT_REQUEST
0x00000106
The server sends the Transfer Out Request message.
RETRACT_DEVICE
0x00000107
The server sends the Retract Device message.
-
Client Device Sink Interface IDs are as follows.
-
Value
Meaning
ADD_VIRTUAL_CHANNEL
0x00000100
The client sends the Add Virtual Channel message.
ADD_DEVICE
0x00000101
The client sends the Add Device message.
-
Channel Notification Interface IDs are as follows.
-
Value
Meaning
CHANNEL_CREATED
0x00000100
The server and the client send the Channel Created message.
messagePayload (variable): An array of unsigned 8-bit integers. The remainder of the message is interpreted based on the interface for which the packet is sent. This field is optional based on the packet length.