Use Firebase authentication in aws services - amazon-web-services

I am using firebase auth as a authentication service in my app.
and using dynamoDB,S3 and other AWS services.Now the problem is that I want to restrict file uploadation to s3 from only firebase authenticated user..How to achieve this?
Please Help

Ensure the user is logged in with firebase auth https://firebase.google.com/docs/auth/web/start
Then if logged in you can allows s3 uploads.
Without seeing the code to your app you will have to design the solution yourself using these basic guidelines.

Related

migrate user sessions to cognito

This is my first stack overflow question. I have an in-house written OAuth backend serving for my application. I have migrated all the users from my backend to Cognito using the user migration Lambda trigger. The problem is that they are a few other services that are already linked and are using the existing backend to authenticate and needed to be to migrate to Cognito without forcing them to log out and log in. is there a way? If yes, let me know. Thanks

How to use AWS Amplify GraphQL APIs if I have access token of a logged in user?

I am completely new to Amplify library. I have logged in my user using Cognito User Pool. I have the required access token (jwt token). How should I go about using AWS Amplify APIs for GraphQL using this access token?
Amplify.API.query
Amplify.API.mutate
Reading the documentation, it seems to me I have to login user using Amplify Auth only to use these APIs. In other words, how do I let Amplify know that I have access token of an authenticated user and allow me to use GrapQL APIs? Or authentication via Amplify Auth is the only way?
Amplify will handle this for you out-of-the-box.
After you authenticate the framework will take care of handling the JWT for you. If you want to see an easy enough implementation of authentication with Cognito + Amplify I recommend you this codebase:
https://www.amplifyauth.dev
https://github.com/dabit3/amplify-auth-demo
After you have configured Amplify Auth and you create APIs using the Amplify CLI you'll be prompted if you want to create an authenticated or unauthenticated API.
On the client side, you'll just call the APIs using the Amplify JS library and the fact that you're authenticated or unauthenticated will be handled for you.

Can we authenticate application user with on-premise directory services with AWS Lambda?

Am looking for authentication methods with our on-premise directory other than AWS Cognito user pool. I saw Lambda can be integrated with Azure AD. Our directory is SAML integrated. Can i achieve this with AWS Lambda function.? And how can i get access tokens to authorize API Gateway after authentication. If Possible, Please let me know how to achieve. Thanks in Advance.

Can I use Cognito for users authentication in an app hosted in DigitalOcean?

I have an app hosted in a DigitalOcean server that is only used by me. Now I would like to give access to some friends, so I need users authentication management.
I have read AWS Cognito is a good option however it is not clear to me if it is possible to implement only AWS Cognito to work in joint cooperation with other services or if I need to migrate all to AWS to be able to use Cognito. I’ve been looking for tutorials but all talk about using Cognito in addition to other AWS services.
The point is that I’m using a Postgres DB and looking at AWS prices it is expensive to me to migrate to AWS. In case it is to do what I would like, I really appreciate recommended lectures.
Thanks in advance.
I need users authentication management.
I have read AWS Cognito is a good option
Indeed the AWS Cognito is a good option for user authentication and authorization. If you have a web app, you may as well check out the AWS amplify framework for easier onboarding.
if it is possible to implement only AWS Cognito
You don't need to use any other AWS services or migrate your infrastructure. Your application can use Cognito indepently.
You can use Cognito even as a pure OAuth 2.0 based authentication and authorization service if you want to keep really independent.
all talk about using Cognito in addition to other AWS services
Cognito can provide its users session (temporary) aws credentials to use AWS services. You don't have to use the feature if you don't need to.

AWS Cognito as Django authentication back-end

Does it make sense to attempt to use AWS Cognito as a Django authentication back-end? What would be the advantages of doing so? What would be some challenges / problem areas?
Has anyone done any work in this direction?
It depends a bit on what your goal is for it as a back end. Cognito Identity doesn't currently manage users or user registration...etc. It leverages public providers (e.g. Twitter, Facebook, Digits, Google, Amazon...etc.) to get AWS credentials to access other AWS resources.
What were you hoping to do with this backend?
EDIT: As is commented below, the new Cognito User Pools feature allows this to happen.