The iPhone platform provides a mechanism whereby applications can register custom URL formats with the system. When other applications call APIs to “launch” URLs with these special formats, the application associated with the URL format will be launched. This mechanism can be used to launch applications from web pages displayed in Mobile Safari.
The VPN client application will register a custom URL format with the following form:
When this URL is “launched” by Safari or some other application, the following will occur:
- The Pulse application will be launched.
- If a tunnel is not already running and the “action” in the URL is “start”:
- If no configuration with a URL matching the host and path specified in the launch URL is already configured, the user will be taken to the “Add configuration” screen where they can define the appropriate configuration. If there is already a configuration with the correct URL, that configuration will be enabled.
- If there are session cookies specified in the launch URL, a new tunnel will be established with the given session cookies.
- If there are no session cookies specified in the launch URL, the login window will be shown and the user will be taken through the login process. After the login process completes, the tunnel will be started.
- If the tunnel is already running then nothing will be done.