2.2.1 Shared Message Header (SHARED_MSG_HEADER)

Every packet in this extension contains a common header.<1>


0


1


2


3


4


5


6


7


8


9

1
0


1


2


3


4


5


6


7


8


9

2
0


1


2


3


4


5


6


7


8


9

3
0


1

InterfaceId

MessageId

FunctionId

messagePayload (variable)

...

InterfaceId (4 bytes): The InterfaceId field is broken out as follows:


0


1


2


3


4


5


6


7


8


9

1
0


1


2


3


4


5


6


7


8


9

2
0


1


2


3


4


5


6


7


8


9

3
0


1

InterfaceValue

Mask

InterfaceValue (30 bits): A 30-bit unsigned integer that represents the common identifier for the interface. The default value is 0x00000000. If the message uses this default interface ID, the message is interpreted for the main interface for which this channel has been instantiated. All other values MUST be retrieved either from an Interface Query response (QI_RSP), [MS-RDPEXPS] section2.2.2.1.2, or from responses that contain interface IDs.

This ID is valid until an interface release (IFACE_RELEASE) message ([MS-RDPEXPS] section 2.2.2.2) is sent or received with that ID. After an IFACE_RELEASE message is processed, this ID is considered invalid.

Mask (2 bits): These two bits in the SHARED_MSG_HEADER header MUST be set to one of the following values.

Value

Meaning

STREAM_ID_STUB

0x80000000

Indicates that the SHARED_MSG_HEADER is being used in a response message.

STREAM_ID_PROXY

0x40000000

Indicates that the SHARED_MSG_HEADER is not being used in a response message.

STREAM_ID_NONE

0x00000000

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 that represents 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.

The Capabilities Negotiator Interface ID is as follows.

Value

Meaning

RIM_EXCHANGE_CAPABILITY_REQUEST

0x00000100

The server sends the Interface Manipulation Exchange Capabilities Request message.

The Client Notifications Interface IDs are as follows.

Value

Meaning

PLAYBACK_ACK

0x00000100

The client sends the Playback Acknowledgment message.

CLIENT_EVENT_NOTIFICATION

0x00000101

The client sends the Client Event Notification message.

Server Data Interface IDs are as follows.

Value

Meaning

EXCHANGE_CAPABILITIES_REQ

0x00000100

The server sends the Exchange Capabilities Request message.

SET_CHANNEL_PARAMS

0x00000101

The server sends the Set Channel Parameters message.

ADD_STREAM

0x00000102

The server sends the Add Stream message.

ON_SAMPLE

0x00000103

The server sends the On Sample message.

SET_VIDEO_WINDOW

0x00000104

The server sends the Set Video Window message.

ON_NEW_PRESENTATION

0x00000105

The server sends the New Presentation message.

SHUTDOWN_PRESENTATION REQ

0x00000106

The server sends the Shut Down Presentation Request message.

SET_TOPOLOGY_REQ

0x00000107

The server sends the Set Topology Request message.

CHECK_FORMAT_SUPPORT_REQ

0x00000108

The server sends the Check Format Support Request message.

ON_PLAYBACK_STARTED

0x00000109

The server sends the On Playback Started message.

ON_PLAYBACK_PAUSED

0x0000010a

The server sends the On Playback Paused message.

ON_PLAYBACK_STOPPED

0x0000010b

The server sends the On Playback Stopped message.

ON_PLAYBACK_RESTARTED

0x0000010c

The server sends the On Playback Restarted message.

ON_PLAYBACK_RATE_CHANGED

0x0000010d

The server sends the On Playback Rate Change message.

ON_FLUSH

0x0000010e

The server sends the On Flush message.

ON_STREAM_VOLUME

0x0000010f

The server sends the On Stream Volume message.

ON_CHANNEL_VOLUME

0x00000110

The server sends the On Channel Volume message.

ON_END_OF_STREAM

0x00000111

The server sends the On End of Stream message.

SET_ALLOCATOR

0x00000112

The server sends the Set Allocator Properties message.

NOTIFY_PREROLL

0x00000113

The server sends the Notify Preroll message.

UPDATE_GEOMETRY_INFO

0x00000114

The server sends the Update Geometry Information message.

REMOVE_STREAM

0x00000115

The server sends the Remove Stream message.

SET_SOURCE_VIDEO_RECT

0x00000116

The server sends the Set Source Video Rectangle message.

messagePayload (variable): An array of unsigned 8-bit integers describing the payload of the message corresponding to the interface for which the packet is sent. The specific structure of the payload is described by the message descriptions in sections 2.2.3, 2.2.4, and 2.2.5.