Skip to content

feat(backendAuth): support injecting multiple secret-sourced headers#2316

Draft
yordis wants to merge 1 commit into
agentgateway:mainfrom
yordis:yordis/fixes-2248
Draft

feat(backendAuth): support injecting multiple secret-sourced headers#2316
yordis wants to merge 1 commit into
agentgateway:mainfrom
yordis:yordis/fixes-2248

Conversation

@yordis

@yordis yordis commented Jun 25, 2026

Copy link
Copy Markdown

Closes #2248

  • Real-world upstreams (Datadog DD-API-KEY + DD-APPLICATION-KEY, Cloudflare account-scoped tokens, etc.) require more than one secret-sourced header per request, and backendAuth currently supports only one.
  • The existing escape hatches each carry an unacceptable cost: inline auth.key leaks credentials into git, traffic.transformation has no Secret access in its CEL context (and routing secrets through CEL widens the observability/logging surface), and extauthz/extproc add per-request RPC and a sidecar to operate just to inject static headers.
  • Keeping the new field orthogonal to the existing oneof preserves the one-line ergonomic shape for the 90% single-Authorization case while enabling N-header upstreams without sidecars.
  • Resolving Secret values controller-side keeps the runtime free of Kubernetes client wiring and matches how secretRef already works today.

Real-world upstreams (Datadog, Cloudflare scoped tokens, etc.) require more
than one secret header per request, but today only one Secret can be injected
via backendAuth.secretRef. The available escape hatches either commit secrets
to git, route them through CEL (widening the observability surface), or
require a sidecar.

Closes agentgateway#2248

Signed-off-by: Yordis Prieto <yordis.prieto@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

backendAuth: support injecting multiple secret-sourced headers per backend

1 participant