Repository navigation
ATLAS-5430: Add SPIFFE header authentication for service-to-service calls. - #786
Merged
Merged
Conversation
…alls. Align Atlas header pre-auth with Ranger by accepting configured SPIFFE ID headers (e.g. x-awc-source-workload-id) and using the service-account segment as the trusted-proxy principal when no username header is present. Co-authored-by: Cursor <cursoragent@cursor.com>
nixonrodrigues
force-pushed
the
ATLAS-5430
branch
from
October 16, 2026 10:51
54c6603 to
e645aa0
Compare
chaitalicod
reviewed
Oct 16, 2026
…fig. Comma-separated atlas.authentication.method.header.spiffe values were truncated when read via getString; use getStringArray and extend tests. Document properties and enable header-auth Docker settings for local E2E verification. Co-authored-by: Cursor <cursoragent@cursor.com>
mneethiraj
reviewed
Oct 16, 2026
mneethiraj
approved these changes
Oct 17, 2026
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.
Summary
Adds SPIFFE-based service-to-service authentication to Atlas header pre-authentication, aligned with Apache Ranger (RANGER-5700). Workloads can authenticate using HTTP headers such as x-awc-source-workload-id when a trusted proxy or service mesh forwards workload identity.
Introduces SpiffeIdUtil to validate SPIFFE IDs and extract the Kubernetes service-account segment as the principal.
Extends AtlasHeaderPreAuthFilter to resolve identity from username headers or configured SPIFFE headers (username takes precedence).
Documents the new property atlas.authentication.method.header.spiffe and adds Docker dev config plus a verification script.
Configuration
Example request
GET /api/atlas/v2/types/typedefs/headers HTTP/1.1
workload-id: spiffe://my-cluster/ns/service-namespace/sa/atlas-spiffe-test
roles: ROLE_ADMIN
Principal: my-service-sa. Authorization uses the roles header and existing Atlas authz policy.
Security note
Header authentication must only be enabled when Atlas is reachable only through a trusted proxy/gateway. Direct client access would allow identity spoofing via headers.
Test plan
SpiffeIdUtilTest / AtlasHeaderPreAuthFilterTest
Confirm basic auth still works (no regression)