Gamelift with Apple Gamecenter and Google Play Services

0

Good day! I’m studying some solutions for my casual multiplayer game for mobile with Unreal Engine and I’m quite interested in GameLift. I’m studying the ways to authenticate and generate tokens for GameLift and I’m thinking in a way to automatic log in user when connected on Apple Gamecenter or Google Play Services. I’m seeing solutions with Cognito but I don’t have any way to connect with those services. How can I get this authentication cycle working, is it possible? Thanks!

질문됨 3년 전328회 조회
3개 답변
0
수락된 답변

Hey GeekFox,

Authentication is ideally handled on the client side or the game backend service; GameLift focuses on integration of game servers with cloud hosting solutions (e.g. EC2).

You could checkout GameSparks, which has out-of-the-box solution for Authentication with Apple [1] or Google Play: [2]

Alternativly, you could implement your own Authentication solution with Cognito.

  1. Create a Cognito user pool, identity pool and Apple/Google account, see: [3], [4]
  2. Call GetCredentialsForIdentity (Follow [5]) to get the auth tokens
  3. If you are using Lambda game backend service, use the auth token to authenticate API gateway calls [6] to Lambda
  4. Lambda will then make calls to GameLift, such as SearchGameSessions, StartMatchmaking, etc.
[1] https://docs.gamesparks.com/api-documentation/request-api/authentication/signinwithappleconnectrequest.html
[2] https://docs.gamesparks.com/api-documentation/request-api/authentication/googleplayconnectrequest.html
[3] https://docs.aws.amazon.com/cognito/latest/developerguide/apple.html
[4] https://docs.aws.amazon.com/cognito/latest/developerguide/google.html
[5] https://docs.aws.amazon.com/cognito/latest/developerguide/authentication-flow.html
[6] https://docs.aws.amazon.com/apigateway/latest/developerguide/apigateway-integrate-with-cognito.html
답변함 3년 전
0

Hey GeekFox,

Authentication is ideally handled on the client side or the game backend service; GameLift focuses on integration of game servers with cloud hosting solutions (e.g. EC2).

You could checkout GameSparks, which has out-of-the-box solution for Authentication with Apple: https://docs.gamesparks.com/api-documentation/request-api/authentication/signinwithappleconnectrequest.html or Google Play: https://docs.gamesparks.com/api-documentation/request-api/authentication/googleplayconnectrequest.html

답변함 3년 전
0

I’ve managed to solve it. I’m using playfab to store securely user data and from there I handle user creation on cognito and store login data. My game retrieve login data from there and login into cognito to get auth tokens. Everything is secured and handled by lambdas with authorizers so only playfab or my game can access cognito.

답변함 3년 전

로그인하지 않았습니다. 로그인해야 답변을 게시할 수 있습니다.

좋은 답변은 질문에 명확하게 답하고 건설적인 피드백을 제공하며 질문자의 전문적인 성장을 장려합니다.

질문 답변하기에 대한 가이드라인

관련 콘텐츠