VNC Java Client Setup for Remote Access

One of the requirements that we have is to be able to look at the status of a running test to verify the status.

The simplest way to do this is to point your browser at port 5800 on the host running the VNC Server - http://xxx.xxx.xxx.xxx:5800. By default TightVNC installs a Java client on every server host.

Follow the directions below if you want to reach different hosts from a single point of contact.

 Here are steps for doing this on Oracle Linux (I used Apache, but hopefully this should work with NodeJS eventually)-

  • Install Apache (sudo yum install httpd)
  • Modify the /etc/httpd/conf/httpd.conf and add the following section to it under 'Aliases' -

What is your first and last name?
  [Unknown]:  FName LName
What is the name of your organizational unit?
  [Unknown]:  MyGroup
What is the name of your organization?
  [Unknown]:  Some Company
What is the name of your City or Locality?
  [Unknown]:  New York
What is the name of your State or Province?
  [Unknown]:  New York
What is the two-letter country code for this unit?
  [Unknown]:  US
Is CN=FName LName, OU= MyGroup, O=Some Company, L=New York, ST=New York, C=US correct?
  [no]:  yes

Enter key password for
  (RETURN if same as keystore password): 
  • Export the certificate you just created (keytool -export vnckey -file vnckey.crt)
  • Sign the VNC jar file using the key you just created (jarsigner /var/www/vnc/VncViewer.jar vnckey)
  • Your certificate is valid for 6 months and you will need to re-sign the applet again in 6 months (unless you sign it with an authoritative key)
  • Create your HTML page for the applet -

  • The full list of available parameters is in the README - http://www.tightvnc.com/doc/java/README.txt
  • A few things to be aware of -
    • Unsigned Java applets are sandboxed and cannot make remote connections. They can only connect to localhost. If you see "Error: access denied (java.net.SocketPermission", the applet is unsigned
    • Make sure that the VNC Server has a read-only password set so that your mouse clicks and keystrokes don't interrupt work in progress
    • The first time you run the app, you will be prompted to give the app permission to run. Make sure you check all the boxes or the applet will not run

Comments

Popular posts from this blog

The Forecaster Brown Fan Club

How to Create a Pentaho Report Using the REST Client

Automated Testing with vncdotool (Not Headless, but Hairless)