OLD | NEW |
1 // Copyright (c) 2006-2009 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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_CLIENT_SOCKET_WIN_H_ | 5 #ifndef NET_SOCKET_SSL_CLIENT_SOCKET_WIN_H_ |
6 #define NET_SOCKET_SSL_CLIENT_SOCKET_WIN_H_ | 6 #define NET_SOCKET_SSL_CLIENT_SOCKET_WIN_H_ |
7 | 7 |
8 #define SECURITY_WIN32 // Needs to be defined before including security.h | 8 #define SECURITY_WIN32 // Needs to be defined before including security.h |
9 | 9 |
10 #include <windows.h> | 10 #include <windows.h> |
11 #include <wincrypt.h> | 11 #include <wincrypt.h> |
(...skipping 24 matching lines...) Expand all Loading... |
36 const std::string& hostname, | 36 const std::string& hostname, |
37 const SSLConfig& ssl_config); | 37 const SSLConfig& ssl_config); |
38 ~SSLClientSocketWin(); | 38 ~SSLClientSocketWin(); |
39 | 39 |
40 // SSLClientSocket methods: | 40 // SSLClientSocket methods: |
41 virtual void GetSSLInfo(SSLInfo* ssl_info); | 41 virtual void GetSSLInfo(SSLInfo* ssl_info); |
42 virtual void GetSSLCertRequestInfo(SSLCertRequestInfo* cert_request_info); | 42 virtual void GetSSLCertRequestInfo(SSLCertRequestInfo* cert_request_info); |
43 virtual NextProtoStatus GetNextProto(std::string* proto); | 43 virtual NextProtoStatus GetNextProto(std::string* proto); |
44 | 44 |
45 // ClientSocket methods: | 45 // ClientSocket methods: |
46 virtual int Connect(CompletionCallback* callback, const BoundNetLog& net_log); | 46 virtual int Connect(CompletionCallback* callback); |
47 virtual void Disconnect(); | 47 virtual void Disconnect(); |
48 virtual bool IsConnected() const; | 48 virtual bool IsConnected() const; |
49 virtual bool IsConnectedAndIdle() const; | 49 virtual bool IsConnectedAndIdle() const; |
50 virtual int GetPeerAddress(AddressList* address) const; | 50 virtual int GetPeerAddress(AddressList* address) const; |
| 51 virtual const BoundNetLog& NetLog() const { return net_log_; } |
51 | 52 |
52 // Socket methods: | 53 // Socket methods: |
53 virtual int Read(IOBuffer* buf, int buf_len, CompletionCallback* callback); | 54 virtual int Read(IOBuffer* buf, int buf_len, CompletionCallback* callback); |
54 virtual int Write(IOBuffer* buf, int buf_len, CompletionCallback* callback); | 55 virtual int Write(IOBuffer* buf, int buf_len, CompletionCallback* callback); |
55 | 56 |
56 virtual bool SetReceiveBufferSize(int32 size); | 57 virtual bool SetReceiveBufferSize(int32 size); |
57 virtual bool SetSendBufferSize(int32 size); | 58 virtual bool SetSendBufferSize(int32 size); |
58 | 59 |
59 private: | 60 private: |
60 bool completed_handshake() const { | 61 bool completed_handshake() const { |
(...skipping 120 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
181 | 182 |
182 // True when the decrypter needs more data in order to decrypt. | 183 // True when the decrypter needs more data in order to decrypt. |
183 bool need_more_data_; | 184 bool need_more_data_; |
184 | 185 |
185 BoundNetLog net_log_; | 186 BoundNetLog net_log_; |
186 }; | 187 }; |
187 | 188 |
188 } // namespace net | 189 } // namespace net |
189 | 190 |
190 #endif // NET_SOCKET_SSL_CLIENT_SOCKET_WIN_H_ | 191 #endif // NET_SOCKET_SSL_CLIENT_SOCKET_WIN_H_ |
OLD | NEW |