| OLD | NEW |
| 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
| 2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
| 3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef BIN_SECURE_SOCKET_H_ | 5 #ifndef BIN_SECURE_SOCKET_H_ |
| 6 #define BIN_SECURE_SOCKET_H_ | 6 #define BIN_SECURE_SOCKET_H_ |
| 7 | 7 |
| 8 #ifdef DART_IO_SECURE_SOCKET_DISABLED | 8 #ifdef DART_IO_SECURE_SOCKET_DISABLED |
| 9 #error "secure_socket.h can only be included on builds with SSL enabled" | 9 #error "secure_socket.h can only be included on builds with SSL enabled" |
| 10 #endif | 10 #endif |
| (...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 47 kWritePlaintext, | 47 kWritePlaintext, |
| 48 kReadEncrypted, | 48 kReadEncrypted, |
| 49 kWriteEncrypted, | 49 kWriteEncrypted, |
| 50 kNumBuffers, | 50 kNumBuffers, |
| 51 kFirstEncrypted = kReadEncrypted | 51 kFirstEncrypted = kReadEncrypted |
| 52 }; | 52 }; |
| 53 | 53 |
| 54 SSLFilter() | 54 SSLFilter() |
| 55 : callback_error(NULL), | 55 : callback_error(NULL), |
| 56 ssl_(NULL), | 56 ssl_(NULL), |
| 57 socket_side_(NULL), |
| 57 string_start_(NULL), | 58 string_start_(NULL), |
| 58 string_length_(NULL), | 59 string_length_(NULL), |
| 59 handshake_complete_(NULL), | 60 handshake_complete_(NULL), |
| 60 bad_certificate_callback_(NULL), | 61 bad_certificate_callback_(NULL), |
| 61 in_handshake_(false), | 62 in_handshake_(false), |
| 62 hostname_(NULL) { } | 63 hostname_(NULL) { } |
| 63 | 64 |
| 64 void Init(Dart_Handle dart_this); | 65 void Init(Dart_Handle dart_this); |
| 65 void Connect(const char* hostname, | 66 void Connect(const char* hostname, |
| 66 SSL_CTX* context, | 67 SSL_CTX* context, |
| (...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 124 void InitializeBuffers(Dart_Handle dart_this); | 125 void InitializeBuffers(Dart_Handle dart_this); |
| 125 void InitializePlatformData(); | 126 void InitializePlatformData(); |
| 126 | 127 |
| 127 DISALLOW_COPY_AND_ASSIGN(SSLFilter); | 128 DISALLOW_COPY_AND_ASSIGN(SSLFilter); |
| 128 }; | 129 }; |
| 129 | 130 |
| 130 } // namespace bin | 131 } // namespace bin |
| 131 } // namespace dart | 132 } // namespace dart |
| 132 | 133 |
| 133 #endif // BIN_SECURE_SOCKET_H_ | 134 #endif // BIN_SECURE_SOCKET_H_ |
| OLD | NEW |