OLD | NEW |
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 NET_SOCKET_SSL_SERVER_SOCKET_NSS_H_ | 5 #ifndef NET_SOCKET_SSL_SERVER_SOCKET_NSS_H_ |
6 #define NET_SOCKET_SSL_SERVER_SOCKET_NSS_H_ | 6 #define NET_SOCKET_SSL_SERVER_SOCKET_NSS_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include <certt.h> | 9 #include <certt.h> |
10 #include <keyt.h> | 10 #include <keyt.h> |
(...skipping 27 matching lines...) Expand all Loading... |
38 unsigned char *out, | 38 unsigned char *out, |
39 unsigned int outlen) OVERRIDE; | 39 unsigned int outlen) OVERRIDE; |
40 | 40 |
41 // Socket interface (via StreamSocket). | 41 // Socket interface (via StreamSocket). |
42 virtual int Read(IOBuffer* buf, int buf_len, | 42 virtual int Read(IOBuffer* buf, int buf_len, |
43 OldCompletionCallback* callback) OVERRIDE; | 43 OldCompletionCallback* callback) OVERRIDE; |
44 virtual int Read(IOBuffer* buf, int buf_len, | 44 virtual int Read(IOBuffer* buf, int buf_len, |
45 const CompletionCallback& callback) OVERRIDE; | 45 const CompletionCallback& callback) OVERRIDE; |
46 virtual int Write(IOBuffer* buf, int buf_len, | 46 virtual int Write(IOBuffer* buf, int buf_len, |
47 OldCompletionCallback* callback) OVERRIDE; | 47 OldCompletionCallback* callback) OVERRIDE; |
48 virtual int Write(IOBuffer* buf, int buf_len, | |
49 const CompletionCallback& callback) OVERRIDE; | |
50 virtual bool SetReceiveBufferSize(int32 size) OVERRIDE; | 48 virtual bool SetReceiveBufferSize(int32 size) OVERRIDE; |
51 virtual bool SetSendBufferSize(int32 size) OVERRIDE; | 49 virtual bool SetSendBufferSize(int32 size) OVERRIDE; |
52 | 50 |
53 // StreamSocket implementation. | 51 // StreamSocket implementation. |
54 virtual int Connect(OldCompletionCallback* callback) OVERRIDE; | 52 virtual int Connect(OldCompletionCallback* callback) OVERRIDE; |
55 virtual int Connect(const CompletionCallback& callback) OVERRIDE; | 53 virtual int Connect(const CompletionCallback& callback) OVERRIDE; |
56 virtual void Disconnect() OVERRIDE; | 54 virtual void Disconnect() OVERRIDE; |
57 virtual bool IsConnected() const OVERRIDE; | 55 virtual bool IsConnected() const OVERRIDE; |
58 virtual bool IsConnectedAndIdle() const OVERRIDE; | 56 virtual bool IsConnectedAndIdle() const OVERRIDE; |
59 virtual int GetPeerAddress(AddressList* address) const OVERRIDE; | 57 virtual int GetPeerAddress(AddressList* address) const OVERRIDE; |
(...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
108 bool transport_send_busy_; | 106 bool transport_send_busy_; |
109 bool transport_recv_busy_; | 107 bool transport_recv_busy_; |
110 | 108 |
111 scoped_refptr<IOBuffer> recv_buffer_; | 109 scoped_refptr<IOBuffer> recv_buffer_; |
112 | 110 |
113 BoundNetLog net_log_; | 111 BoundNetLog net_log_; |
114 | 112 |
115 OldCompletionCallback* user_handshake_callback_; | 113 OldCompletionCallback* user_handshake_callback_; |
116 OldCompletionCallback* old_user_read_callback_; | 114 OldCompletionCallback* old_user_read_callback_; |
117 CompletionCallback user_read_callback_; | 115 CompletionCallback user_read_callback_; |
118 OldCompletionCallback* old_user_write_callback_; | 116 OldCompletionCallback* user_write_callback_; |
119 CompletionCallback user_write_callback_; | |
120 | 117 |
121 // Used by Read function. | 118 // Used by Read function. |
122 scoped_refptr<IOBuffer> user_read_buf_; | 119 scoped_refptr<IOBuffer> user_read_buf_; |
123 int user_read_buf_len_; | 120 int user_read_buf_len_; |
124 | 121 |
125 // Used by Write function. | 122 // Used by Write function. |
126 scoped_refptr<IOBuffer> user_write_buf_; | 123 scoped_refptr<IOBuffer> user_write_buf_; |
127 int user_write_buf_len_; | 124 int user_write_buf_len_; |
128 | 125 |
129 // The NSS SSL state machine | 126 // The NSS SSL state machine |
(...skipping 16 matching lines...) Expand all Loading... |
146 | 143 |
147 State next_handshake_state_; | 144 State next_handshake_state_; |
148 bool completed_handshake_; | 145 bool completed_handshake_; |
149 | 146 |
150 DISALLOW_COPY_AND_ASSIGN(SSLServerSocketNSS); | 147 DISALLOW_COPY_AND_ASSIGN(SSLServerSocketNSS); |
151 }; | 148 }; |
152 | 149 |
153 } // namespace net | 150 } // namespace net |
154 | 151 |
155 #endif // NET_SOCKET_SSL_SERVER_SOCKET_NSS_H_ | 152 #endif // NET_SOCKET_SSL_SERVER_SOCKET_NSS_H_ |
OLD | NEW |