This repository was archived by the owner on Oct 8, 2025. It is now read-only.
Commit f7e0264
committed
http: Fix WebSockets with Firefox
Firefox (134 at least) was unable to open a WebSocket connection to Unit
due to it sending a Connection header of
Connection: keep-alive, Upgrade
However in Unit we were expecting only a single value in the header.
Fix the 'Connection' parsing in nxt_h1p_connection() to address this.
We keep the check for 'close' basically the same as that really should
be the only value.
Then we check for both of 'keep-alive' and 'upgrade'.
Closes: #1547
Signed-off-by: Andrew Clayton <a.clayton@nginx.com>1 parent b4201ab commit f7e0264
1 file changed
+8
-6
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
759 | 759 | | |
760 | 760 | | |
761 | 761 | | |
| 762 | + | |
762 | 763 | | |
763 | 764 | | |
764 | 765 | | |
| |||
768 | 769 | | |
769 | 770 | | |
770 | 771 | | |
| 772 | + | |
| 773 | + | |
771 | 774 | | |
772 | | - | |
773 | | - | |
774 | | - | |
| 775 | + | |
| 776 | + | |
| 777 | + | |
775 | 778 | | |
| 779 | + | |
776 | 780 | | |
777 | | - | |
778 | | - | |
779 | | - | |
| 781 | + | |
780 | 782 | | |
781 | 783 | | |
782 | 784 | | |
| |||
0 commit comments