I have looked into this more today.
This is what I think is the best way to access your desktop from any browser on any OS without risk of giving people access.
first part is to use apache web server
here is the Virtual Host section of the httpd.conf
<VirtualHost *>
ServerAdmin
admin@domain.com
DocumentRoot /var/www/unsecure/vnc
ServerName vnc.domain.com
ErrorLog logs/dcp-error_log
CustomLog logs/dcp-access_log common
</VirtualHost>
note the folder in this Virtual Host is /var/www/unsecure/vnc
the index.php file there contains the following
<?php
header("Location:
https://vnc.domain.com");
exit();
?>
now this will redirect any connection by http to https which will secure the connection before login. Also all data is secure.
Here is the secure Virtual Host section of httpd.conf
<VirtualHost *:443>
Port 443
DocumentRoot "/usr/share/vnc/classes"
ServerName vnc.domain.com
ServerAdmin
admin@domain.com
ErrorLog logs/vnc_ssl-error_log
TransferLog logs/vnc_ssl-access_log
SSLEngine on
SSLCipherSuite ALL:!ADH:!EXPORT56:RC4+RSA:+HIGH:+MEDIUM:+LOW:+SSLv2:+EXP:+eNULL
SSLCertificateFile /etc/httpd/conf/ssl.crt/server.crt
SSLCertificateKeyFile /etc/httpd/conf/ssl.key/server.key
<Files ~ "\.(cgi|shtml|phtml|php3?)$">
SSLOptions +StdEnvVars
</Files>
<Directory "/var/www/cgi-bin">
SSLOptions +StdEnvVars
</Directory>
SetEnvIf User-Agent ".*MSIE.*" \
nokeepalive ssl-unclean-shutdown \
downgrade-1.0 force-response-1.0
CustomLog logs/ssl_request_log \
"%t %h %{SSL_PROTOCOL}x %{SSL_CIPHER}x \"%r\" %b"
</VirtualHost>
ok, this puts a browser connection to vnc.domain.com in the folder /usr/share/vnc/classes
now in that folder you need an index.html
example index.html
<HTML>
<TITLE>
VNC Desktop
</TITLE>
<APPLET CODE=vncviewer.class ARCHIVE=vncviewer.jar
WIDTH=800 HEIGHT=600>
<param name=PORT value=5902>
</APPLET>
</HTML>
The port here is an example of what you need if the vncserver is on vnc.domain.com:2
If you want more security to access the folder use something like this
<Directory /usr/share/vnc/classes>
Options +Indexes
AuthType Basic
AuthName vncUser
AuthUserFile /var/www/access/vnc/.htpasswd
EnableDelete Off
umask 007
require valid-user
</Directory>
If you want to get fancy with this I guess you could have a page where you login and it lets you start vncserver then connects you to the port it's on.
This is just the basics.