Developers SDK

VPNUConfigurator

This class provides an interface for controlling VPN connections.
Discussion

Before using this class you must authorize or register with the help of VPNUAuthorizer class. You must pass the same VPNUTransport instance to its constructor as you have passed to VPNUAuthorizer instance constructor.

A basic workflow after initializing looks as follows: For iOS 9+ / macOS 10.11+ only (ignore first two steps if you don't support iOS 9+ / macOS 10.11+):

  1. Set desired value for `protocol` property if needed.

  2. Asynchronously call loadInitialConfiguration.

  3. Provide a custom VPNUOnDemandConnectionManager object for onDemandConnectionManager property if you want to manage VPN On Demand Rules.

  4. Configure VPN server item using setupWithServerItem:alreadyInstalled: method.

  5. Connect to the configured VPN server using startVPNWithError: method.

  6. Disconnect at any time using stopVPNWithError: method.

You can check connectionStatus property of this class to know the real VPN connection status every time VPNUConnectionStatusDidChangeNotification notification is posted or simply use KVO.

attention: This class is a public interface of a class cluster. You are discouraged from subclassing it. attention: You MUST call loadInitialConfiguration method asynchronously if you are using iOS 9+ / macOS 10.11+ BEFORE any call to instance of this class.

Extends: NSObject

Declared in: VPNUConfigurator.h

Class Methods

Instance Methods

Properties

Typedefs