xpra icon
Bug tracker and wiki

Version 8 (modified by Antoine Martin, 6 years ago) (diff)

--

Network Protocol

This page documents the types of messages that the client and server can exchange. For the actual network connection see wiki/Network and for the encoding and compression of the messages see wiki/PacketEncoding. The most important packet is the first one sent, the hello packet, since it contains "capabilities" which determines what packets and features are supported by the other end.

  • General packets that flow in both directions:
Packet Type Arguments Purpose Actions Required
hello
a dictionary containing connection options and capabilitiesauthentication (if required), setup of keyboard, configuration options, etceither accept the connection and send a hello back as acknowledgement, send a challenge request or disconnect
pingtime to be echoed backmonitor connection state, collect latency statisticsThe receiver must send a ping-echo back
ping-echoechoed time, load average, measured latencyresponse to pingnone, it should be used to collect latency statistics
sound-datasound buffers and associated metadataforward sound datathe receiver should queue the sound buffer, it may drop them if desired - if so, it should tell the other end to stop sending
connection-lostnonesent by the network layer when the network connection has droppedfree any resources
gibberishnonesent by the network layer when the network received unparseable data, data decompression failed or decryption faileddisconnect the connection and free any resources
  • Packets sent by the server
Packet Type Arguments Purpose Actions Required Client Capability Required
startup-completenonenotifies the client that all the windows have been sentnonenotify-startup-complete
new-window and new-override-redirectmanytells the client about a new regular window or override-redirect windowthe client should show the new window, it should eventually send a map-window packet with the location of the windownone
new-traymanytells the client about a new tray windowthe client should show the new system traysystem_tray
raise-windowwindow IDthe window should be raisedthe client may or may not honour the request to raise the windowwindow.raise
window-move-resizewindow ID, new position and sizehonour applications that request the window to be moved and resizedthe client should move and resize the windowserver-window-move-resize
window-resizedwindow ID and new sizethe client should move and resize the windowserver-window-resize