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