Skip to content

Cognito User Manager is a user management solution that demonstrates building User flows in AWS Cognito using ASP.NET Core.

License

Notifications You must be signed in to change notification settings

referbruv/CognitoUserManager

Repository files navigation

CognitoUserManager - an ASP.NET Core MVC implementation for Cognito User Flows

.NET GitHub stars Twitter Follow

What is this solution about?

Cognito User Manager is a user management solution that demonstrates building User flows in AWS Cognito using ASP.NET Core.

What is AWS Cognito?

AWS Cognito is a user management and identity service offered by AWS as a part of its Cloud suite. It provides a single user identity and authentication service which can also be used to access all of its resources. The Users are placed inside isolated spaces called User Pools, which any registered third-party client can access via OAuth flows.

What does the solution offer?

The solution demonstrates the following features / flows in AWS Cognito:

  • New User SignUp
  • Existing User SignIn
  • Password Reset for a Signed In User
  • Forgot Password flow for an unsigned user
  • Fetch JWT Tokens (Id_Token, Access_Token, Refresh_Token) for a Signed In User

This solution can offer a solution to two problems:

  1. It demonstrates building Cognito login flows using .NET SDK
  2. It can work as a simple tool to create and manage users on a User Pool without having to go through the same process in AWS Console.

What are the prerequisites?

The solution requires the following things first to run:

  1. An active AWS Cognito User Pool
  2. An active Client created on the Cognito Pool which the solution uses to connect to the User Pool
  3. AccessKey and AccessSecretKey of a Programmatical User who has access to create Users

*You need to update these values inside appsettings.json respectively

On the environment side, the solution requires a .NET Core (.NET 5) installation on the machine.

How do I run this?

The solution is built using ASP.NET Core (.NET 5) with a pipeline to upgrade to .NET 6 (soon), so for now you'd need a .NET Core (.NET 5) installed on your machine.

  1. Clone the solution into your local repository
  2. Open the solution in Visual Studio and set CognitoUserManger.WebApp as the startup project
  3. Run the solution

or

  1. Clone the solution into your local repository
  2. Navigate to CognitoUserManager.WebApp directory and open a command prompt / Terminal
  3. Execute the command dotnet run

I want to know more

To know more about this and to understand how this works in detail, I'd recommend you to check out the below articles where bits and pieces of this solution have been used:

Issues or Ideas?

If you face any issues or would like to drop a suggestion, raise an issue

License

The solution is completely open source and is licensed with MIT License.

Show your Support

Found this solution helpful and useful? You can do these to help this reach greater audience.

  1. Leave a star on this repository ⭐
  2. Recommend this solution to your colleagues and dev community
  3. Join my Twitter family. I regularly post awesome content on dev over there.
  4. Join my Facebook community. I regularly post interesting content over there as well.
  5. You can also buy me a cup of great coffee ☕!

Buy Me A Coffee

For more detailed articles and how-to guides, visit https://referbruv.com

About

Cognito User Manager is a user management solution that demonstrates building User flows in AWS Cognito using ASP.NET Core.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published