[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH] add VNC reverse connections
From: |
Eddie Kohler |
Subject: |
Re: [Qemu-devel] [PATCH] add VNC reverse connections |
Date: |
Wed, 16 Jan 2008 16:51:37 -0800 |
User-agent: |
Thunderbird 2.0.0.9 (Macintosh/20071031) |
Anthony Liguori wrote:
This doesn't feel like an option to me, though; rather a different
means of connecting. Among other things, in "-vnc :0", the QEMU VNC
server opens port 5900. But the client's listening port for reverse
connections defaults to 5500. "-vnc :-400,rev" is clearly insane,
but it seems strange for an option like ",rev" to change the meaning
of the port field.
Yes that is a valid point. It is a little unfortunate we switched to
using
display num instead of port num for the current VNC code. Having a syntax
which makes people use negative display nums for reverse connections
would
suck. So reluctantly I think your original proposal may actually be
better.
Yet this is the syntax we use for normal connections. I don't see why
the asymmetry is okay for reverse connections.
Because reverse connections feel very different from normal connections, use
ports instead of "display numbers", etc.?
Here's what the manual would look like for the "rev:" syntax.
interface:d
TCP connections will only be allowed from interface on display d. By convention
the TCP port is 5900+d. Optionally, interface can be omitted in which case the
server will bind to all interfaces.
...
rev:[address:]port
Connects to a VNC client listening at address:port. Optionally, address can be
omitted in which case the server connects to localhost:port.
Here's what the manual would look like for the ",reverse" syntax.
Valid syntax for the display is
interface:d
TCP connections will only be allowed from interface on display d. By convention
the TCP port is 5900+d. Optionally, interface can be omitted in which case the
server will bind to all interfaces.
...
reverse
QEMU will connect to a listening VNC client, rather than waiting for a client
connection. If the connection has type "interface:d", then "interface" is the
client address; if omitted, localhost is used. The display number "d" is added
to 5900 to determine the port, so negative numbers might be necessary to
connect to default client ports.
Or are you thinking
For reverse connections, the display number "d" is added to 5500 to determine
the port.
in which case the interface:d definition is incorrect?
I'm not trying to make this look ugly on purpose. The prefix syntax seems
friendlier.
Eddie