Skip to content

Add configurable model endpoint identity header for APIM policies #1250

Description

@Bionic711

Summary

Add an admin-configurable model endpoint identity header that sends a stable, non-reversible per-user key with outbound model endpoint calls.

User Value

APIM and backend policies need a consistent user-specific value for counters, quotas, routing, and throttling without exposing raw user identifiers such as UPN, object ID, or tenant ID.

Proposed Behavior

  • Admins can enable or disable the header globally.
  • Admins can customize the header name while blocking reserved auth/protocol headers.
  • Admins can choose the identity input used for the HMAC: UPN, UPN + tenant ID, object ID, or object ID + tenant ID.
  • Individual model endpoints can inherit, force-enable, force-disable, or override header name/value behavior.
  • SimpleChat sends only an HMAC-SHA256 digest, never raw user identity values.
  • Background/workflow calls use the owning or initiating user where available; otherwise the header is omitted.

Acceptance Criteria

  • Global admin settings control header enablement, name, and identity value type.
  • Per-endpoint overrides are saved and applied at runtime.
  • Configured model endpoint calls and legacy GPT/APIM model calls include the header when enabled and identity values are available.
  • Reserved headers cannot be used as the custom identity header name.
  • Functional and UI coverage validate HMAC stability, privacy, disablement, override behavior, and endpoint override serialization.
  • Feature documentation explains setup, APIM usage, and limitations.

Notes

Implementation is underway in the current working branch for version 0.250.186.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

enhancementNew feature or requestsecurity_improvementThis issue results in an improvement to security

Type

No type

Projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions