Viscosity VPN Helper



Viscosity VPN Helper 1.1

Configure your own one-click-starter for Viscosity VPN connections and programs

Viscosity offers an option to start shell scripts right after connection/disconnecting using OpenVPN commands, see this post for more information

But if you have to launch a special VPN connection before you can use programs like Hulu Desktop or the BBC iPlayer it is really annoying that you have to go to the menu, launch the VPN connection, wait for the connection to be established and then launch your program - and if you quit your program you have to manually disconnect the VPN connection again.
Things become even more annoying if you use your Mac as a media center and you are forced to do all these steps with the remote control.

With Viscosity VPN Helper you only have to do these steps once. After the initial configuration Viscosity VPN Helper
  • connects to your VPN server,
  • starts your desired program and
  • -after you have quit the program- automatically disconnects from the VPN server.

All with just one click.
After initiating the connection Viscosity VPN Helper checks every minute if your program is still running and closes the VPN connection if it is no longer needed.

You can have more than one copy of Viscosity VPN Helper each one for a special VPN server/program pair - and if you use a Remote Application like RemoteBuddy you can launch the Viscosity VPN Helper copies with one click from your remote.

Download: Viscosity VPN Helper 1.1

(about 33 KB)

Viscosity VPN Toggler

If you only want to connect and disconnect your VPN server from within RemoteBuddy with one single click you can use Viscosity VPN Toggler.

On the first launch you have to select the VPN server, the Viscosity VPN Toggler connects to the VPN server and quits.
When Viscosity VPN Toggler is launched again, it checks if the VPN connection is up and closes the connection or if the connection is down it connects to the VPN server.

Download: Viscosity VPN Toggler 1.0

(about 37 KB)

IMPORTANT NOTICE: VISCOSITY is required to use these scripts. Viscosity is an OpenVPN client for Mac, providing a rich Cocoa graphical user interface for creating, editing, and controlling VPN connections.


selcet the desired VPN server from the list.
The list contains all VPN connections from your Viscosity configuration
select the program to be launched after the VPN connection is established
the configuration is finished and the connection is started
rename your file according to the VPN connection/ program
Make copies of Viscosity VPN Helper for every program you need and put them in your remote application (the screenshot is from Remote Buddy)

Version History

1.0 2009-12-31 initial release
1.1 2010-01-09 fix for some "strange" server names

Q & A section

Q: How can I edit the script?
A: To view or edit the source code drag the program on the Applescript Editor icon.

Q: Why is Viscosity required, I am using the freeware Tunnelblick?
A: I have used Tunnelblick for some months too but liked the interface of Viscosity better - well worth the US$9