diff options
author | Chris Wheeler <grintor@gmail.com> | 2021-03-29 15:19:06 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-03-29 15:19:06 -0400 |
commit | 331d601eb599a5a7be7588c98fa2da9d23fa89c5 (patch) | |
tree | d6bbae87796dff5407c14b5029242a9ac7b337f3 | |
parent | 5ac7b3e3915621682212d84dd9b7d9a6fabf7221 (diff) | |
download | websocket-client-331d601eb599a5a7be7588c98fa2da9d23fa89c5.tar.gz |
Add support for permitting additional values in the "upgrade" and "connection" headers (#627)
-rw-r--r-- | websocket/_handshake.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/websocket/_handshake.py b/websocket/_handshake.py index 6c93f7c..1876919 100644 --- a/websocket/_handshake.py +++ b/websocket/_handshake.py @@ -177,8 +177,8 @@ def _validate(headers, key, subprotocols): r = headers.get(k, None) if not r: return False, None - r = r.lower() - if v != r: + r = [x.strip().lower() for x in r.split(',')] + if v not in r: return False, None if subprotocols: |