...
In Xcode, add the dependency to the Mobile Protect SDK through the File → Add Packages… menu.
Enter the following URL into the search bar on the top right:
Code Block https://spm:{MOBILEPROTECT_REPO_API_KEY}@mobile-protect-repos.securetheorem.com/mobileprotect-ios
Replacing
{MOBILEPROTECT_REPO_API_KEY}
with the Mobile Protect API key.
For Mobile Protect Anti Fraud, use the following URL instead:
Code Block |
---|
https://spm:{MOBILEPROTECT_REPO_API_KEY}@mobile-protect-repos.securetheorem.com/mobileprotect-ios-antifraud |
Select your preferred Dependency Rule, and then click on the Add Package button.
Select the Target you wish to add Mobile Protect to, and then click on the Add Package button.
That key is NOT SENSITIVE. The key is only used to download the Mobile Protect SDK, but cannot be used to pull any data from the app nor the backend. A different and more secure key is required for pulling data. It is safe to commit in your repository.
Step 2: Add Mobile Protect Configuration File
Copy the MobileProtect.plist
config file into the project, place it in the Target root. See Add Existing Files and Folders to a Project for instructions.
The plist file contains an AUTH_TOKEN
key; however, the key is NOT SENSITIVE. The key is only used to identify the data sent by Mobile Protect to the backend, but cannot be used to pull any data from the app nor the backend. A different and more secure key is required for pulling data. It is safe to commit and have the token in the .apk as it is used as an identifier, similar to Google's Firebase: https://firebase.google.com/docs/projects/api-keys
Results
Please visit https://www.securetheorem.com/mobile/protect to see the list of your apps and the state of protection, along with the individual protection item details.