litellm/tests/unit/proxy/agent_endpoints
yucheng-berri edf8d5c57e
fix(proxy): accept audience and public_key_url in litellm_jwtauth (#53288)
* fix(proxy): accept audience and public_key_url in litellm_jwtauth

general_settings.litellm_jwtauth rejected public_key_url and audience at startup with
"Invalid arguments provided", so the flat config shape published for Entra ID and Okta
gateway SSO could not boot. Both were read only from JWT_PUBLIC_KEY_URL and JWT_AUDIENCE.

They are now fields on LiteLLM_JWTAuth and the Rust JWT settings. They seed the global
validation path for tokens whose iss matches no issuers entry, take precedence over the
env vars, and each one falls back to its env var on its own. An empty value is refused at
startup instead of silently rejecting every token. The agent identity provider list reads
the same audience, so it agrees with what the gateway enforces.

* fix(proxy): refuse a null or URL-less global JWKS URL and audience in litellm_jwtauth

An os.environ/ reference to an unset variable resolves to null, which let
a config that names an audience boot with no audience check. A
public_key_url made only of commas and whitespace also passed startup and
left global JWT verification with no endpoint.

* test(proxy): sign the config JWKS rejection tokens inside the test

The parametrized tokens were signed at collection with a ten minute
expiry, so a late run would fail on expiry instead of on the audience or
signing key.
2026-11-21 10:51:37 -08:00
..
auth refactor(auth_cache): type auth cache keys and keep the cache always native (#51130) 2026-11-21 17:20:30 +09:00
__init__.py
test_a2a_endpoints.py feat(guardrails): reject requests that name an unregistered guardrail when reject_unregistered_guardrails is on (#53214) 2026-11-20 18:39:29 -08:00
test_a2a_version_e2e.py
test_agent_header_isolation.py
test_agent_headers.py feat(agents): support Databricks Agent Platform agents in the agent gateway (#45681) 2026-10-15 12:42:06 -07:00
test_agent_rbac.py
test_agent_registry.py
test_agent_search.py fix(proxy): treat empty agent and skill search embedding model as not configured (#49485) 2026-10-31 15:32:26 -07:00
test_databricks_oauth.py feat(agents): support Databricks Agent Platform agents in the agent gateway (#45681) 2026-10-15 12:42:06 -07:00
test_endpoints.py fix(proxy): accept audience and public_key_url in litellm_jwtauth (#53288) 2026-11-21 10:51:37 -08:00
test_identity.py
test_identity_store.py feat(db): route jwt provisioning writes through rust repositories (#52756) 2026-11-20 14:53:01 +09:00
test_kill_switch.py
test_managed_identity.py
test_model_list_helpers.py