Stream tubes, a new generation of tubes

A few weeks ago Daf and Rob announced D-Bus tube, a new Telepathy technology allowing applications to use D-Bus facilities for their network communications.

We have now a new type of tube called Stream Tube. With these tubes you'll be able to easily establish TCP connections with your contacts or with the participants of a multi-users chatroom. Let's take a look on Daf's amazing ASCII art to see how that works.

 .---------.
 |TP client|--|listening socket| B
 '---------'         ^
     C               |
                .----------.
                |Connection|
                | Manager  | A
                '----------'
                     |
                   _____
                __/     \___
            ___/            \n           /                 \____
          |                       \n          \__                     /
             \    Internets      /
             /                   \n            /                     \n           |             ___      /
           \____/\      /   \____/
                  \____/
                     ^
                     |
                .----------.
                |Connection|
             F  | Manager  |-|listening socket| E
                '----------'        ^
                                    |
                               .---------.
                               |TP client| D
                               '---------'

Alice wants to share a, say, local Unix socket (B) with Fernand. She exports that socket in a stream tube and offers it to Fernand. He accepts it and so its Connection Manager creates a local socket (E) on his system. Now, each time Fernand will connect an application (D) to this new socket, Alice's CM will make a new connection to the socket B and a new bytestream will be established between Alice and Fernand to transport data of this connection. So, applications C and D can now communicate together without caring about the network between them and without any code modifications, they just have to support unix socket (more socket type will be supported soon).

So, now imagine C is, for example, a VNC server and D a VNC client and we have... VNC over jabber!

RealVNC doesn't support Unix socket yet, but this patch add this feature. Thanks to the help of its author, I was able to build it with RealVNC 4.1 and so play with a remote GNOME mine. :)

mine-tube.jpg

GNOME mine over VNC over stream tubes over jabber

Currently only local unix socket support is implemented but we should support other socket type soon. We're still using XML bytestream (IBB) but real P2P bytestreams (with NAT penetration support) are planned too.