Skip to content
This repository has been archived by the owner on Feb 7, 2019. It is now read-only.

Validate and refresh OAuth access tokens to ensure the user can utilize cloud storage #487

Closed
linuxwolf opened this issue Jan 23, 2018 · 0 comments
Assignees
Labels
Milestone

Comments

@linuxwolf
Copy link
Contributor

linuxwolf commented Jan 23, 2018

In service to sync, timely updates of the account access rights are necessary. This involves verifying the OAuth access_token is present, current, and active by requesting current user profile information.

This is exposed to the rest of the extension internals as a token() method, does the following:

  • checks for the presence, expiration, and activeness of an access token

  • refreshes the access token if possible

  • caches updated access token, expiration time, and profile information

    • OPTIONAL alerts the rest of the extension of updated account details
  • returns the access token on success, or throws a AUTH error on failure

Checking the access token involves the following, marking for refresh if any fail:

  1. checks for the presence of a cached access token and expiration time
  2. checks the expiration time for the access token
  3. requests the user's current profile information to confirm the access token is still active

Refreshing the access token involves the following, throwing an AUTH error if any fail:

  1. Checks for the presence of a cached refresh token
  2. makes an OAuth token exchange request using the refresh token
  3. checks the newly acquired token is present, current, and active (as above)
@linuxwolf linuxwolf changed the title Implement "light" vs. "full" account signout Improved updating of account authorization and profile information Jan 24, 2018
@linuxwolf linuxwolf changed the title Improved updating of account authorization and profile information Improved updating of account access and profile information Jan 24, 2018
@linuxwolf linuxwolf added the backlog We have looked at and understand the issue. Prioritized with alignment to product initiatives. label Jan 24, 2018
@sandysage sandysage removed the backlog We have looked at and understand the issue. Prioritized with alignment to product initiatives. label Jan 24, 2018
@linuxwolf linuxwolf changed the title Improved updating of account access and profile information Validate and refresh OAuth access tokens to ensure the user can utilize cloud storage Jan 24, 2018
@sandysage sandysage added the backlog We have looked at and understand the issue. Prioritized with alignment to product initiatives. label Jan 24, 2018
@sandysage sandysage added to do and removed backlog We have looked at and understand the issue. Prioritized with alignment to product initiatives. labels Feb 8, 2018
@sandysage sandysage added this to the 0.1.7 milestone Feb 9, 2018
@linuxwolf linuxwolf added in progress We are actively working on it. and removed to do labels Feb 12, 2018
@ghost ghost removed the in progress We are actively working on it. label Feb 20, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

2 participants