Repository navigation
Add jwt auth keycloak provider - #72978
Merged
vincbeck merged 4 commits intoSep 14, 2026
Merged
Conversation
…ow authentication method. Closes apache#72903
vincbeck
approved these changes
Sep 11, 2026
vincbeck
reviewed
Sep 11, 2026
Contributor
|
CI is failing |
dlactin
force-pushed
the
feat/add-jwt-auth-keycloak-provider
branch
from
September 14, 2026 15:27
2c7ba36 to
b82f5da
Compare
dlactin
requested review from
Fokko,
Lee-W,
XD-DENG,
amoghrajesh,
ashb,
choo121600,
dheerajturaga,
ephraimbuddy,
gopidesupavan,
henry3260,
hussein-awala,
jason810496,
jedcunningham,
jscheffl,
kaxil,
o-nikolas,
pierrejeambrun,
potiuk,
rawwar,
shubhamraj-git and
uranusjr
as code owners
September 14, 2026 15:27
dlactin
force-pushed
the
feat/add-jwt-auth-keycloak-provider
branch
from
September 14, 2026 15:31
b82f5da to
2c7ba36
Compare
…nt caching, openapi spec, docs and fixed CI failures
dlactin
force-pushed
the
feat/add-jwt-auth-keycloak-provider
branch
from
September 14, 2026 15:57
2c7ba36 to
7933ba0
Compare
Contributor
Author
Apologies for the spam folks, rebased without including merge commits :( |
henry3260
removed request for
Fokko,
Lee-W,
XD-DENG,
amoghrajesh,
ashb,
bugraoz93,
choo121600,
dheerajturaga,
ephraimbuddy,
gopidesupavan,
hussein-awala,
jedcunningham,
jscheffl,
kaxil,
potiuk,
rawwar,
shubhamraj-git and
uranusjr
September 14, 2026 16:06
Member
|
rerun CI |
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.
What changed:
Added a new
urn:ietf:params:oauth:grant-type:jwt-bearergrant to the Keycloak auth manager's /auth/token endpoint (TokenJwtFederatedBody / create_jwt_federated_token), alongside a newjwt_federated_client_idsconfig option.It lets a client that already authenticated to Keycloak by some other means (e.g. a
Signed JWT - Federatedclient bound to an external OIDC identity provider such as a Kubernetes ServiceAccount issuer or AWS IAM outbound identity federation) exchange its Keycloak access token for an Airflow-minted JWT, without re-authenticating to Keycloak through Airflow.Why:
The existing
client_credentialsgrant requires a staticclient_secretper caller, and doesn't support multiple distinct client identities cleanly going forward (upstream hardening restricts it to a single configured client id).Machine identities that already prove themselves to Keycloak via a federated/no-static-secret mechanism had no way to obtain an Airflow API token. This grant closes that gap: Airflow verifies an already-issued Keycloak assertion (signature, issuer, aud) and authorizes the caller via a new
jwt_federated_client_idsallow-list keyed off the token's azp claim — fail-closed if unset.More details in #72903 if needed, but the core goal was to support temporary credentials to the Airflow API from external services using k8s service accounts.
How to test:
Signed JWT - Federatedauth.[keycloak_auth_manager]jwt_federated_client_ids.Signed JWT - Federatedflow for machine authentication to Airflow #72903Was generative AI tooling used to co-author this PR?
Generated-by: [GitHub Copilot] following the guidelines
{pr_number}.significant.rst, in airflow-core/newsfragments. You can add this file in a follow-up commit after the PR is created so you know the PR number.