8000 Adding Origin, as required by spec. https://tools.ietf.org/html/rfc6… · coderGods/arduinoWebSockets@10a8d3c · GitHub
[go: up one dir, main page]

Skip to content

Commit 10a8d3c

Browse files
committed
Adding Origin, as required by spec. https://tools.ietf.org/html/rfc6455#section-1.6
1 parent 4f55c36 commit 10a8d3c

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/WebSocketsClient.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -393,8 +393,9 @@ void WebSocketsClient::sendHeader(WSclient_t * client) {
393393

394394
String handshake = "GET " + client->cUrl + " HTTP/1.1\r\n"
395395
"Host: " + _host + ":" + _port + "\r\n"
396-
"Upgrade: websocket\r\n"
397396
"Connection: Upgrade\r\n"
397+
"Upgrade: websocket\r\n"
398+
"Origin: file://\r\n"
398399
"User-Agent: arduino-WebSocket-Client\r\n"
399400
"Sec-WebSocket-Version: 13\r\n"
400401
"Sec-WebSocket-Key: " + client->cKey + "\r\n";

0 commit comments

Comments
 (0)
0