question

ronaldjroy avatar image
ronaldjroy asked

LoginWIthSteam failed with WebAPI error: 102 (Ticket for other app),LoginWIthSteam failed with WebAPI error 102 (Ticket for other app)

I'm using Unreal Engine 4.11. It has a wrapper (GetAuthToken) for the GetAuthSessionTicket which converts the byte array into the expected string. I've also setup a callback for GetAuthSessionTicketResponse_t to verify that I'm waiting long enough. When I call LoginWithSteam, PlayFab returns me:

HttpStatus: BadRequest HttpCode: 400

ErrorName: InvalidSteamTicket ErrorCode: 1010

ErrorMessage: Steam WebAPI error: 102 (Ticket for other app)

After that I create a HTTP GET Request from:

http://api.steampowered.com/ISteamUserAuth/AuthenticateUserTicket/v1/?key=%s&appid=%d&ticket=%s

This returns me the expected JSON:

{ response: params: { result: OK, steamid: #####, ownersteamid: #####, vacbanned: false, publisherbanned: false } }

I've gone to the "Partner Add-ons->Steam" page and entered the "Steam Application ID" and "Steam Secret Key". These are the same values that I pass to "key" and "appid" within the Steam WebAPI request.

Is there something I'm missing, or is this a bug?

,

I'm using Unreal Engine 4.11. It has a wrapper (GetAuthToken) for the GetAuthSessionTicket which converts the byte array into the expected string. I've also setup a callback for GetAuthSessionTicketResponse_t to verify that I'm waiting long enough. When I call LoginWithSteam, PlayFab returns me:

HttpStatus: BadRequest HttpCode: 400

ErrorName: InvalidSteamTicket ErrorCode: 1010

ErrorMessage: Steam WebAPI error: 102 (Ticket for other app)

After that I create a HTTP GET Request from:

http://api.steampowered.com/ISteamUserAuth/AuthenticateUserTicket/v1/?key=%s&appid=%d&ticket=%s

This returns me the expected JSON:

{ response: params: { result: OK, steamid: #####, ownersteamid: #####, vacbanned: false, publisherbanned: false } }

I've gone to the "Partner Add-ons->Steam" page and entered the "Steam Application ID" and "Steam Secret Key". These are the same values that I pass to "key" and "appid" within the Steam WebAPI request.

Is there something I'm missing, or is this a bug?

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.

vethan avatar image vethan commented ·

Hey @Brendan Vanous, Looks like I'm having the exact same problem as Ronaldjroy. Passing my values in as a webrequest works fine, but apprently playfab's not happy with the setup.

,

I appear to be having the same problem as ronald, but using the Unity SDK. Passing in my values straing into a webcall works fine, but playfab doesn't work

0 Likes 0 ·
brendan avatar image
brendan answered

[Edit - we have since updated the add-on page for Steam to take the App ID in decimal format.]

Arg! Okay, my sincere apologies, guys - I should not have second-guessed my previous statement on this. It is indeed the Web API Key, available by going to Users & Permissions, selecting Manage Groups, select the group you'll be using for the title (or create one, if you don't have one set up), and in that group, generating a Web API Key (if you don't already have one there). That Key is what goes into the Add-ons page for Steam in PlayFab. The actual issue was much simpler, which is why it was harder to spot. The Steam App ID in the PlayFab Add-ons page is actually in hexadecimal format. I've corrected that for both your titles.

@vethan: I've tested, and your title works fine now.

@ronaldjroy: I'm still seeing the 102 error on your title with the corrected App ID. What I'd like to do is revoke your existing WebAPI Key and re-create it, then update the PlayFab setting for your title, to see if that fixes this. Is that okay with you?

6 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.

vethan avatar image vethan commented ·

Thanks a bunch @Brendan Vanous! This should probably get market as the answer for future searchers!

0 Likes 0 ·
brendan avatar image brendan vethan commented ·

Fair point - I'll do that. :)

0 Likes 0 ·
ronaldjroy avatar image ronaldjroy commented ·

Yes please.

0 Likes 0 ·
brendan avatar image brendan ronaldjroy commented ·

Okay, I've compared all elements of your title to multiple working titles, removed and re-created your WebAPI Key, and even tried adding a different Group in Steam to host the WebAPI Key, and the result is always the same. At this point, this appears to be an issue in Steam, so I've reached out to their team for assistance. I'll update as soon as I have any info from them.

0 Likes 0 ·
ronaldjroy avatar image ronaldjroy brendan commented ·

Everything is working now.

I'm not sure what's going wrong with your test, but I'm now getting a success to the LoginWIthSteam. This is visible on the players tab in the game manager.

0 Likes 0 ·
Show more comments
brendan avatar image
brendan answered

The auth token system for Steam hasn't changed as of 4.11, so we should look for other potential causes. The "Ticket for other app" error is specifically coming from the Steam service, so that's the place to start. What Title ID is this for? Can you add brendan@playfab.com to the permissions for your title in Steam, so that I can have a look? Alternately, do you have a repro sample you can send to us (at devrel@playfab.com)?

10 |1200

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

ronaldjroy avatar image
ronaldjroy answered

@Brendan Vanous: I've added you as a user to CE39. I noticed that the "Ticket for other app" is from Steam. This is why I made the GET Request to the webapi myself, to see if there was some other problem. But when I did that I got a success response back. I was able to reproduce the "Ticket for other app" by changing the appid in the parameters and by waiting for the auth token to expire. It's kind of hard to send a repro sample since the auth tokens expire.

I did go to the "try it" within docs for LoginWithSteam. I'd do the "try it", run the steam WebApi, then try the "try it" again. Both "try it" requests would show the "Ticket for other app" and the steam WebApi would give a succss response.

I fiddled with the auth token values just to see what would happen. If they aren't a real ticket you get a different error. If you change the appid you get the "Ticket for other app". I also tried changing the WebAPI key and that causes a completely different error. It's as if the AppId I provided is just being ignored.

As a side note, the title ID is just tied to my personal account for now. I'll be recreating it wants we get farther along.

10 |1200

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

brendan avatar image
brendan answered

I actually can access all the titles in our service (so that I can help folks), but what I can't see is the setup of your title in Steam. Could you add me to your project in Steamworks, so that I can have a look? The ID to add is playfab_brendan.

10 |1200

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

ronaldjroy avatar image
ronaldjroy answered

Sorry, I miss read your request. We've added you to the Steamworks. Please let me know if you need more details. I'm pretty sure we are in the same Slack team. I'm ron_empyrean. PM me if you need any specific details about the app, or other permissions.

10 |1200

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

brendan avatar image
brendan answered

@ronaldjroy: Unfortunately, you only gave me the base level access, so I can't see your users and permissions tab. I'll message you in Slack as well, but so that others are aware, without the admin privileges, Steam doesn't really provide anything useful about the configuration.

Can you both confirm that you're using the WebAPI key for the setup in PlayFab, as described in this post, and that you have added the game in question to the group in Steamworks? The page for this can be a little hard to find. https://community.playfab.com/questions/537/207484368-Failed-to-connect-to-Steam-WebAPI-ProtocolError.html

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.

vethan avatar image vethan commented ·

Added you as an admin ^^
But yeah the webapi key is set up all right. You can double check. And the fact that the call from playfab is reporting wrongappid means it must be going through somewhat.

0 Likes 0 ·
brendan avatar image
brendan answered

Thanks! Everything looks like it's configured correctly in CE39. How are you specifying the AppId on the client side - do you use a configuration file, or is it hard-coded into the executable? Can you double-check that it is set correctly?

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.

vethan avatar image vethan commented ·

[FYI, my case concerns F405] the appID is set correctly, I previously had everything working fine using GameSparks but moved across to playfab, so the call + info being passed should be fine

0 Likes 0 ·
ronaldjroy avatar image
ronaldjroy answered

I'm using the same WebAPI key in both my game test code and the PlayFab settings.

Before I posted this question I had attempted to first find an existing question/answer that would help. i.e. Ya I read through that post in hopes it would give me some insight into what is going wrong.

10 |1200

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

brendan avatar image
brendan answered

Ah! My sincere apologies, guys. I was also following that older reference, which is incorrect - I'll go fix it, as well. The correct thing to use is the Encrypted App Ticket Key. I've set it correctly in PlayFab for both your titles, but so others know, you need to go into your App, click on Edit Steamworks Settings, then click on Security->SDK Auth. That's where you'll find the correct key.

@vethan: I've updated your title with the correct key. Can you re-test?

@ronaldjroy: I don't have the necessary permissions to get to the SDK Auth settings in your app. Can you update your PlayFab settings and re-test?

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.

vethan avatar image vethan commented ·

No dice this time! The result has changed to: "PlayfabStatPlatform.PlayfabErrorHandler()::Steam WebAPI error: 0 ()::InvalidSteamTicket"

0 Likes 0 ·
ronaldjroy avatar image
ronaldjroy answered

When I test with that key I get:

BadRequest(400) - InvalidSteamTicket(1010): Steam WebAPI error: 0 ()

I've given you "Edit App Metadata" privlieges on the steamworks page. Hopefully that's enough to give you the access you need to verify.

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.