Add Steam ticket auth for auth=steam HTTP requests#158
Open
Ash-bass wants to merge 1 commit into
Open
Conversation
Made-with: Cursor
Author
|
The main purpuse of this is locking content download behind and auth, so with the steam ticket, server can verify its legitimacy, and then provide specific content to an user or group of users based on steam id, but ye can be used for multiple things. P.S: This is my first pull request — please excuse any inconvenience. Feedback is welcome. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds support for Steam-authenticated HTTP requests. When a URL includes auth=steam, the client sends the user's Steam session ticket in the Authorization header so the server can verify the request. This works for downloads, API calls, and any other HTTP request that goes through the shared web client (e.g. content downloads, server content, metadata fetching).
Changes:
a4f081c:
SteamTicketProvider.cs(new) obtains Steam session ticket viaGetAuthSessionTicketand exposesUrlRequiresSteamTicket()to detectauth=steamin URLs.CookieAwareWebClient.csadds Steam ticket injection inGetWebRequest, settingAuthorization: Bearer <hex-ticket>when the URL containsauth=steam.AcManager.Tools.csprojadds compile include forSteamTicketProvider.cs.