How start vncserver for a no-root user whem i m logged on root account ?

Corné Beerse cbeerse "at" lycos.nl
Thu Apr 8 16:10:01 2004


William Hooper wrote:

> Eternal Security said:
> 
> 
>>But if i want to start vncserver on a port < 1024 (with the -httpport
>>option) i can't do it because only the root user can bind port < 1024.

What do you want to do on port < 1024?

If it is for http, then be noted it only serves a html page with a jave viewer.

This java viewer also uses the same port as the binary vncviewer for your 
desktop: the rfb-port. Those ports cannot be combined.

You can also use any other webserver to serve the html page and the java viewer. 
You'll find them in the .../vnc/classes/. directory: the *.vnc files are 
pre-cooked html files with some variables that are filled by the Xvnc-webserver.


>>
>>How is it possible to start vncserver for a particular user in using the
>>root account ?

The best way is like on http://www.sourcecodecorner.com/articles/vnc/linux.asp . 
It provides vnc just as on the console, including login box.

> 
> 
> No, because if you start vncserver as a user you are no longer root, so
> you can't bind to those ports.  Programs that do this include special code
> to bind the port as root then pass control to a non-root account.  VNC
> includes no such code.