mirror of
https://github.com/BerriAI/litellm.git
synced 2026-09-06 08:16:43 +00:00
A three-segment token presented while `general_settings.enable_jwt_auth` is unset is never treated as JWT-shaped, so it falls through to the virtual-key path and is rejected for not starting with 'sk-'. That reads as a missing key in the verification table and sends the operator off to inspect virtual keys, when the real cause is one missing config line. The rejection now names `enable_jwt_auth`, appended to the existing text so the Prometheus invalid-key filter and the admin UI keep matching what they match today. The hint claims only that the key is JWT-shaped. Segment count cannot tell a JWT from any other dotted credential, so asserting the key IS a JWT would swap one confident misdiagnosis for a narrower one. The enterprise gate on that same path raised a bare `ValueError`, which the terminal handler turns into a 401. Every sibling enterprise gate answers 403, and a 401 tells the client to retry with a better credential, which no credential can satisfy while the install is unlicensed. It now raises a 403 `ProxyException` like the SSO gate does. |
||
|---|---|---|
| .. | ||
| test_admin_viewer_handler_access.py | ||
| test_auth_checks.py | ||
| test_auth_exception_handler.py | ||
| test_auth_hot_path_network_requests.py | ||
| test_auth_utils.py | ||
| test_banned_params_extra_body.py | ||
| test_cli_auth.py | ||
| test_custom_auth_end_user_budget.py | ||
| test_handle_jwt.py | ||
| test_info_routes.py | ||
| test_litellm_license.py | ||
| test_login_utils.py | ||
| test_mcp_ip_filtering.py | ||
| test_model_checks.py | ||
| test_model_checks_fallbacks.py | ||
| test_multi_budget_windows.py | ||
| test_network.py | ||
| test_oauth2_proxy_hook.py | ||
| test_object_permission_loading.py | ||
| test_onboarding.py | ||
| test_organization_budget_enforcement.py | ||
| test_password_hashing.py | ||
| test_resolvers_exceptions.py | ||
| test_resolvers_models.py | ||
| test_resolvers_seam.py | ||
| test_resolvers_store.py | ||
| test_route_checks.py | ||
| test_router_override_fallback_auth.py | ||
| test_team_member_budget.py | ||
| test_unmapped_model_budget_enforcement.py | ||
| test_user_api_key_auth.py | ||