Antalya 26.5: Token Authentication and Authorization#1959
Open
zvonand wants to merge 4 commits into
Open
Conversation
…next commit) --- Original cherry-pick message follows: Merge pull request #1430 from Altinity/backports/antalya-26.1/1078 26.1 Antalya: Token Authentication and Authorization # Conflicts: # ci/jobs/scripts/check_style/aspell-ignore/en/aspell-dict.txt # src/Access/AccessControl.h # src/Access/Authentication.cpp # src/Access/IAccessStorage.cpp # src/Access/UsersConfigParser.cpp # src/Server/TCPHandler.cpp # src/configure_config.cmake
Adapted `Authentication::areCredentialsValid` return type: antalya-26.5 changed the return type from `bool` to `CredentialsCheckResult`, so `return false` in the source PR's `TokenCredentials` handling was adapted to `return CredentialsCheckResult::Fail` and the `bool` result of `checkTokenCredentials` was wrapped with a ternary. Adapted `UsersConfigParser::parseUserAuthMethod`: antalya-26.5 refactored the function to use `auth_method_path` prefix and return `AuthenticationData` instead of writing directly to `user->authentication_methods`. The new `has_jwt` branch from the source PR was adapted to use `auth_data` and `auth_method_path` accordingly. Adapted `TCPHandler::receiveHello`: antalya-26.5 added `socket().peerAddress()` as an extra argument to the regular `session->authenticate` call; the source PR's JWT branch (which uses the credentials overload) needed no change. Kept both `REQUIRED_SECOND_FACTOR` and `AUTHENTICATION_FAILED` in `IAccessStorage.cpp` (both error codes are used in the file). Kept both `scope_guard.h` and `AuthenticationType.h` includes (both used). Kept both `allow_impersonate_user` and `enable_token_auth` member variables in `AccessControl.h` (independent additions from different branches).
…next commit) --- Original cherry-pick message follows: Merge pull request #1784 from Altinity/fix/antalya-26.3/oauth-fix-azure [WiP] Antalya 26.3: OAuth -- rework Entra ID workflow # Conflicts: # src/Access/TokenAccessStorage.cpp # src/Access/TokenProcessors.h # src/Access/TokenProcessorsOpaque.cpp # src/Access/TokenProcessorsParse.cpp
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Changelog category (leave one):
Changelog entry (a user-readable short description of the changes that goes to CHANGELOG.md):
Introduce token-based authentication and authorization (#1430 by @zvonand, #1784 by @zvonand).
CI/CD Options
Exclude tests:
Regression jobs to run:
Combined port of 2 PR(s) (group
pr-1784). Cherry-picked from #1430, #1784.