Home | History | Annotate | Download | only in websockets
      1 // Copyright 2013 The Chromium Authors. All rights reserved.
      2 // Use of this source code is governed by a BSD-style license that can be
      3 // found in the LICENSE file.
      4 
      5 #include "net/websockets/websocket_handshake_constants.h"
      6 
      7 namespace net {
      8 namespace websockets {
      9 
     10 const char* const kHttpProtocolVersion = "HTTP/1.1";
     11 
     12 const size_t kRawChallengeLength = 16;
     13 
     14 const char* const kSecWebSocketProtocol = "Sec-WebSocket-Protocol";
     15 const char* const kSecWebSocketExtensions = "Sec-WebSocket-Extensions";
     16 const char* const kSecWebSocketKey = "Sec-WebSocket-Key";
     17 const char* const kSecWebSocketAccept = "Sec-WebSocket-Accept";
     18 const char* const kSecWebSocketVersion = "Sec-WebSocket-Version";
     19 
     20 const char* const kSupportedVersion = "13";
     21 
     22 const char* const kUpgrade = "Upgrade";
     23 const char* const kWebSocketGuid = "258EAFA5-E914-47DA-95CA-C5AB0DC85B11";
     24 
     25 const char* const kSecWebSocketProtocolSpdy3 = ":sec-websocket-protocol";
     26 const char* const kSecWebSocketExtensionsSpdy3 = ":sec-websocket-extensions";
     27 
     28 const char* const kSecWebSocketProtocolLowercase =
     29     kSecWebSocketProtocolSpdy3 + 1;
     30 const char* const kSecWebSocketExtensionsLowercase =
     31     kSecWebSocketExtensionsSpdy3 + 1;
     32 const char* const kSecWebSocketKeyLowercase = "sec-websocket-key";
     33 const char* const kSecWebSocketVersionLowercase = "sec-websocket-version";
     34 const char* const kUpgradeLowercase = "upgrade";
     35 const char* const kWebSocketLowercase = "websocket";
     36 
     37 }  // namespace websockets
     38 }  // namespace net
     39