TeamViewer 11 (Again) - With Munki

TeamViewer 11 (Again) - With Munki

2016, Mar 08    

I'm sure many of you read my previous post TeamViewer 11 and Munki where I described what I thought was the best way to deploy TeamViewer 11 on OS X by installing Version 8, then Version 9 and finally Version 11. Last week I decided that there has to be a better way and began digging through some of the packages. What I found was an actual method to deploy TeamViewer 11 by using pre and post install scripts. I no longer have to rely on instilling previous versions of the software.

So when I expanded the TeamViewer Host 9 package as this version would convert our password from version 8 to the new encryption method, I found that TeamViewer is running a post install script that does two things:

  • Renames com.TeamViewer8.Settings.plist to com.teamviewer.teamviewer9.plist
  • Using /usr/bin/defaults to write a simple Date key to the plist file before TeamViewer launches

It seems that when TeamViewer detects this Date key in the plist file it will convert the key SecurityPasswordAES to PermanentPassword which is exactly what we are looking for since PermanentPassword is a "unique" data binary for each system.

To test this theory I decided to use a test system that had never had TeamViewer installed on it. I then used pre and post install scripts that will create the plist file for TeamViewer 11 with the settings we would like to define and apply the attribute needed for customizations. Here are my pre and post install scripts:

TeamViewer 11 Pre Install Script

TeamViewer 11 Post Install Script

Upon testing these scripts within Munki and a silent install, TeamViewer was able to correctly change the password. No longer, do we need to install previous versions before installing this version. Now that this install is finished you can apply your customization that we highlighted in the previous post. You can get the modified MainMenuHost.NIB file here. Once you have this file you can build a DMG file for use within Munki. This file will remove the following from the TeamViewer Menu Bar item:

  • Check for Updates
  • Activate License
  • TeamViewer Website
  • Exit TeamViewer

With these two files, we can deploy TeamViewer silently to a system and efficiently. I always require a logout so nothing from TeamViewer is running when the install takes place just to be safe which also might be why I need to invoke the LaunchDaemon. Your experience may vary but if you have any questions please be sure to let me know. Also we need to let TeamViewer know that this kind of modification to make their product deployable isn't acceptable and they should provide the same type of deployment they offer for Windows for Mac.