test(proxy): cover a websocket bearer token with extra whitespace

The master-key acceptance test now also sends the key after a double space, so dropping the strip on the bearer token, or keeping its prefix, fails a test
This commit is contained in:
L4XB 2026-09-17 19:43:11 +02:00
parent 4147d2a55d
commit d3e4eaff0c
No known key found for this signature in database

View file

@ -8612,6 +8612,7 @@ async def test_websocket_auth_without_master_key_accepts_a_keyless_client(header
"headers",
[
pytest.param({"authorization": "Bearer sk-master-key"}, id="bearer token"),
pytest.param({"authorization": "Bearer sk-master-key"}, id="bearer token with extra space"),
pytest.param({"api-key": "sk-master-key"}, id="api-key header"),
pytest.param(
{"sec-websocket-protocol": "realtime, openai-insecure-api-key.sk-master-key"},