dev
-
amplify auth updateUserAttributes 후 currentAuthenticatedUser 갱신 안되는 문제dev/aws 2019. 7. 4. 16:13
updateUserAttributes 로 정보 업데이트를 하고 currentAuthenticatedUser 로 반환되는 user 정보에는 업데이트 전 데이터가 들어있음. Auth.currentAuthenticatedUser({ bypassCache: true }); Auth.currentAuthenticatedUser({ bypassCache: true }); 업데이트 후 위 코드 실행하여 변경된 user 조회 가능. https://github.com/aws-amplify/amplify-js/issues/2534 Updating user attributes does not update cached user data · Issue #2534 · aws-amplify/amplify-js Is your fea..
-
API Gateway 인증에 idToken, accessToken 차이dev/aws 2019. 5. 30. 11:26
https://stackoverflow.com/questions/50404761/aws-api-gateway-using-access-token-with-cognito-user-pool-authorizer AWS API Gateway - using Access Token with Cognito User Pool authorizer? I am configuring an app with various frontends (mobile and web apps) and a single API backend, powered by Lambda and accessed via AWS API Gateway. As I'm planning to use Cognito to authenticate and stackoverflow...
-
서버사이드(node)에서 cognito 이용한 인증 구현dev/aws 2019. 5. 29. 09:01
Cognito user pool on node lambda serverless implementation https://www.reddit.com/r/aws/comments/ak2r2k/cognito_user_pool_on_node_lambda_serverless/ cognito 의 adminXXX 를 사용 https://github.com/awslabs/cognito-proxy-rest-service https://medium.com/@franzwong/howto-implement-user-sign-up-and-login-with-aws-cognito-8330f771b671 https://medium.com/@franzwong/howto-grant-iam-role-to-cognito-authentica..
-
aws lambda layer 로 lambda 소스 다이어트dev/aws 2019. 5. 24. 11:02
aws 문서 - 계층 내 라이브러리 종속 항목들을 포함 https://docs.aws.amazon.com/ko_kr/lambda/latest/dg/configuration-layers.html NodeJS Runtime Environment with AWS Lambda Layers https://medium.com/@anjanava.biswas/nodejs-runtime-environment-with-aws-lambda-layers-f3914613e20e lambda 에서 사용하는 모듈들과 json 들을 layer 로 구성하여 lambda 업로드 소스를 최소화 가능.
-
promise return multiple valuesdev/web 2019. 5. 14. 11:01
https://stackoverflow.com/a/41382855/3543411 Can promises have multiple arguments to onFulfilled? I'm following the spec here and I'm not sure whether it allows onFulfilled to be called with multiple arguments. For example: promise = new Promise(function(onFulfilled, onRejected){ onFulfil... stackoverflow.com
-
cognito authenticateUser 후 User is not authenticated 문제dev/aws 2019. 5. 8. 17:51
cognito 를 사용하여 로그인을 처리한 후 다른 함수에서 cognito user 를 가져와 인증 후 가능한 기능(비밀번호 변경 등) 사용시 제목과 같은 에러가 나온다 var userPool = new AmazonCognitoIdentity.CognitoUserPool(poolData); var cognitoUser = userPool.getCurrentUser(); 위의 경우 생성된 cognitoUser 는 authenticateUser 호출로 반환되는 토큰을 가지고 있지 않는다. 이어서 cognitoUser 에 getSession 을 호출하여 기존 세션 정보를 user 에게 할당을 하면 정상적으로 동작한다. 참고 https://github.com/amazon-archives/amazon-cognit..