Closed Izainab22 closed 10 months ago
can you verify if you have the appropriate IAM policy? you should have permission for each of the following rekognition actions:
auth or unauth role of client/app user to start the liveness session: "rekognition:StartFaceLivenessSession"
backend service to create and get the liveness results: "rekognition: CreateFaceLivenessSession" "rekognition:GetFaceLivenessSessionResults"
Can you provide any sample code or sample app?
@Izainab22 Can you also provide what device model and iOS version you're seeing this error in?
I'm able to start the liveness in the demo app you provided now, I was configuring User Pool Group and I didn't give a permission for it. Once I granted the permission it worked.
But I'm using the same code in my app with the same configurations I did in with the demo app, and I'm facing the same issue but the difference is there's no failure and no thing begin printed in the console!
Here is more details:
I'm testing on iPhone 14 Pro Max and iPhone XS - both are iOS 16.6.
I'm using UIKit as a default language in my app. I can open the view and see the camera with the recording and close icons but it is sticking on recording without showing me the oval to detect the face and without any error printed in the console!
These are my CLI configurations:
In AWS Console I've granted the below permission to my anauth, auth roles and my user pool group:
{
"Effect": "Allow",
"Action": "rekognition:StartFaceLivenessSession",
"Resource": "*"
}
I granted only this access because I've developed .Net API's for creating the session and getting the result. And I'm calling these API's in my iOS app.
My code:
I've been blocked at this stage for almost a week... Your help will be much much appreciated!
@Izainab22 Could you provide a sample app that replicates your app running into the same issue to help with debugging/troubleshooting?
@phantumcode Thanks for your support! It finally worked, the issue was with 'DBDebugToolkit' cocoapod. I was using it in my app and it seems the AWS API is not being called for security reasons, once I comment it out it worked!
Hi,
I'm using the same app you've uploaded, and I did all the backend configurations. For creating the sessionId I'm using my own .Net API and I'm calling it in createSession() function. But I'm not able the start the faceLiveness.
Create Liveness Session Button will call my API and pass the sessionId to FaceLivenessDetectorView, and it's opening the camera but once the recording is started before getting the Oval I'm getting Validation error and the camera still open without doing any thing.
These are the errors am getting in the console: