Modify an Identity Pool Cognito JWT

0

I've joined a team working on an application that uses Cognito with Identity Pools and user state in Cognito Sync. We need to add some authentication to our process and the natural place would be to sprinkle a little data into the Cognito-generated JWT. I'd like to grab that data from, say, a lambda querying Aurora. I see that User Pools have a pretoken generation lambda trigger. Is there something similar I can do for identity pools?

已提問 2 年前檢視次數 331 次
2 個答案
0

Hi,

Can you share more details on how you get a token from cognito identity pool and how do you use it in your application? are you using GetOpenIdTokenForDeveloperIdentity API?

AWS
專家
已回答 2 年前
0

We're using the Javascript aws-sdk: new AWS.CognitoIdentityCredentials. Currently, we only use the token to maintain login state, renew token, logout, etc. Looking forward, we'd need a custom inspection for the new elements.

已回答 2 年前

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

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

回答問題指南