简体   繁体   English

AWS Cognito 用户设备触发器

[英]AWS Cognito User Devices Trigger

We use AWS Cognito for user authentication.我们使用 AWS Cognito 进行用户身份验证。 Every user can have multiple devices.每个用户都可以拥有多个设备。 We would like to react to newly registered or deleted devices for every user.我们希望对每个用户的新注册或删除设备做出反应。 Ideally through a lambda trigger.理想情况下,通过 lambda 触发器。 How can we archieve that?我们怎样才能存档呢?

These standard triggers won't work for our usecase: Customizing User Pool Workflows with Lambda Triggers这些标准触发器不适用于我们的用例: Customizing User Pool Workflows with Lambda Triggers

Does anyone have sugguestions how to tackle that problem?有没有人建议如何解决这个问题?

Step1: In AWS Cognito you net to enable the end-user device tracking as mentioned in the below document.第 1 步:在 AWS Cognito 中,您可以按照以下文档中的说明启用最终用户设备跟踪。

https://aws.amazon.com/blogs/mobile/tracking-and-remembering-devices-using-amazon-cognito-your-user-pools/ https://aws.amazon.com/blogs/mobile/tracking-and-remembering-devices-using-amazon-cognito-your-user-pools/

Step2: Every authentication attempt for the user, you can create an SNS message with the device info and user info. Step2: 用户的每次认证尝试,您都可以使用设备信息和用户信息创建一条 SNS 消息。

Step3: Push this message into a SQS so that it can trigger a AWS Lambda步骤 3:将此消息推送到 SQS,以便它可以触发 AWS Lambda

Step4: Process the message and respond to the user according to the required logic. Step4:处理消息并根据需要的逻辑响应用户。

I hope this helps.我希望这有帮助。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 基于 Java 的 AWS Cognito 预注册 Lambda 触发器:自动确认用户并验证 email - Java-based AWS Cognito Pre-Sign-up Lambda Trigger: Automatically confirm user and validate email JAVA- AWS Cognito - 检查 Cognito 用户池中是否存在用户 - JAVA- AWS Cognito -Check if a user exists in Cognito User pool 在 Cognito Post Confirmation Trigger 上未收到用户详细信息 - Not receiving user details on Cognito Post Confirmation Trigger AWS cognito用户池,自定义消息lambda - AWS cognito user pools, custom message lambda 检查用户是否已登录AWS Cognito,JAVA - Check if user is logged in aws cognito, JAVA AWS Cognito用户的子更改在getAuthenticationDetails上 - AWS Cognito user's sub changes on getAuthenticationDetails AWS Java Lambda Cognito-无效的lambda触发源 - AWS Java Lambda Cognito - Invalid lambda trigger source 无法克服Java AWS Lambda Cognito自定义消息触发器的InvalidLambdaResponseException - Unable to overcome InvalidLambdaResponseException for Java AWS Lambda Cognito custom message trigger 如何通过Java API使用AWS Cognito对用户进行身份验证 - How to authenticate user using AWS Cognito via Java API AWS Cognito-使用SignInUI登录后获取用户数据 - AWS Cognito - Get user data after login with SignInUI
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM