Privileges are based on multiple factors
The effective privileges of an XBOX services user are based on the following factors.- The subscription entitlements of that user
- The type of device that’s used to access XBOX services
- The app that’s currently running
- The parental controls that are applied to that user’s account
- The input (such as XBOX services suspensions) from online safety and enforcement moderators of XBOX services
Privileges are computed during authentication
XBOX services compute and issue the effective privileges of a user when the user signs in and is authorized to XBOX services. A user’s privileges are carried in the token that’s received at the time of authentication. Privileges are issued in a token claim.Privilege information in XBOX services
A user must access XBOX services for your client app to obtain that user’s privilege information as shown in the following screenshot.
Flow of a user’s privilege information
- The XBOX services client (on behalf of a title or app) requests a token from the XBOX Security Token Service (XSTS).
- XSTS returns a token for the requested relying party. XSTS then computes the privileges for all users in the request
and issues them a token claim. Requests from the client app include the following automated actions.
- The app calls XBOX services directly and includes the token in the authorization header of the request.
- XBOX services grant access to the requested feature (such as
XPRIVILEGE_MULTIPLAYER_SESSIONS) that’s based on the privileges in the token.
- XBOX services grant access to the requested feature (such as
- Alternatively, the app calls a relying party service that’s configured for SSO.
- The service includes the token that’s in the authorization header of the request.
If the partner SSO service provides an implementation of an XBOX services feature (for example, downloadable user-created content such as
XPRIVILEGE_USER_CREATED_CONTENT), the partner service uses the privileges that are in the token to grant access to the requested feature. - To decrypt and de-serialize XBOX services tokens, the partner service must be configured for SSO.
- For more information about this configuration, see XBOX services authentication for title services.
- The service includes the token that’s in the authorization header of the request.
If the partner SSO service provides an implementation of an XBOX services feature (for example, downloadable user-created content such as
[!NOTE] The client can use XBOX platform APIs to customize the user experience and drive resolution (such as upselling, parental override) before issuing requests to XBOX services.
- The app calls XBOX services directly and includes the token in the authorization header of the request.
- Partner services can make requests to XBOX services on behalf of users by using a delegated authorization token.
- If the request is for a feature that requires a specific privilege (such as
XPRIVILEGE_COMMUNICATIONS), the partner service must obtain a delegated authorization token for XBOX services on behalf of the user and include it in the authorization header of the request. - XBOX services grant access to the request feature that’s based on the user’s privileges.
- If the request is for a feature that requires a specific privilege (such as
Privileges in the user identity
Privileges are a claim in the user identity, and that claim contains the collection of the current effective privileges of the user as shown in the following header claim. If a privilege is in the collection, then the user is currently authorized to access the corresponding feature. If the privilege isn’t in the collection, then the user isn’t currently authorized. The effective privileges of a user are dynamic, and they depend on the following scenarios.- Any expired subscription entitlements
- Apps that are currently running
- All accounts signed in on the same client device
- Status of the client device
- Parental controls that are applied to that user’s account
- The input (such as XBOX services suspensions) from online safety and enforcement moderators
[!NOTE] When a user is authorized for a feature at a particular time, this doesn’t guarantee that the user is authorized to access the feature later. The privileges that are issued for the user are valid for the lifetime of the token that’s issued when the user is authenticated.
Privileges and privacy settings
Privileges determine if a user is authorized to access a feature of XBOX services or a third-party service. This is a coarse check. For example, privileges determine whether a user can use any voice chat communications, not just whether two users can chat with each other. For the social features of XBOX services, apps and services use the privacy service to determine with whom an action can be performed, based on the privacy settings of all users that are involved in the action. For example, it determines if the user can use voice chat with a target, based on the settings of the target (such as a Mute list or Avoid list). For more information about integrating with the privacy service, see Privacy and permissions.Privileges and content restrictions
Privileges don’t provide information about content rating. For more information about XBOX Requirements (XRs), see Policies and XBOX Requirements.See also
Policies and XBOX RequirementsXBOX services authentication for title services Game Services Sample
