Desktop should track oauth access token expiry and avoid returning expired tokens
Categories
(Firefox :: Firefox Accounts, enhancement)
Tracking
()
| Tracking | Status | |
|---|---|---|
| firefox149 | --- | fixed |
People
(Reporter: markh, Assigned: markh)
References
Details
(Whiteboard: [fxsync-])
Attachments
(1 external file)
We currently don't track expiry of oauth access tokens. The Rust component does and it seems to work fine, so let's start doing that in desktop too.
This isn't going to mean that people using the tokens can blindly assume they are good though - there are still reasons they will not be, including clock skew etc. So consumers must still know to handle a 401 and discard the token before asking for a new one - but this would mean they need to actually do that far less often.
Updated•9 months ago
|
| Assignee | ||
Comment 1•9 months ago
|
||
This just mirrors the strategy the Rust fxa component uses. The implementation is quite
simple because we were already storing cached tokens as an object (ie, as {token: 'xxx'}), so it's quite simple to add expiresAt` to that object without changing the format of the
cached data.
Updated•9 months ago
|
Updated•8 months ago
|
Description
•