question

SniperED007 avatar image
SniperED007 asked

PlayFabClientAPI.LoginWithGameCenter - signature does not match authentication request data

Using Unity 2020.1.8f1

TitleId: 7A936

On launching my game the Game Center login pops up correctly, I seem to get all the details correctly (key, signature, salt, timestamp), but then when calling PlayFabClientAPI.LoginWithGameCenter it throws the following error:

"signature does not match authentication request data"


Any ideas where to look?

I've used this before for another project that worked a few months back and the code is pretty much identical except of course the TitleId. So not sure what I'm doing wrong.

The iOS Bundle Id in my Unity Player Settings matches the one in PlayFab Apple AddOns.

Not sure what other steps need to be done?

Authentication
1 comment
10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Rick Chen avatar image Rick Chen ♦ commented ·

Thank you for reporting this issue. We will set up environments and reproduce this issue as you described. I will keep this thread updated when there is feedback. Your patience is appreciated and please stay tuned.

0 Likes 0 ·
Rick Chen avatar image
Rick Chen answered

We tested it in Unity, it worked and we cannot reproduce the issue you described. The issue could be associated with iOS Authentication server. Since there was no issue in our test, it could be fixed before we do the test. Could you please try again and see how it goes? If you still experiencing the issue, please let us know.

2 comments
10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

SniperED007 avatar image SniperED007 commented ·

Thanks for checking,
I tried again but it still throws the same error.

0 Likes 0 ·
Rick Chen avatar image Rick Chen ♦ SniperED007 commented ·

Since we cannot reproduce this issue, it could be your local issue of either environment or code. As you mentioned, the one of your old title with the same code works. To determine whether it is an environment issue or code issue, could you please create a new project to see if it still produce the same issue? If it is still producing the same issue, meaning it could be a code issue, then could you please provide a code snippet of how the key, signature, salt, timestamp are obtained and how PlayFabClientAPI.LoginWithGameCenter is used? Then we will diagnose it and give you feedback.

0 Likes 0 ·
SniperED007 avatar image
SniperED007 answered

I think this may be an issue with Game Center changing the UserId to use TeamPlayerId which was introduced in Unity 2020.1.

Can you please confirm that it works for you in Unity 2020.1 or above for your environment so I can at least rule it out as this being the issue or not.

"Unity 2020.1

Added GameID to the Social API it will return GamePlayerID when using GameCenter
Social.localUser.ID will return the TeamPlayerID instead of GameCenterUsersID on iOS 12 and above"
10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Jeremy Rose avatar image
Jeremy Rose answered

The issue I ran into is that if the account is created with the old id. It will not authenticate with the new id. Even if they are the same account. I had to rebind gamecenter using the new methods values.

10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.