Integrating AWS Face Liveness in React without Cognito Identity pool ID

0

Is Cognito Identity pool ID required to use Face Liveness in React front end. I am trying to integrate Face Liveness in my React project, backend has already provided a session ID and region, so I just plug it in <FaceLivenessDetector />. The issue is, when it runs, Face Liveness will throw me error from onError saying that "No Cognito Identity pool provided for unauthenticated access". But when building for android, we can skip auth all together. So is there anyways to skip auth for React as well?

Note: Only notable package used is @aws-amplify/ui-react-liveness from NPM

<FaceLivenessDetector
          sessionId={getProfileVerifyInitiateData?.data?.uvp?.session_id}
          region={getProfileVerifyInitiateData?.data?.uvp?.region}
          onAnalysisComplete={handleAnalysisComplete}
          onError={onFaceLivenessDetectorError}
/>

Face Liveness Doc

Bryan
已提問 9 個月前檢視次數 221 次
1 個回答
0

Hi Bryan,

Thanks for reaching out.

For using the FaceLivenessDetector component in a React based front-end, it is recommended to use Cognito Identity Pool as it handles the credentials sourcing with least privilege permissions and their expiry.

Managing credentials yourself on a web-app is challenging and can easily lead to security vulnerability if done incorrectly. If you have a secure way of managing credentials, you can use a custom credentials provider in the FaceLivenessDetectorCore component to get around using a Cognito Identity Pool.

Regards,

AWS Team

AWS
已回答 3 個月前
profile picture
專家
已審閱 1 個月前

您尚未登入。 登入 去張貼答案。

一個好的回答可以清楚地回答問題並提供建設性的意見回饋,同時有助於提問者的專業成長。

回答問題指南