Possible to deploy RealVNC via Group Policy?

Punkrulz

Somewhat eXPerienced
Joined
24 Dec 2001
Messages
790
Hey guys,

One of the greatest advantages that I have been trying to take care of here is by placing RealVNC on all of the users workstations. I believe it's a wonderful program, because it's free, it allows me to connect to both Windows 2000 and Windows XP machines, and it allows me to see exactly what the user is seeing and makes it easier to troubleshoot from the comfort of my desk.

For some reason I believe some how the application is getting uninstalled on some workstations. I'm looking for some added security, by making it deployable via group policy. Is it possible to deploy real VNC, and to configure it so that it will use the password that I specify?

Thanks!
 
Anything with an MSI installer can be deployed.

I believe MS has a tool somewhere to capture non-msi installs and convert them to msi installers for deployment.

I was only shown the tools briefly in passing at my old job so I'm afraid I'm not much more helpful than that.
 
there are ways, if you have admin rights on the remote machine, to remotely install the VNC Client piece on an as-needed/used basis.

A combination of the psexec tools from sysinternals can accomplish this. At one point I had a whole batch file that automated the whole process to connect, copy, install, and configure VNC all remotely and let me connect.
 
Fitz, we have the domain administrator account so I can use that to install applications under... so that part is taken care of. Could you perhaps link me to some utilities or something that I could follow up with this?
 
Hey guys,

One of the greatest advantages that I have been trying to take care of here is by placing RealVNC on all of the users workstations. I believe it's a wonderful program, because it's free, it allows me to connect to both Windows 2000 and Windows XP machines, and it allows me to see exactly what the user is seeing and makes it easier to troubleshoot from the comfort of my desk.

For some reason I believe some how the application is getting uninstalled on some workstations. I'm looking for some added security, by making it deployable via group policy. Is it possible to deploy real VNC, and to configure it so that it will use the password that I specify?

Thanks!
Silent deploying RealVNC. Free Installation And Administration In A Computer Network
Ganduri amestecate: Silent deploying RealVNC. Free Installation And Administration In A Computer Network
 
For those looking to deploy RealVNC via GPO, here's the easy solution I came up with yesterday. Just thought I'd share and save people the trouble I went through ...

This has been tested as a fresh install, upgrading from previous revisions of RealVNC v4.x.x and installing over the top of an existing v4.5.3. I'm sure it also works with other versions, but you'll need to test it first.

This should take no more than 20 mins to setup.

Instructions:


  • Install RealVNC on a machine, configure it as required with relevant VNC/Windows password and security groups (if necessary).

  • Export the following key to a file named vnc_settings.reg
HKEY_LOCAL_MACHINE\SOFTWARE\RealVNC\WinVNC4
  • Copy the VNC setup .exe file and the above .reg file to a folder named VNC in the NETLOGON directory of your DC's, i.e. \\yourdomain.ext\NETLOGON\VNC

  • Copy and paste the VBS code below into notepad.

  • Amend lines 17-20 of the file to match your relevant NETLOGON\VNC path, setup file name, RealVNC version number and license key.

  • Save the file with a .vbs extension

  • Create a GPO and configure the relevant OU links and scope.

  • Edit the GPO and add the .vbs file as a machine startup script.

  • Done !

Code:
' *********************************************************
' ** VBScript to deploy VNC
' **
' ** - Copies VNC setup and .reg file to local temp folder
' ** - Imports .reg file containing VNC settings
' ** - Runs setup file
' ** - Creates license key
' ** - Generates security key
' **
' **     Written by Andy Whittle, 28/07/10
' **
' *********************************************************

Set wshShell = CreateObject("WScript.Shell")
Set objFSO = CreateObject("Scripting.FileSystemObject")                ' Create the File System Object

strVNCSetupPath =     "\\yourdomain.ext\netlogon\VNC\"            ' Path to setup and .reg file on network share - Keep trailing slash
strVNCSetupFile =     "vnc-E4_5_3-x86_x64_win32.exe"                ' Full name of setup file with extension
strDeployVersion =     "4.5.3"                            ' VNC version to be deployed
strVNCLicKey =         "ABCDE-12345-FGHIJ-67890-KLMNO"                ' VNC license key
strVNCRegKey =         "HKEY_LOCAL_MACHINE\SOFTWARE\RealVNC\WinVNC4\"        ' VNC registry key (HKLM) - Keep trailing slash
strVNCRegFile =     "vnc_settings.reg"                    ' Full name of reg file with extension
strVNCInstallPath =     """C:\Program Files\RealVNC\VNC4\"            ' VNC installation path within 'Program Files' folder - Start with """ and end with trailing slash
strVNCConfigExe =     "vncconfig.exe"                        ' Full name of VNC config program with extension
strTempDir =         "C:\Temp\"                        ' Local temp folder to copy files to - Keep trailing slash
strStartMenuFolder =     wshShell.Environment("PROCESS")("ALLUSERSPROFILE") _
                          & "\Start Menu\Programs\RealVNC"            ' Path to VNC Start menu folder - NO trailing slash !

' ------------- DO NOT EDIT BELOW THIS LINE -------------


on error resume next

strCurrentVersion = wshShell.RegRead(strVNCRegKey & "Version")            ' Check for existing VNC version

If strCurrentVersion = strDeployVersion Then                    ' If already has latest version ...
  wscript.quit                                    ' ... end script
End If

If Not objFSO.FolderExists(strTempDir) Then                    ' Check for local temp folder
  objFSO.CreateFolder(strTempDir)                        ' Create local temp folder
End If

objFSO.CopyFile strVNCSetupPath & strVNCSetupFile, strTempDir, True        ' Copy VNC setup file to local temp folder
objFSO.CopyFile strVNCSetupPath & strVNCRegFile, strTempDir, True        ' Copy VNC reg settings file to local temp folder

strReturnCode = wshShell.run _
  ("reg import " & strTempDir & strVNCRegFile,0,false)                ' Import reg settings
strReturnCode = wshShell.run _
  (strTempDir & strVNCSetupFile _
  & " /sp- /verysilent /norestart /COMPONENTS=WinVNC,WinVNC/VNCMirror",0,true)    ' Run VNC setup file
strReturnCode = wshShell.run _
  (strVNCInstallPath & strVNCConfigExe & """ -license " & strVNCLicKey,0,false)    ' Generate license key
strReturnCode = wshShell.run _
  (strVNCInstallPath & strVNCConfigExe & """ -service -generatekeys",0,false)    ' Generate security key

wshShell.RegWrite strVNCRegKey & "Version", strDeployVersion, "REG_SZ"        ' Write VNC version to registry

If objFSO.FolderExists(strStartMenuFolder) Then                    ' Check for VNC Start menu group
  objFSO.DeleteFolder(strStartMenuFolder)                    ' Delete VNC Start menu group
End If
When the script is first executed, it will install the required version of RealVNC, regardless of existing installed version. A registry value named "Version" will then be added which the script will use to determine if the latest is already installed on subsequent runs and will quit if no installation is required.

The script is very quick to execute and install RealVNC and does so silently at startup. The .exe and .reg files are copied locally to speed up the process.

NB: Line 51 contains the install switches which can be amended to suit. We don't deploy the Viewer to all machines, although you might want to. Changing /VERYSILENT to /SILENT will display an installation progress screen, but will still be automated. Lines 59-61 exist to delete the VNC Start menu program group. This isn't necessary and the lines can be deleted or commented out with an apostrophe if you want to leave the shortcuts intact.

To upgrade in future, just copy the new setup execuable file to the NETLOGON\VNC directory and amend lines 18 and 19 of the .vbs file to reflect the new filename and version. That's it. The script will recognise the new version and deploy it as necessary.

As a side note, new VNC settings can be deployed using this script by changing the version number, e.g. change 4.5.3 on line 19 to 4.5.3_2. Again, you'll need to configure a machine with the new settings, then export the key to a .reg file and copy to NETLOGON\VNC. The script will recognise a change, even though it is the same version, and will reinstall VNC and import the new .reg file.

Enjoy !
 
Its come to my attention that the layout of the script I posted has been screwed by pasting it into the thread.

The 'neat and tidy' version is attached below. Obviously, you'll need to change the file extension and amend the details within before use.

For reference, VNC has now been successfully deployed to 800 XP clients using this script. Also tested and working on Windows 7 32bit.

If anybody needs help with this, send me a message. I'm always happy to give something back to the community.

Cheers

Andy
 

Attachments

  • deploy_vnc.txt
    3.1 KB · Views: 1,046

Members online

No members online now.

Latest profile posts

Also Hi EP and people. I found this place again while looking through a oooollllllldddd backup. I have filled over 10TB and was looking at my collection of antiques. Any bids on the 500Mhz Win 95 fix?
Any of the SP crew still out there?
Xie wrote on Electronic Punk's profile.
Impressed you have kept this alive this long EP! So many sites have come and gone. :(

Just did some crude math and I apparently joined almost 18yrs ago, how is that possible???
hello peeps... is been some time since i last came here.
Electronic Punk wrote on Sazar's profile.
Rest in peace my friend, been trying to find you and finally did in the worst way imaginable.

Forum statistics

Threads
62,015
Messages
673,494
Members
5,621
Latest member
naeemsafi
Back