You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In WebSocketHandler.isWebsocketRequest there is a check for the connection upgrade, which is working well for Chrome and Opera, but my Firefox (version 133.0 snap) fails to connect due to sending keep-alive, Upgrade instead of the expected Upgrade.
Changing the first if-clause in isWebsocketRequest from
if (connection == null ||
!connection.equalsIgnoreCase(Util.HEADER_CONNECTION_VALUE)) {
to something like
if (connection == null ||
!connection.toLowerCase()
.contains(Util.HEADER_CONNECTION_VALUE.toLowerCase())) {
The code does look wrong, but there is a test case that verifies this here so I must have altered the code when integrating nanohttp code.
More importantly, it brings up an issue, because according to the spec, it should be a comma delimited list, but I believe this syntax is also correct:
Activity
robaho commentedon Dec 11, 2024
Thanks for reporting.
The code does look wrong, but there is a test case that verifies this here so I must have altered the code when integrating nanohttp code.
More importantly, it brings up an issue, because according to the spec, it should be a comma delimited list, but I believe this syntax is also correct:
so using getFirst() is not appropriate either.
robaho commentedon Dec 11, 2024
Ah, the test is broken, it isn't verifying the results!
[-]Firefox websocket upgrade test[/-][+]Firefox websocket upgrade request[/+]fix issue Firefox websocket upgrade request #12
robaho commentedon Dec 11, 2024
This has been fixed in version 1.0.11
smfgh commentedon Dec 12, 2024
thank you so much! :-)