SDK pour Unity / Authentification silencieuse via la plateforme de publication
  Retour à la documentation

SDK pour Unity

Authentification silencieuse via la plateforme de publication

Silent authentication allows users to log into you application without having to enter their credentials again. With this type of authentication, the Xsolla Login server uses the credentials that the user provided on the application’s publishing platform.

Note
Silent authentication is currently supported for the Steam, Xbox Live and Epic Games platforms. If you need support for the Stone or Mail.ru platforms, contact your Account Manager.

To implement silent authentication via the publishing platform:

  1. Set up the application in the platform developer account.
  2. Set up silent authentication in Publisher Account.
  3. Complete integration steps on your application’s side.

Configurer l'authentification silencieuse

In the Login product, two approaches to enabling silent authentication are implemented:

Note
The shadow Login project is required to create cross-platform accounts that allow users to play on different platforms under the same account, sync their inventory across platforms, etc. A shadow Login project is created for each publishing platform that hosts the game and is then tied to the main account of the user. See Cross-platform account for details.

In the classic login option, you can enable silent authentication for several publishing platforms at once, but creating a cross-platform account is not possible. If a user logs into a game on one platform and then on another, the Login product will consider these logins as two different users.

To enable silent authentication in the classic login option:

  1. Open your project in Publisher Account and go to the Login section.
  2. Click Configure in the panel of a classic login option.
  3. On the navigation page, go to the Authentication block and select the Publishing platforms section.

  1. To connect a publishing platform, click the ⚙ icon next to its name and select Settings.
  1. In the modal window, specify the parameters for the selected platform:
    • Steam:
      • Application ID — AppID of your account on the platform;
      • Application secret keyWeb API Key.
    • Epic Games:
      • Application ID — Client ID of the client of your game on the platform;
      • Application secret key — Secret key of the client of your game on the platform.
    • Xbox Live:
      • Application ID — Application ID/Client ID of your game on the platform;
      • Application secret key — Application Secret generated when your game was registered on the platform.
Note
For the Xbox Live platform, it is not necessary to provide setting values. You can connect Xbox Live with access keys owned by Xsolla. To do this, click the ⚙ icon to the right of the platform name and select Connect.
  1. Click Connect.
  2. Repeat steps 4 – 6 for other publishing platforms, if required.

Intégration côté application

  1. Integrate the publishing platform SDK into your application.
  2. Implement the logic of obtaining the session ticket:
  1. Implement user authentication logic using SDK methods:
    • SilentAuth — exchanges the session ticket from the publishing platform to JSON Web Token (JWT) and authenticates the user.
    • OAuthLogout — ends the active user session.
Note
Silent authentication via Steam is implemented in the demo project. You can use the SteamAuth.cs class as an example. If you use the demo project as the initial version of the authentication system, you can set up silent authentication via Steam by following the How to set up native authentication via Steam guide.
Cet article vous a été utile ?
Merci !
Que pouvons-nous améliorer ? Message
Nous sommes désolés de l'apprendre
Dites-nous pourquoi vous n'avez pas trouvé cet article utile. Message
Merci pour votre commentaire !
Nous examinerons votre message et l'utiliserons pour améliorer votre expérience.
Évaluer cette page
Évaluer cette page
Que pouvons-nous améliorer ?

Préfère ne pas répondre

Merci pour votre commentaire !

Liens utiles

Dernière mise à jour: 10 Octobre 2023

Faute de frappe ou autre erreur dans le texte ? Sélectionnez le texte concerné et appuyez sur Ctrl+Entée.

Signaler un problème
Nous améliorons continuellement notre contenu grâce à vos commentaires.
Indiquez votre adresse e-mail pour un suivi
Merci pour votre commentaire !