Installation

Installation

Requirements:

Cocoapods installation​‌

    Project dependencies are specified in a file called Podfile. Create this file in the same directory as your Xcode project file (.xcodeproj) if it doesn't already exist.
    Add the following lines to your Podfile: (make sure to replace YOUR_PROJECT_NAME)
1
platform :ios, '10.0'
2
source 'https://bitbucket.org/authenteq/cocoapods-specs.git'
3
source 'https://cdn.cocoapods.org/'
4
5
target 'YOUR_PROJECT_NAME' do
6
use_frameworks!
7
pod 'AuthenteqFlow'
8
end
Copied!
    Run Terminal command to install the dependencies in your project:
1
$ pod install
Copied!

Project settings

    Add NSCameraUsageDescription key in your Info.plist file
    Under the Info tab, add description as to why camera access is required by clicking the small `+` button and adding the text
    For example: 'Camera permission is needed to take a photo of your document and face for identification.'
    Under the Build Settings tab, make sure the iOS Deployment Target is 10.0 or higher
If your app support iOS 10:
    Add NSPhotoLibraryUsageDescription key in your Info.plist file
    Under the Info tab, add description as to why camera access is required by clicking the small `+` button and adding the text
    For example: 'Select document image to be uploaded.'
If issues with building the app, save the project as a workspace, then close project and open workspace

Setup project for NFC scanning

    Add NFCReaderUsageDescription key in your Info.plist file
    Add com.apple.developer.nfc.readersession.iso7816.select-identifiers key in your Info.plist file and specify A0000002471001 as 'Item 0'.
    Add Near Field Communication Tag Reading capability in project "Signing & Capabilities" section.

Submit your app to the App Store or Testflight

The AuthenteqFlow.framework is a dynamic framework which contains slices for all architectures - device and simulator. If you intend to extract the .ipa file for ad-hoc or App Store distribution, you’ll need to pre-process the framework to remove simulator architectures.
The best solution is to add a script at the build phase and after the embed frameworks build phase, which strips unused slices from the embedded frameworks.
Script
1
APP_PATH="${TARGET_BUILD_DIR}/${WRAPPER_NAME}"
2
3
# This script loops through the frameworks embedded in the application and
4
# removes unused architectures.
5
find "$APP_PATH" -name '*.framework' -type d | while read -r FRAMEWORK
6
do
7
FRAMEWORK_EXECUTABLE_NAME=$(defaults read "$FRAMEWORK/Info.plist" CFBundleExecutable)
8
FRAMEWORK_EXECUTABLE_PATH="$FRAMEWORK/$FRAMEWORK_EXECUTABLE_NAME"
9
echo "Executable is $FRAMEWORK_EXECUTABLE_PATH"
10
11
EXTRACTED_ARCHS=()
12
13
for ARCH in $ARCHS
14
do
15
echo "Extracting $ARCH from $FRAMEWORK_EXECUTABLE_NAME"
16
lipo -extract "$ARCH" "$FRAMEWORK_EXECUTABLE_PATH" -o "$FRAMEWORK_EXECUTABLE_PATH-$ARCH"
17
EXTRACTED_ARCHS+=("$FRAMEWORK_EXECUTABLE_PATH-$ARCH")
18
done
19
20
echo "Merging extracted architectures: ${ARCHS}"
21
lipo -o "$FRAMEWORK_EXECUTABLE_PATH-merged" -create "${EXTRACTED_ARCHS[@]}"
22
rm "${EXTRACTED_ARCHS[@]}"
23
24
echo "Replacing original executable with thinned version"
25
rm "$FRAMEWORK_EXECUTABLE_PATH"
26
mv "$FRAMEWORK_EXECUTABLE_PATH-merged" "$FRAMEWORK_EXECUTABLE_PATH"
27
28
done
Copied!
Last modified 1mo ago