Re: Client server handshake and missing color maps
- From: "Daniel P. Berrange" <dan berrange com>
- To: Marco Gidde <Marco Gidde br-automation com>
- Cc: gtk-vnc-list gnome org
- Subject: Re: Client server handshake and missing color maps
- Date: Tue, 22 Apr 2014 21:56:39 +0100
On Tue, Apr 22, 2014 at 06:57:27PM +0200, Marco Gidde wrote:
Hello Daniel, hello list,
I noticed and analyzed a gtk-vnc crash, via vinagre on ubuntu 13.10 and
gvncviewer.py on an older SUSE release. The client tried to connect to
an older proprietary VNCserver running on a PLC, RFB version 3.3, maybe
some RealVNC derivative.
It turned out that the server uses 8bit color depth with a color map and
does not accept clients which request different color encodings or true
color. On the other hand the server does not send the color entries
unless the client explicitly sends the SetPixelFormat message.
There is some code/comment in src/vncdisplay.c:1182:
#if 0
/* TigerVNC always sends back the encoding even if
unchanged from what the server suggested. This
does not appear to matter, so lets save the bytes */
memcpy(&fmt, currentFormat, sizeof(fmt));
break;
#else
return TRUE;
#endif
If I activate that code, the client connects successfully, so there
might be a reason why TigerVNC always sends it :-)
It's not entirely clear whether the client is required to always send
SetPixelFormat - when using true color it is obviously superfluous. But
in this case its main purpose is to instruct the server to send the
color map. I couldn't find anything about this in the specification, but
I only skimmed through it.
All a little bizarre. It has been a long time since I looked at the
colourmap handling code. In fact I'm not entirely sure it ever worked
right, since basically no one uses colourmaps since the late 1990's :-)
Thanks for the bug report though - I'll try to refamiliarize myself
with this code and see if the change you suggest makes sense.
Daniel
--
|: http://berrange.com -o- http://www.flickr.com/photos/dberrange/ :|
|: http://libvirt.org -o- http://virt-manager.org :|
|: http://autobuild.org -o- http://search.cpan.org/~danberr/ :|
|: http://entangle-photo.org -o- http://live.gnome.org/gtk-vnc :|
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]