Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Websocket-extension changes to permessage-deflate #371

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,7 @@ public static void addWebSocketUpgradeHeaders(AsyncHttpRequest req, String proto
final String key = Base64.encodeToString(toByteArray(UUID.randomUUID()),Base64.NO_WRAP);
headers.set("Sec-WebSocket-Version", "13");
headers.set("Sec-WebSocket-Key", key);
headers.set("Sec-WebSocket-Extensions", "x-webkit-deflate-frame");
headers.set("Sec-WebSocket-Extensions", "permessage-deflate");
headers.set("Connection", "Upgrade");
headers.set("Upgrade", "websocket");
if (protocol != null)
Expand Down Expand Up @@ -183,7 +183,7 @@ public static WebSocket finishHandshake(Headers requestHeaders, AsyncHttpRespons
String extensions = requestHeaders.get("Sec-WebSocket-Extensions");
boolean deflate = false;
if (extensions != null) {
if (extensions.equals("x-webkit-deflate-frame"))
if (extensions.equals("permessage-deflate"))
deflate = true;
// is this right? do we want to crap out here? Commenting out
// as I suspect this caused a regression.
Expand Down