Title: OIDC auth rejects Entra ID (Azure AD) tokens: username claims and top-level app roles unsupported · Issue #6630 · feast-dev/feast · GitHub
Open Graph Title: OIDC auth rejects Entra ID (Azure AD) tokens: username claims and top-level app roles unsupported · Issue #6630 · feast-dev/feast
X Title: OIDC auth rejects Entra ID (Azure AD) tokens: username claims and top-level app roles unsupported · Issue #6630 · feast-dev/feast
Description: Expected Behavior Feature-server OIDC auth (auth: type: oidc) authenticates tokens issued by Microsoft Entra ID (Azure AD), including client-credentials (app-only) tokens, and RoleBasedPolicy matches Entra app roles. Current Behavior Two...
Open Graph Description: Expected Behavior Feature-server OIDC auth (auth: type: oidc) authenticates tokens issued by Microsoft Entra ID (Azure AD), including client-credentials (app-only) tokens, and RoleBasedPolicy match...
X Description: Expected Behavior Feature-server OIDC auth (auth: type: oidc) authenticates tokens issued by Microsoft Entra ID (Azure AD), including client-credentials (app-only) tokens, and RoleBasedPolicy match...
Opengraph URL: https://github.com/feast-dev/feast/issues/6630
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"OIDC auth rejects Entra ID (Azure AD) tokens: username claims and top-level app roles unsupported","articleBody":"## Expected Behavior\n\nFeature-server OIDC auth (`auth: type: oidc`) authenticates tokens issued by Microsoft Entra ID (Azure AD), including client-credentials (app-only) tokens, and `RoleBasedPolicy` matches Entra app roles.\n\n## Current Behavior\n\nTwo independent Keycloak-shape assumptions in `sdk/python/feast/permissions/auth/oidc_token_parser.py` (unchanged 0.64.0 -> 0.65.0):\n\n1. `_extract_username_or_raise_error` requires `preferred_username` or `upn`. Entra client-credentials tokens carry neither, so every machine-to-machine caller fails with `AuthenticationError(\"Missing preferred_username or upn field in access token.\")`.\n2. Roles are extracted only from Keycloak's nested `resource_access.\u003cclient_id>.roles`. Entra emits app roles in the top-level `roles` claim, so roles are always `[]` and `RoleBasedPolicy` can never match.\n\n#4934 previously requested the roles half and was closed stale without a fix.\n\n## Steps to reproduce\n\n1. Configure the feature server with `auth: type: oidc` against an Entra ID tenant.\n2. Acquire a client-credentials token for an app registration granted an app role.\n3. Call any authenticated endpoint: the token is rejected at username extraction. With a user (auth-code) token, authentication passes but extracted roles are `[]`.\n\n### Specifications\n\n- Version: 0.64.0 (parser identical in 0.65.0)\n- Platform: Python feature server, Microsoft Entra ID (Azure AD)\n- Subsystem: `permissions/auth`\n\n## Possible Solution\n\n- Username: when the human claims are absent, fall back to the calling application's identity: `azp` (v2 tokens), then `appid` (v1), then `sub`.\n- Roles: merge the top-level `roles` claim with the existing `resource_access` extraction so both issuer shapes authorize.\n\nI'm taking this one: we already run 0.64 behind Entra with exactly this change applied as a build-time patch, and I'll submit it as a PR.\n","author":{"url":"https://github.com/larrysingleton007","@type":"Person","name":"larrysingleton007"},"datePublished":"2026-07-22T18:28:04Z","url":"https://github.com/feast-dev/feast/issues/6630"}
| react-profiling | 0 |
| react-import-map | react,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322 |
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:ee15ce27-2a3a-ab34-3567-efcd15b1ff4e |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | 8D9A:2A4404:F02145:13CBD87:6AFE9818 |
| html-safe-nonce | b1181b1dc62b80991ac7ee57d23f7af5ccd58b3bb728f3129ba5b5cd7ca92958 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiI4RDlBOjJBNDQwNDpGMDIxNDU6MTNDQkQ4Nzo2QUZFOTgxOCIsInZpc2l0b3JfaWQiOiI0Mzk3ODk3MzIxODkwODM2NzIiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ== |
| visitor-hmac | 05802b3b4694b42508026d29dfcea834ab05c1a68340e4a75cf143bf13909c19 |
| hovercard-subject-tag | issue:4951951355 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/feast-dev/feast/6630/issue_layout |
| twitter:image | https://opengraph.githubassets.com/ddf587bcdff537cfc4770e7808932d02a4ede004f636791d7f9228bc711021b1/feast-dev/feast/issues/6630 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/ddf587bcdff537cfc4770e7808932d02a4ede004f636791d7f9228bc711021b1/feast-dev/feast/issues/6630 |
| og:image:alt | Expected Behavior Feature-server OIDC auth (auth: type: oidc) authenticates tokens issued by Microsoft Entra ID (Azure AD), including client-credentials (app-only) tokens, and RoleBasedPolicy match... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | larrysingleton007 |
| hostname | github.com |
| expected-hostname | github.com |
| None | b3c0f155eafc27e60db6e254d1ffff0e072e9ab3b4018a5ee518797c19d89f86 |
| turbo-cache-control | no-preview |
| go-import | github.com/feast-dev/feast git https://github.com/feast-dev/feast.git |
| octolytics-dimension-user_id | 57027613 |
| octolytics-dimension-user_login | feast-dev |
| octolytics-dimension-repository_id | 161133770 |
| octolytics-dimension-repository_nwo | feast-dev/feast |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 161133770 |
| octolytics-dimension-repository_network_root_nwo | feast-dev/feast |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 4a10310af51a1bfffbedc4fd81cb582acf0cb0ff |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
| react-app-name | issues |
Links:
Viewport: width=device-width