PlayFab / PlayFabMultiplayerUnreal

PlayFab Online Subsystem Plugin for Unreal Engine
https://learn.microsoft.com/en-us/gaming/playfab/features/multiplayer/networking/party-unreal-engine-oss-overview
39 stars 35 forks source link

Rapid login attempts can create lingering/stale entries in pending authorization table. #42

Closed bwagstaff closed 1 year ago

bwagstaff commented 1 year ago

If users attempt to sign in before previous processing has completed, it is possible for multiple entries to be added to the list. The entries will remain indefinitely.

https://github.com/PlayFab/PlayFabMultiplayerUnreal/blob/d92f7103e256b24ea1d28f86f480cfecdb91cb8c/Source/Private/OnlineIdentityInterfacePlayFab.cpp#L409

Our change is to add:

const FString& userId = LocalUser->GetPlatformUserId();
if (!UsersToAuth.Contains(userId))
{
    UsersToAuth.Add(userId);
}
nassosterz-ms commented 1 year ago

Thank you for reporting this. The change looks good to me, I will pass it on to the people who are actively working in this codebase!

yuehanlin commented 1 year ago

Hello, the change looks good to me as well, and we will include the fix in future releases. I am going to close this issue, and please feel free to reopen if you have any concerns.