The documentation describes the steps to integrate ActSDK into your iOS project.
Untar ActSDK_n.nnn.tar.gz. This contains the header files in "includes" and libactmobilemonon.a in "Libs" directory.
Let's say it is extractd to /path/to/ActSDK/
tar xzvf ActSDK_n.nnn.tar.gz
Untar ActSDK_ThirdParty_n.nnn.tar.gz. This contains the necessary third party frameworks and libraries for Ad integration.
tar xzvf ActSDK_ThirdParty_n.nnn.tar.gz
Let's say that the bundle id for your app is com.mycompany.myapp. Do the following steps:
Xcode will generate necessary files for the vpnExtension. Overwrite the contents of VPNSDKSample/PacketTunnelProvider.h and VPNSDKSample/PacketTunnelProvider.m into the Xcode generated ones.
If you want to override/have your own PacketTunnelProvider.m, in the extension's Info.plist file NSExtension section, there is a value NSExtensionPrincipalClass, this provides the main entry point for launching the extension and must be a .m file, not ActPacketTunnelProvider from the library. You can provide a wrapper .m/h, they need to do nothing but extend ActPacketTunnelProvider.
If the name of which is anything other than "PacketTunnelProvider", then set that name in Info.plist/NSExtension/NSExtensionPrincipalClass.
Please contact support for additional details.1) Under "Header Search Paths" add "/path/to/ActSDK/" and set the search to "recursive".
2) Under "Framework Search Paths" add "/path/to/ActSDK/" and set the search to "recursive".
3) Under "Library Search Paths" add "/path/to/ActSDK/" and set the search to "recursive".
NOTE: Please update the above build settings for both, the extension's target and the app's target.1) Under "Compile Sources", add NSData+Gzip.m and JSONKit.m to the project (present in the ActSDK/Extra directory). Add the Complier Flag -fno-objc-arc (for JSONKit.m)
2) Under "Link Binary With Libraries", click on the '+' sign. Then click on "Add Other...". Navigate to /path/to/ActSDK/Libs and add libactmobilemono.a. Choose "Create Folder References" in the prompt that follows.
3) Under "Link Binary With Liraries", click on the '+' sign. Then in the search box, type and add the following framework libraries:
In your app's plist file, ensure there is a string for "CFBundleDisplayName". Set its value to "Your App VPN" or something similar. This string shows up in the Apple VPN Profiles.
1) Edit your AppID and enable the following:
2) Create a new AppID for the VPN Extension. Give it a name "My App VPNExtension" and bundle identifier com.mycompany.myapp.vpnExtension (replace com.mycompany.myapp with your App's bundle id). Enable the following on the newly created AppID.
3) Go to 'Identifier|App Groups'. Create a new group and give it a name and a group id. Let's say the name is group.actsdk
4) Then go to the AppId of your app, edit it, edit the 'App Groups' and select the newly created group id above.
5) Then go to the AppId of the vpnExtension, edit it, edit the 'App Groups' and select the newly created group id above.
1) In your app's provisioning profile, ensure it has the entitlement for 'Network Extension iOS'.
2) Create a new provisioning profile for the extension product_code. Ensure it has the entitlement for 'Network Extension iOS'.
3) Now, get back to Xcode. Import these provisioning profiles into your Xcode for the respective targets.
4) Click on 'Capabilities' tab of your app target settings.
5) For both your App and Extension targets, go to Build Settings and set the 'Enable Bitcode' option to No.
There is no need to add any code to the extension target. Only the app needs to be modified to make calls to [ActSDK] methods. Please see ActSDK.h and VPNSDKSample sample code for reference.