Using Cognito User Pools, without Cognito Federated Identities(identity pools)

后端 未结 4 1560
滥情空心
滥情空心 2021-01-07 09:38

I would like to use only Cognito User Pool, and therefore I want to use identity federation with Cognito User Pools, without Cognito Federated Identities (identity pools).

4条回答
  •  刺人心
    刺人心 (楼主)
    2021-01-07 10:16

    Looks like they only allow User Pool Federation with their own UI/SDK. What I ended up doing for react-native was

    • get facebook token

    • sign up the user into the user pool with a custom attribute to track facebook Id and generic password

    • use the temporary credentials (need to setup IAM for cognito user pool - adminMovetoGroup to move the user into the auto created user pool federated group.

    • create lambda function to auto-confirm the end user.

    This way the user can log in and get credentials using federated identities, but then they also have an account in the event they stop using facebook. They would also need to reset their password.

提交回复
热议问题