1 Answer
- Newest
- Most votes
- Most comments
1
Hi,
Cognito does not create the Lambda's Trigger.
You should check whether the Lambda's Permissions contain a Resource-based policy statements like this:
{
"Version": "2012-10-17",
"Id": "default",
"Statement": [
{
"Sid": "lambda-allow-cognito",
"Effect": "Allow",
"Principal": {
"Service": "cognito-idp.amazonaws.com"
},
"Action": "lambda:InvokeFunction",
"Resource": "<your Lambda function ARN>",
"Condition": {
"StringEquals": {
"AWS:SourceAccount": "<your account number>"
},
"ArnLike": {
"AWS:SourceArn": "<your user pool ARN>"
}
}
}
]
}
answered 7 months ago
Relevant content
- asked 2 years ago
- Accepted Answerasked 6 years ago
- AWS OFFICIALUpdated a year ago
- AWS OFFICIALUpdated 2 years ago
- AWS OFFICIALUpdated a year ago
- AWS OFFICIALUpdated 4 months ago
Yes, it does have a Resource-based policy statement like the one you mentioned. (I edited the question to show it)
This resource-based policy means you're already successful. The Lambda in my own environment does not have a Trigger, but the Lambda runs fine.
You're right. It fires fine. It's just misleading that the trigger does not show up in the lambda function overview.