Add a New Trusted Device
Last updated
Last updated
There are 2 steps that's needed to add a new Trusted Device:
Show the QR Code of the New Device
Scan the New Device's QR Code using the Trusted Device
To show the QR Code of the new device:
Example:
This will open a View Controller with a QR Code that can be scanned from the Trusted Device. After registration is done, the above-defined callback function would be called.
For the above callback, a text label in the SomeUIVC
view controller will be populated to let the user know whether registration succeeded or failed. Otherwise, if desired, the user can also perform a segue to another view controller (on success or failure) in the callback function as well.
Once it's scanned and registered successfully as, the View Controller will show a success image, and close after 3 seconds.
If after 3 minutes, the new device is still not registered as a Trusted Device, it will show an error message.
To scan the QR Code from a Trusted Device, call the function:
This will open a View Controller that opens the Camera. It will ask for permission to access the camera. When the QR Code is detected and scanned, it will automatically attempt to register the new device. After scanning is done, the user will be redirected back to the above SomeUIVC
view controller.
When the QR Code is detected and registered, the SDK will automatically show whether it was successful or if there's an error.
Now you can authenticate from the new device without requiring approval.