Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cognito emulation #26

Closed
csabakoncz opened this issue Feb 22, 2017 · 34 comments
Closed

Cognito emulation #26

csabakoncz opened this issue Feb 22, 2017 · 34 comments

Comments

@csabakoncz
Copy link

csabakoncz commented Feb 22, 2017

Hi,

In our tests we use a large number of made-up users.
It would be nice if we could have a local user pool (to which we could add these users programmatically) and authentication service.

Best regards,
Csaba

┆Issue is synchronized with this Jira Bug by Unito

@whummer
Copy link
Member

whummer commented Feb 23, 2017

Hey @csabakoncz , can you provide a few more details about your use case please. When you say users, are you talking about IAM Users? (See API reference here: http://docs.aws.amazon.com/IAM/latest/APIReference/)

Note that the IAM API has not yet been integrated into LocalStack (which means that IAM Users are not available), but we may consider adding the IAM API if we understand your exact use case. Can you provide some examples how exactly you create and interact with your test user accounts? Thanks

@whummer
Copy link
Member

whummer commented Feb 23, 2017

I just realized that your request is related to the Cognito service: https://aws.amazon.com/cognito/ Still, can you provide a bit more background on your use case, in particular how your tests interact with the Cognito API?

@csabakoncz
Copy link
Author

Hi,
Unfortunately we moved to AWS only recently, so I am somehow unsure with the Cognito terminology.
Previously we used CloudFoundry's UAA, which is not available only as a service, but also as a standalone application over which we have can have full control. This came handy for setting up our local test environment.

The only way our functional tests interact directly with Cognito is to obtain Oauth tokens using test user credentials. These tokens are then handed over to the services under test when performing REST operations on them.

So the most important features of a Cognito emulation would be:

  • ability to manage a user pool (define users)
  • ability to authenticate users

I will look up the exact API calls and will provide a list of them.
Best regards,
Csaba

@hassankhan
Copy link

The Cognito "brand" is rather confusing, but what @csabakoncz is referring to is Cognito (Your?) User Pools.

@hassankhan
Copy link

A more complete use-case would be to use an authorizer for a Cognito User Pool to authorize incoming requests to API Gateway (backed by Lambda):

Request -> Cognito Authorizer -> API Gateway -> Lambda -> Response

@damianesteban
Copy link

@hassankhan This is exactly the use case we are looking to test. I hope localstack supports Cognito User Pools in the future.

@whummer
Copy link
Member

whummer commented Jul 15, 2017

@csabakoncz @hassankhan @damianesteban Support for AWS Cognito is on our roadmap and we're actively working on it. Please stay tuned, more details following soon.

@mattcarrier
Copy link

@whummer Any updates, or anything we can help with?

@msolimans
Copy link

msolimans commented Mar 22, 2018

@whummer any updates? any expected date!

@vincentsolutions
Copy link

@whummer Would really be interested in hearing out if there was any options about this feature. I've been actively looking for something like this!

@warnerpinz
Copy link

Looks like this got abandoned.

@pchaganti
Copy link

👍

@ojurkiewicz
Copy link

So I guess still nothing has changed?

@oleersoy
Copy link

This would be really cool to have!

@rcavezza
Copy link

I would also be very interested in this.

@sahellebusch
Copy link

Also very interested.

@jtszalay
Copy link

Interested!

@tim-xch4nge
Copy link

This would be a great help to our development as we are experiencing issues with local testing of Cognito authorisation

@aldarund
Copy link

@whummer is it still on roadmap anywhere soon or no chances?

@tillkuhn
Copy link

tillkuhn commented Sep 3, 2018

Add me to the growing list of people who ran into the very same issue and would really appreciate to see Cognito support in localstack soon.

@edmarjsg
Copy link

Same issue here. It'd really be great if you guys added support for Cognito.
Any updates/ETA on this?

@RyanFelt
Copy link

Would love this!!

@holtc
Copy link

holtc commented Dec 23, 2018

Any update on this? Would be great to be able to test Cognito authentication and authorization locally

@ghost
Copy link

ghost commented Dec 28, 2018

Oh man, this is close to a showstopper for a lot of people I know, and myself. If a team can't test their entire (or nearly) code infrastructure offline; it's pretty hard to ignore the significant risk this comes with.

@hatityechindove
Copy link

It will be really great to have cognito added to the localstack

@lwoodson
Copy link

lwoodson commented Feb 25, 2019

There are many resources out there that promote the using of Amazon Cognito with a serverless application model for end-user auth. Here is one very popular example for a full-stack React JS app on the front-end working with a serverless backend:

https://serverless-stack.com/

If cognito support were available in localstack, you would be able to use the serverless-localstack plugin to run the whole app described above end-to-end with localstack. This would be a huge boon to productivity for local development.

So 👍 for getting cognito support available. If you are interested in having a new contributor to work towards that end, let me know, @whummer.

@7hibault
Copy link

Same here, I would love to be able to execute my full stack (api gateway, lambdas, dynamodb, cognito, cloudfront) locally.

I was getting excited about Amazon's serverless but not having control over this kind of things is a bummer :(

@jeffdoolittle
Copy link

+1 for cognito support in local-stack

@oleersoy
Copy link

oleersoy commented Mar 6, 2019

Anyone want to collaborate on a "Task" list for what it would take to get this implemented? I'm a fairly good developer, but new to localstack and serverless. I don't mind being a grease monkey / researching this more. Perhaps we could start a new issue and just and our notes and implementation research / details to it? I imagine the first task would be a yaml file that expresses the end goal of cognito emulation?

@m4-miranda
Copy link

I'd like to start development for this, as working with user pools on the cloud is turning out to be a bottleneck for my team.

Can anyone provide me with requirements or what I should start looking at?

@jagregory
Copy link

There'll be a lot to making a complete local Cognito. Off the top of my head (based on my personal use-case):

  • An OAuth2 provider, that has a HTTP server that does redirects
  • User Pool emulation to create/manage users
  • Lambda triggers
  • SES notifications for registration codes etc

Other things I can think of:

  • Identity Pools
  • API Gateway Authorizers

@whummer
Copy link
Member

whummer commented Aug 24, 2019

Hi @csabakoncz @hassankhan @damianesteban @mattcarrier @msolimans @vincentsolutions @warnerpinz @pchaganti @ojurkiewicz @oleersoy @rcavezza @sahellebusch @jgissend10 @tim-xch4nge @aldarund @tillkuhn @imedmar @RyanFelt @holtc @ghost @hatityechindove @lwoodson @7hibault @jeffdoolittle @m4-miranda @jagregory

Initial support for Cognito has been added to the LocalStack Pro edition. 🎉 If you want to check it out, please head over to the website and sign up for private beta access: https://localstack.cloud

@mcandre
Copy link

mcandre commented Aug 13, 2021

Hi,

When will Cognito be added to the normal FOSS edition?

@thrau
Copy link
Member

thrau commented Oct 18, 2021

closing this issue for now, as cognito is available in pro, and adding cognito to the communtiy version is currently not on our roadmap (but may be in the future)

@thrau thrau closed this as completed Oct 18, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests