Skip to content

Add oauth login functionality - #211

Merged
rossengeorgiev merged 4 commits into
ValvePython:masterfrom
melvyn2:master
Sep 30, 2020
Merged

Add oauth login functionality#211
rossengeorgiev merged 4 commits into
ValvePython:masterfrom
melvyn2:master

Conversation

@melvyn2

Copy link
Copy Markdown
Contributor

Because we have access to creating OAuth tokens, I thought it might be useful to use them to log in more easily. If any code style changes/refactoring needs to be done, I'd be happy to do it.

Comment threadsteam/webauth.py Outdated
Comment threadsteam/webauth.py
Comment threadsteam/webauth.py Outdated
@rossengeorgiev

Copy link
Copy Markdown
Member

If I understand this correctly, once I login with mobileauth (user+pass etc) I get oauth_token that I can use with the API to re-authenticate at a future time? And I need to know the correct steam_id? (its not provided by GetGWToken?)

@melvyn2

Copy link
Copy Markdown
ContributorAuthor

Yes; once you have a token, you can use it until it gets revoked (which seems to be random). Then, you must get a new one, which does require the username and password. The steam_id is also required. I believe I have also fixed all the notes above.

@rossengeorgiev

Copy link
Copy Markdown
Member

Thanks. I will need to try this out and figure out how this would fit in the class. Wondering whether it might better to implement it as a "remember password" feature.

@rossengeorgiev

Copy link
Copy Markdown
Member

Sorry, this PR has been sitting for a while. Happy to merge

@melvyn2

Copy link
Copy Markdown
ContributorAuthor

Ah, sorry for the delay: I've rebased the branch onto master. Does anything else need to be done before merging?

Comment threadsteam/webauth.py Outdated
Comment threadsteam/webauth.py
@melvyn2

Copy link
Copy Markdown
ContributorAuthor

Alright, I've managed to fetch and confirm mobile confirmations w/o the steamid cookie, and verified that the cookie is not present on the desktop site (mobile may still have it, but I don't see why it would). Should the commits be squashed, or left as-is?

@sonarqubecloud

Copy link
Copy Markdown

Kudos, SonarCloud Quality Gate passed!

BugA0 Bugs
VulnerabilityA0 Vulnerabilities (and Security Hotspot0 Security Hotspots to review)
Code SmellA0 Code Smells

No Coverage information No Coverage information
No Duplication information No Duplication information

@rossengeorgiev
rossengeorgiev merged commit 6f955c4 into ValvePython:masterSep 30, 2020
tomprince pushed a commit to tomprince/steam that referenced this pull request Feb 11, 2021
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants

@melvyn2@rossengeorgiev