amazon-cognito

What is the REST (or CLI) API for logging in to Amazon Cognito user pools

╄→尐↘猪︶ㄣ 提交于 2019-12-18 11:05:51
问题 How do i make logins happen via Amazon Cognito REST APIs (for user pools) on platforms for which there is no official SDK? - Note that i am asking for user pools - not identity pools. Synopsis Amazon cognito provides 3 kinds of logins: federated logins (creates identity pools ) - using social connects like FB, Twitter, G+ etc AWS managed logins (creates user pools ) - using Amazon's own managed signup, signin, forgot password, reset password services developer provided logins (my custom

Serverless Framework with AWS cognito generates CORS error

霸气de小男生 提交于 2019-12-18 09:32:50
问题 I get this error message from the Angular frontend and I am not authorized to touch my lambda code: `Access to fetch at 'https://testapicd.***.***.com/localization/v1/role' from origin 'https://localization.test.***.***.com' has been blocked by CORS policy: No 'Access-Control-Allow-Origin' header is present on the requested resource. If an opaque response serves your needs, set the request's mode to 'no-cors' to fetch the resource with CORS disabled.` I have looked everywhere and there seems

AWS cognito: sign in with usernam/password OR facebook

血红的双手。 提交于 2019-12-17 18:58:34
问题 I want to integrate a pretty standard functionality: give option to user (mobile and web) to either login with email/password or with facebook (google) account with RBAC (different users may have different roles, like users, moderators, admins, creators, etc). Here is basically what I want from sign in: I went through a number of AWS tutorials and other materials. I got some grasp on how to implement it, but I still don't have a full picture. Hope someone can help me here. Here is my current

How to get user attributes (username, email, etc.) using cognito identity id

半城伤御伤魂 提交于 2019-12-17 17:54:35
问题 I have AWS Cognito Identity Pool that is configured with Cognito User Pool as an authentication provider. Assume I have identity ID of an identity in Cognito Identity Pool (e.g. us-east-1:XXaXcXXa-XXXX-XXXX-XXX-XXXXXXXXXXXX) where this identity has a linked login to a user in Cognito User Pool. Using identity ID, how can I get the linked user details (email, phone, username)? 回答1: The ID Token that you exchange with Cognito federated identity service to get the identity id and credentials

AWS Lambda API gateway with Cognito - how to use IdentityId to access and update UserPool attributes?

烂漫一生 提交于 2019-12-17 17:33:48
问题 OK I am now days into this and have made significant progress but am still completely stumped about the fundamentals. My application uses Cognito User Pools for creating and managing users - these are identified on S3 it seems by their IdentityId. Each of my users has their own S3 folder, and AWS automatically gives them a folder name that is equal to the user's IdentityId. I need to relate the IdentityId to the other Cognito user information but cannot work out how. The key thing I need is

AWS Cognito Swift credentials provider “logins is deprecated: Use AWSIdentityProviderManager”

∥☆過路亽.° 提交于 2019-12-17 13:26:23
问题 Im trying to allow users to sign up with my app using facebook and Amazon Cognito. I found previous documentation saying to use: let token = FBSDKAccessToken.currentAccessToken().tokenString var logins: NSDictionary = NSDictionary(dictionary: ["graph.facebook.com" : token]) credentialsProvider.logins = [AWSIdentityProviderFacebook: token] but I am getting the message that logins is deprecated and to use the protocol AWSIdentityProviderManager to provide logins to the credentials provider,

Restrict login to Enterprise Google Domain for AWS Federated Identity Pool

不羁的心 提交于 2019-12-14 04:16:42
问题 I'm using a federation identity pools with aws-amplify (https://aws.github.io/aws-amplify/media/authentication_guide#enabling-federated-identities) and I'd like to restrict the scope of domains to just my google domain organization (ex. johndoe@foobar.com). There doesn't seem to be a way to lock it down on either the Google API console or the AWS Cognito Identity Pool settings, just a hint that an hd parameter can be appended to the google request to restrict it by domain (which would still

AWS Using refresh token Javascript

倖福魔咒の 提交于 2019-12-14 03:23:30
问题 Are there any examples on how to use the refresh token to get a new idtoken on aws cognito? I´m trying to use http://docs.aws.amazon.com/cognito-user-identity-pools/latest/APIReference/API_AdminInitiateAuth.html But then, it requires "developer credentials". I think I was able to set that on Cognito following http://docs.aws.amazon.com/cognito/latest/developerguide/developer-authenticated-identities.html#associate-developer-provider Now I don´t know what else do I need to do on my code in

Switch from unauth to developer authenticated cognito user - AWS iOS SDK

╄→尐↘猪︶ㄣ 提交于 2019-12-13 20:57:29
问题 Overall Problem: I have a problem using a developer authenticated identity with my front end (iOS). I know my backend produces the correct token and identityID but my refresh method never gets called. I've also looked at the sample but I get slightly confused with everything going on. Flow Explanation: Currently I have a login screen that has a login button. The user presses the login button, then my api class takes the credentials, encrypts the password and stores it in keychain (commented

How to return response from cognito async function and display it on the page?

霸气de小男生 提交于 2019-12-13 18:26:25
问题 Given the code below, how will I output the response back on the webpage when the response is either success or fail? loginUser(data) { var authenticationData = { Username : data.email, Password : data.password }; var authenticationDetails = new AmazonCognitoIdentity.AuthenticationDetails(authenticationData); var userPool = new AmazonCognitoIdentity.CognitoUserPool(config.cognito); var userData = { Username : data.email, Pool : userPool }; var cognitoUser = new AmazonCognitoIdentity