-
Notifications
You must be signed in to change notification settings - Fork 18
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
rework the oauth2 code a bit and fix some bugs in it
1. Fix the check for expired token in default client. a. addded a helper for this: client_trait::is_token_expired_error() 2. (BREAKING) Change oauth2::Oauth2Type variants: a. Oauth2Type::AuthorizationCode is now a struct variant with a named field for the secret b. Oauth2Type::ImplicitGrant now does not take the client secret any more, since it was not ever actually needed or used 3. (BREAKING) Rename Authorization::from_access_token() to Authorization::from_long_lived_access_token() to reflect its more niche purpose, and has been marked deprecated. 4. Authorization::obtain_access_token() when currently holding a refresh token will retain the refresh token. There was previously a bug where it would switch to only being a short-lived token with no way to refresh. Thanks to @dennishall3 and Julian Aichholz (@rusty-jules) for their contributions to reporting and investigating these issues.
- Loading branch information
Showing
6 changed files
with
104 additions
and
47 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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