Cognito oAuth with AWS SDK

0

Hi

I'm trying to implement a .Net website that uses Cognito to access S3 and DynamoDB resources securely using oAuth2. I've raised a question on Stack Exchange but they have not been able to answer my query: https://stackoverflow.com/questions/74643160/accessing-aws-resources-securely-using-the-aws-sdk-for-net

All examples I have found do two things: authenticate a Cognito userpool user and access resources using an IAM account. This is not how I understand oAuth should work, which is: authenticate a Cognito user -> get the Identity Pool ID token -> Use the token to access S3/DynamoDB.

I've done this successfully using JS and found an example here: https://hobbyistcoder.com/2015/05/25/character-creator-with-amazon-dynamodb-integration-in-unity3d/ which does it in an obsolete SDK, but there doesn't appear to be any equivalent to the CognitoAWSCredentials in v 3 of the SDK, so I'm stuck.

1 Answer
0

Nick, I can't offer you any specific answers but I do share your pain when it comes to using Cognito and .NET - I have found examples and documentation less than ideal.

I am going to have to face this challenge again for a personal project in the next few weeks so fingers crossed I'll have better outcomes this time.

The best points of reference I have found are :

answered a year ago

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions