Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(620)

Side by Side Diff: content/browser/renderer_host/p2p/socket_host.h

Issue 22452002: Adding TLS support to the TCP Client sockets. (Closed) Base URL: https://src.chromium.org/chrome/trunk/src/
Patch Set: Created 7 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef CONTENT_BROWSER_RENDERER_HOST_P2P_SOCKET_HOST_H_ 5 #ifndef CONTENT_BROWSER_RENDERER_HOST_P2P_SOCKET_HOST_H_
6 #define CONTENT_BROWSER_RENDERER_HOST_P2P_SOCKET_HOST_H_ 6 #define CONTENT_BROWSER_RENDERER_HOST_P2P_SOCKET_HOST_H_
7 7
8 #include "content/common/content_export.h" 8 #include "content/common/content_export.h"
9 #include "content/common/p2p_sockets.h" 9 #include "content/common/p2p_sockets.h"
10 10
(...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after
58 STUN_SEND_REQUEST = 0x0004, 58 STUN_SEND_REQUEST = 0x0004,
59 STUN_SEND_RESPONSE = 0x0104, 59 STUN_SEND_RESPONSE = 0x0104,
60 STUN_SEND_ERROR_RESPONSE = 0x0114, 60 STUN_SEND_ERROR_RESPONSE = 0x0114,
61 STUN_DATA_INDICATION = 0x0115 61 STUN_DATA_INDICATION = 0x0115
62 }; 62 };
63 63
64 enum State { 64 enum State {
65 STATE_UNINITIALIZED, 65 STATE_UNINITIALIZED,
66 STATE_CONNECTING, 66 STATE_CONNECTING,
67 STATE_OPEN, 67 STATE_OPEN,
68 STATE_TLS_CONNECTING,
juberti2 2013/08/07 06:04:21 It seems confusing to have different meanings for
Mallinath (Gone from Chromium) 2013/08/07 23:48:19 Done.
69 STATE_TLS_OPEN,
68 STATE_ERROR, 70 STATE_ERROR,
69 }; 71 };
70 72
71 P2PSocketHost(IPC::Sender* message_sender, int id); 73 P2PSocketHost(IPC::Sender* message_sender, int id);
72 74
73 // Verifies that the packet |data| has a valid STUN header. In case 75 // Verifies that the packet |data| has a valid STUN header. In case
74 // of success stores type of the message in |type|. 76 // of success stores type of the message in |type|.
75 static bool GetStunPacketType(const char* data, int data_size, 77 static bool GetStunPacketType(const char* data, int data_size,
76 StunMessageType* type); 78 StunMessageType* type);
77 static bool IsRequestOrResponse(StunMessageType type); 79 static bool IsRequestOrResponse(StunMessageType type);
78 80
79 IPC::Sender* message_sender_; 81 IPC::Sender* message_sender_;
80 int id_; 82 int id_;
81 State state_; 83 State state_;
82 84
83 DISALLOW_COPY_AND_ASSIGN(P2PSocketHost); 85 DISALLOW_COPY_AND_ASSIGN(P2PSocketHost);
84 }; 86 };
85 87
86 } // namespace content 88 } // namespace content
87 89
88 #endif // CONTENT_BROWSER_RENDERER_HOST_P2P_SOCKET_HOST_H_ 90 #endif // CONTENT_BROWSER_RENDERER_HOST_P2P_SOCKET_HOST_H_
OLDNEW
« no previous file with comments | « no previous file | content/browser/renderer_host/p2p/socket_host.cc » ('j') | content/browser/renderer_host/p2p/socket_host_tcp.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698