-
Notifications
You must be signed in to change notification settings - Fork 3.6k
Add docs for refresh-token support to OAuth2 #13009
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Praveen2112
merged 1 commit into
trinodb:master
from
Praveen2112:praveen/docs/refresh_token
Jul 14, 2022
Merged
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -114,6 +114,47 @@ The following configuration properties are available: | |
| * - ``http-server.authentication.oauth2.groups-field`` | ||
| - The field of the access token used for Trino groups. The corresponding claim value must be an array. | ||
|
|
||
| Refresh tokens | ||
| ^^^^^^^^^^^^^^ | ||
|
|
||
| In order to start using refresh tokens flows, the following property must be | ||
| enabled in the coordinator configuration. | ||
|
|
||
| .. code-block:: properties | ||
|
|
||
| http-server.authentication.oauth2.refresh-tokens=true | ||
|
|
||
| Additional scopes for offline access might be required, depending on | ||
| IdP configuration. | ||
|
|
||
| .. code-block:: properties | ||
|
|
||
| http-server.authentication.oauth2.scopes=openid,offline_access [or offline] | ||
|
|
||
| The following configuration properties are available: | ||
|
|
||
| .. list-table:: OAuth2 configuration properties for refresh flow | ||
| :widths: 40 60 | ||
| :header-rows: 1 | ||
|
|
||
| * - Property | ||
| - Description | ||
| * - ``http-server.authentication.oauth2.refresh-tokens.issued-token.timeout`` | ||
| - Expiration time for issued token. Value must be less than or equal to | ||
| the duration of the refresh token expiration issued by the IdP. | ||
| Defaults to ``1h``. | ||
| * - ``http-server.authentication.oauth2.refresh-tokens.issued-token.issuer`` | ||
| - Issuer representing the coordinator instance, that is referenced in the | ||
| issued token, defaults to ``Trino_coordinator``. The current | ||
| Trino version is appended to the value. This is mainly used for | ||
| debugging purposes. | ||
| * - ``http-server.authentication.oauth2.refresh-tokens.issued-token.audience`` | ||
| - Audience representing this coordinator instance, that is used in the | ||
| issued token. Defaults to ``Trino_coordinator``. | ||
| * - ``http-server.authentication.oauth2.refresh-tokens.secret-key`` | ||
| - Base64-encoded secret key used to encrypt the generated token. | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. By default it's generated during startup.
Member
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Added them |
||
| By default it's generated during startup. | ||
|
|
||
|
|
||
| Troubleshooting | ||
| --------------- | ||
|
|
||
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These 3 properties have default values as well so it's probably worth documenting it.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Added them