goto bail;
}
+ if (wsi->utf8_token[WSI_TOKEN_EXTENSIONS].token_len) {
+ fprintf(stderr, "extensions not supported\n");
+ goto bail;
+ }
+
if (wsi->utf8_token[WSI_TOKEN_KEY].token_len >=
MAX_WEBSOCKET_04_KEY_LEN) {
fprintf(stderr, "Client sent handshake key longer "
[WSI_TOKEN_KEY2] = { "Sec-WebSocket-Key2:", 19 },
[WSI_TOKEN_PROTOCOL] = { "Sec-WebSocket-Protocol:", 23 },
[WSI_TOKEN_UPGRADE] = { "Upgrade:", 8 },
+ [WSI_TOKEN_EXTENSIONS] = { "Sec-WebSocket-Extensions:", 25 },
[WSI_TOKEN_ORIGIN] = { "Origin:", 7 },
[WSI_TOKEN_DRAFT] = { "Sec-WebSocket-Draft:", 20 },
[WSI_TOKEN_CHALLENGE] = { "\x0d\x0a", 2 },
case WSI_TOKEN_VERSION:
case WSI_TOKEN_ACCEPT:
case WSI_TOKEN_NONCE:
+ case WSI_TOKEN_EXTENSIONS:
case WSI_TOKEN_HTTP:
debug("WSI_TOKEN_(%d) '%c'\n", wsi->parser_state, c);