mirror of
https://github.com/BerriAI/litellm.git
synced 2026-10-05 02:41:56 +00:00
fix: use == instead of is for string comparison in master key check
This is backwards incompatible - the proxy will now correctly reject the default master key "sk-1234" in production, which may break setups relying on the default key.
This commit is contained in:
parent
e3fb50818c
commit
5e42d4b9d8
1 changed files with 1 additions and 1 deletions
|
|
@ -3094,7 +3094,7 @@ class ProxyConfig:
|
|||
)
|
||||
|
||||
if master_key is not None and isinstance(master_key, str):
|
||||
if master_key is "sk-1234":
|
||||
if master_key == "sk-1234":
|
||||
raise ValueError(
|
||||
f"LITELLM_MASTER_KEY is set to the default master-key granting proxy admin access, please change it to something stronger"
|
||||
)
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue