1Xvnc(1)                    Virtual Network Computing                   Xvnc(1)
2
3
4

NAME

6       Xvnc - the X VNC server
7

SYNOPSIS

9       Xvnc [options] :display#
10

DESCRIPTION

12       Xvnc is the X VNC (Virtual Network Computing) server.  It is based on a
13       standard X server, but it has a "virtual" screen rather than a physical
14       one.   X applications display themselves on it as if it were a normal X
15       display, but they  can  only  be  accessed  via  a  VNC  viewer  -  see
16       vncviewer(1).
17
18       So  Xvnc  is  really two servers in one. To the applications it is an X
19       server, and to the remote VNC users it is a VNC server.  By  convention
20       we have arranged that the VNC server display number will be the same as
21       the X server display number, which means you can use  eg.  snoopy:2  to
22       refer  to display 2 on machine "snoopy" in both the X world and the VNC
23       world.
24
25       The best way of starting Xvnc is via the vncserver script.   This  sets
26       up  the  environment  appropriately and runs some X applications to get
27       you going.  See the manual page for vncserver(1) for more information.
28
29

OPTIONS

31       Xvnc takes lots of options - running Xvnc -help gives a list.  Many  of
32       these  are  standard  X  server  options,  which  are  described in the
33       Xserver(1) manual page.  In addition to options which can only  be  set
34       via the command-line, there are also "parameters" which can be set both
35       via the command-line and through the vncconfig(1) program.
36
37
38       -geometry widthxheight
39              Specify the size of  the  desktop  to  be  created.  Default  is
40              1024x768.
41
42       -depth depth
43              Specify  the  pixel  depth in bits of the desktop to be created.
44              Default is 24, other possible values are 8, 15, and  16  -  any‐
45              thing else is likely to cause strange behaviour by applications.
46
47       -pixelformat format
48              Specify  pixel format for server to use (BGRnnn or RGBnnn).  The
49              default for depth 8 is BGR233 (meaning the most significant  two
50              bits represent blue, the next three green, and the least signif‐
51              icant three represent red), the default for depth 16  is  RGB565
52              and for depth 24 is RGB888.
53
54       -interface IP address
55              Listen  on  interface.  By default Xvnc listens on all available
56              interfaces.
57
58       -inetd This significantly changes Xvnc's behaviour so that  it  can  be
59              launched from inetd.  See the section below on usage with inetd.
60
61       -help  List all the options and parameters
62
63

PARAMETERS

65       VNC  parameters  can  be  set both via the command-line and through the
66       vncconfig(1) program, and with a VNC-enabled Xorg  server  via  Options
67       entries in the xorg.conf file.
68
69       Parameters  can be turned on with -param or off with -param=0.  Parame‐
70       ters which take a value can be specified as -param value.  Other  valid
71       forms  are param=value -param=value --param=value.  Parameter names are
72       case-insensitive.
73
74
75       -desktop desktop-name
76              Each desktop has a name which may be displayed by the viewer. It
77              defaults to "x11".
78
79       -rfbport port
80              Specifies  the  TCP  port  on which Xvnc listens for connections
81              from viewers (the protocol used in VNC is called RFB  -  "remote
82              framebuffer").  The default is 5900 plus the display number.
83
84       -UseIPv4
85              Use IPv4 for incoming and outgoing connections. Default is on.
86
87       -UseIPv6
88              Use IPv6 for incoming and outgoing connections. Default is on.
89
90       -rfbunixpath path
91              Specifies the path of a Unix domain socket on which Xvnc listens
92              for connections from viewers, instead  of  listening  on  a  TCP
93              port.
94
95       -rfbunixmode mode
96              Specifies  the  mode  of the Unix domain socket.  The default is
97              0600.
98
99       -rfbwait time, -ClientWaitTimeMillis time
100              Time in milliseconds to wait for a viewer which is blocking  the
101              server.  This is necessary because the server is single-threaded
102              and sometimes blocks until the viewer has  finished  sending  or
103              receiving  a  message  -  note that this does not mean an update
104              will be aborted after this time.  Default is 20000 (20 seconds).
105
106       -httpd directory
107              Run a mini-HTTP server which serves files from the given  direc‐
108              tory.   Normally  the directory will contain the classes for the
109              Java viewer.  In addition, files with a .vnc extension will have
110              certain  substitutions made so that a single installation of the
111              Java VNC viewer can be served by separate instances of Xvnc.
112
113       -httpPort port
114              Specifies the port on which the mini-HTTP server runs.   Default
115              is 5800 plus the display number.
116
117       -rfbauth passwd-file, -PasswordFile passwd-file
118              Password  file for VNC authentication.  There is no default, you
119              should specify the  password  file  explicitly.   Password  file
120              should  be  created  with the vncpasswd(1) utility.  The file is
121              accessed each time a connection comes in, so it can  be  changed
122              on the fly.
123
124       -AcceptCutText
125              Accept clipboard updates from clients. Default is on.
126
127       -MaxCutText bytes
128              The  maximum  size  of  a clipboard update that will be accepted
129              from a client.  Default is 262144.
130
131       -SendCutText
132              Send clipboard changes to clients. Default is on.
133
134       -SendPrimary
135              Send the primary selection and cut buffer to the server as  well
136              as the clipboard selection. Default is on.
137
138       -AcceptPointerEvents
139              Accept pointer press and release events from clients. Default is
140              on.
141
142       -AcceptKeyEvents
143              Accept key press and release events from clients. Default is on.
144
145       -AcceptSetDesktopSize
146              Accept requests to resize the size of the  desktop.  Default  is
147              on.
148
149       -DisconnectClients
150              Disconnect  existing  clients  if an incoming connection is non-
151              shared. Default is on. If DisconnectClients is false, then a new
152              non-shared  connection  will  be refused while there is a client
153              active.  When combined with  NeverShared  this  means  only  one
154              client is allowed at a time.
155
156       -NeverShared
157              Never  treat  incoming  connections as shared, regardless of the
158              client-specified setting. Default is off.
159
160       -AlwaysShared
161              Always treat incoming connections as shared, regardless  of  the
162              client-specified setting. Default is off.
163
164       -Protocol3.3
165              Always use protocol version 3.3 for backwards compatibility with
166              badly-behaved clients. Default is off.
167
168       -FrameRate fps
169              The maximum number of updates per second sent to each client. If
170              the  screen updates any faster then those changes will be aggre‐
171              gated and sent in a single update to the client. Note that  this
172              only controls the maximum rate and a client may get a lower rate
173              when resources are limited. Default is 60.
174
175       -CompareFB mode
176              Perform pixel comparison on framebuffer  to  reduce  unnecessary
177              updates.  Can be either 0 (off), 1 (always) or 2 (auto). Default
178              is 2.
179
180       -ZlibLevel level
181              Zlib compression level for ZRLE encoding  (it  does  not  affect
182              Tight  encoding).   Acceptable  values  are  between  0  and  9.
183              Default is to use the standard compression level provided by the
184              zlib(3) compression library.
185
186       -ImprovedHextile
187              Use  improved  compression  algorithm for Hextile encoding which
188              achieves better compression ratios by the cost of using slightly
189              more CPU time.  Default is on.
190
191       -SecurityTypes sec-types
192              Specify  which  security scheme to use for incoming connections.
193              Valid values are a comma separated list of None, VncAuth, Plain,
194              TLSNone,  TLSVnc,  TLSPlain,  X509None,  X509Vnc  and X509Plain.
195              Default is VncAuth,TLSVnc.
196
197       -Password password
198              Obfuscated binary encoding of the password  which  clients  must
199              supply  to access the server.  Using this parameter is insecure,
200              use PasswordFile parameter instead.
201
202       -PlainUsers user-list
203              A comma separated list of user names that are allowed to authen‐
204              ticate  via  any of the "Plain" security types (Plain, TLSPlain,
205              etc.). Specify * to allow any user to  authenticate  using  this
206              security type. Default is to deny all users.
207
208       -pam_service name, -PAMService name
209              PAM  service  name to use when authentication users using any of
210              the "Plain" security types. Default is vnc.
211
212       -X509Cert path
213              Path to a X509 certificate in PEM format to be used for all X509
214              based security types (X509None, X509Vnc, etc.).
215
216       -X509Key path
217              Private  key  counter part to the certificate given in X509Cert.
218              Must also be in PEM format.
219
220       -GnuTLSPriority priority
221              GnuTLS priority string that controls the TLS session’s handshake
222              algorithms.   See the GnuTLS manual for possible values. Default
223              is NORMAL.
224
225       -BlacklistThreshold count
226              The number of unauthenticated connection attempts  allowed  from
227              any  individual  host before that host is black-listed.  Default
228              is 5.
229
230       -BlacklistTimeout seconds
231              The initial timeout applied when a host is  first  black-listed.
232              The  host  cannot  re-attempt  a  connection  until  the timeout
233              expires.  Default is 10.
234
235       -IdleTimeout seconds
236              The number of seconds after which an idle VNC connection will be
237              dropped.   Default  is 0, which means that idle connections will
238              never be dropped.
239
240       -MaxDisconnectionTime seconds
241              Terminate when no client  has  been  connected  for  N  seconds.
242              Default is 0.
243
244       -MaxConnectionTime seconds
245              Terminate  when  a  client  has  been  connected  for N seconds.
246              Default is 0.
247
248       -MaxIdleTime seconds
249              Terminate after N seconds of user inactivity.  Default is 0.
250
251       -QueryConnect
252              Prompts the user of the desktop to explicitly accept  or  reject
253              incoming connections. Default is off.
254
255              The vncconfig(1) program must be running on the desktop in order
256              for QueryConnect to be supported.
257
258       -QueryConnectTimeout seconds
259              Number of seconds to show the Accept  Connection  dialog  before
260              rejecting the connection.  Default is 10.
261
262       -localhost
263              Only  allow connections from the same machine. Useful if you use
264              SSH and want to stop non-SSH connections from any other hosts.
265
266       -Log logname:dest:level
267              Configures the  debug  log  settings.   dest  can  currently  be
268              stderr,  stdout  or  syslog, and level is between 0 and 100, 100
269              meaning most verbose output.  logname is usually * meaning  all,
270              but  you  can target a specific source file if you know the name
271              of its "LogWriter".  Default is *:stderr:30.
272
273       -RemapKeys mapping
274              Sets up a keyboard mapping.  mapping is a comma-separated string
275              of   character   mappings,  each  of  the  form  char->char,  or
276              char<>char, where char is a hexadecimal keysym. For example,  to
277              exchange the " and @ symbols you would specify the following:
278
279                 RemapKeys=0x22<>0x40
280
281       -AvoidShiftNumLock
282              Key  affected  by  NumLock  often  require  a  fake  Shift to be
283              inserted in order for the correct symbol to be generated.  Turn‐
284              ing  on this option avoids these extra fake Shift events but may
285              result in a slightly different symbol (e.g. a Return instead  of
286              a keypad Enter).
287
288       -RawKeyboard
289              Send  keyboard events straight through and avoid mapping them to
290              the current keyboard layout. This effectively makes the keyboard
291              behave  according to the layout configured on the server instead
292              of the layout configured on the client. Default is off.
293
294       -AllowOverride
295              Comma separated list of parameters that can  be  modified  using
296              VNC  extension.   Parameters  can  be modified for example using
297              vncconfig(1) program from inside a running session.
298
299              Allowing override of parameters such as PAMService or  Password‐
300              File can negatively impact security if Xvnc runs under different
301              user than the programs allowed to override the parameters.
302
303              When NoClipboard parameter is set, allowing override of SendCut‐
304              Text and AcceptCutText has no effect.
305
306              Default   is  desktop,AcceptPointerEvents,SendCutText,AcceptCut‐
307              Text,SendPrimary,SetPrimary.
308
309

USAGE WITH INETD

311       By configuring the inetd(1) service appropriately, Xvnc can be launched
312       on  demand when a connection comes in, rather than having to be started
313       manually.  When given the -inetd option, instead of listening  for  TCP
314       connections  on  a  given  port it uses its standard input and standard
315       output.  There are two modes controlled by the wait/nowait entry in the
316       inetd.conf file.
317
318       In the nowait mode, Xvnc uses its standard input and output directly as
319       the connection to a viewer.  It never has a listening socket, so cannot
320       accept  further connections from viewers (it can however connect out to
321       listening viewers by use of the  vncconfig  program).   Further  viewer
322       connections  to  the  same  TCP port result in inetd spawning off a new
323       Xvnc to deal with each connection.  When the connection to  the  viewer
324       dies,  the  Xvnc  and  any associated X clients die.  This behaviour is
325       most useful when combined with the XDMCP options -query and -once.   An
326       typical example in inetd.conf might be (all on one line):
327
328       5950    stream    tcp  nowait  nobody   /usr/local/bin/Xvnc Xvnc -inetd
329       -query localhost -once securitytypes=none
330
331       In this example a viewer connection to :50 will result in  a  new  Xvnc
332       for  that connection which should display the standard XDM login screen
333       on that machine.  Because the user needs to login via XDM, it  is  usu‐
334       ally OK to accept connections without a VNC password in this case.
335
336       In  the  wait mode, when the first connection comes in, inetd gives the
337       listening socket to Xvnc.  This means that for a given TCP port,  there
338       is  only  ever  one  Xvnc at a time.  Further viewer connections to the
339       same port are accepted by the same Xvnc in the normal way.   Even  when
340       the  original  connection is broken, the Xvnc will continue to run.  If
341       this is used with the XDMCP options -query  and  -once,  the  Xvnc  and
342       associated  X  clients will die when the user logs out of the X session
343       in the normal way.  It is important to use a VNC password in this case.
344       A typical entry in inetd.conf might be:
345
346       5951    stream    tcp  wait   james     /usr/local/bin/Xvnc Xvnc -inetd
347       -query localhost -once passwordFile=/home/james/.vnc/passwd
348
349       In fact typically, you would have one entry for each user who uses  VNC
350       regularly,  each  of  whom  has their own dedicated TCP port which they
351       use.  In this example, when user "james" connects to :51, he enters his
352       VNC  password,  then  gets the XDM login screen where he logs in in the
353       normal way.  However, unlike the previous example, if  he  disconnects,
354       the  session remains persistent, and when he reconnects he will get the
355       same session back again.  When he logs out of the X session,  the  Xvnc
356       will  die,  but  of  course a new one will be created automatically the
357       next time he connects.
358
359

SEE ALSO

361       vncconfig(1),  vncpasswd(1),  vncserver(1),  vncviewer(1),  Xserver(1),
362       inetd(1)
363       http://www.tigervnc.org
364
365

AUTHOR

367       Tristan Richardson, RealVNC Ltd. and others.
368
369       VNC  was  originally  developed  by  the RealVNC team while at Olivetti
370       Research Ltd / AT&T Laboratories Cambridge.   TightVNC  additions  were
371       implemented  by Constantin Kaplinsky. Many other people have since par‐
372       ticipated in development, testing and support. This manual is  part  of
373       the TigerVNC software suite.
374
375
376
377TigerVNC                                                               Xvnc(1)
Impressum