OLD | NEW |
---|---|
1 // Copyright (c) 2015, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2015, 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 part of dart.io; | 5 part of dart.io; |
6 | 6 |
7 /** | 7 /** |
8 * The object containing the certificates to trust when making | 8 * The object containing the certificates to trust when making |
9 * a secure client connection, and the certificate chain and | 9 * a secure client connection, and the certificate chain and |
10 * private key to serve from a secure server. | 10 * private key to serve from a secure server. |
(...skipping 131 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
142 /** | 142 /** |
143 * Sets the list of authority names that a [SecureServerSocket] will advertise | 143 * Sets the list of authority names that a [SecureServerSocket] will advertise |
144 * as accepted, when requesting a client certificate from a connecting | 144 * as accepted, when requesting a client certificate from a connecting |
145 * client. | 145 * client. |
146 * | 146 * |
147 * Like [setClientAuthorities] but takes the contents of the file. | 147 * Like [setClientAuthorities] but takes the contents of the file. |
148 */ | 148 */ |
149 void setClientAuthoritiesBytes(List<int> authCertBytes, {String password}); | 149 void setClientAuthoritiesBytes(List<int> authCertBytes, {String password}); |
150 | 150 |
151 /** | 151 /** |
152 * Whether the platform supports ALPN. | |
kevmoo
2017/06/08 20:47:54
It's good to put a note in the doccomment, too – e
| |
153 */ | |
154 @deprecated | |
155 external static bool get alpnSupported; | |
156 | |
157 /** | |
152 * Sets the list of application-level protocols supported by a client | 158 * Sets the list of application-level protocols supported by a client |
153 * connection or server connection. The ALPN (application level protocol | 159 * connection or server connection. The ALPN (application level protocol |
154 * negotiation) extension to TLS allows a client to send a list of | 160 * negotiation) extension to TLS allows a client to send a list of |
155 * protocols in the TLS client hello message, and the server to pick | 161 * protocols in the TLS client hello message, and the server to pick |
156 * one and send the selected one back in its server hello message. | 162 * one and send the selected one back in its server hello message. |
157 * | 163 * |
158 * Separate lists of protocols can be sent for client connections and | 164 * Separate lists of protocols can be sent for client connections and |
159 * for server connections, using the same SecurityContext. The [isServer] | 165 * for server connections, using the same SecurityContext. The [isServer] |
160 * boolean argument specifies whether to set the list for server connections | 166 * boolean argument specifies whether to set the list for server connections |
161 * or client connections. | 167 * or client connections. |
(...skipping 91 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
253 } | 259 } |
254 | 260 |
255 if (bytes.length >= (1 << 13)) { | 261 if (bytes.length >= (1 << 13)) { |
256 throw new ArgumentError( | 262 throw new ArgumentError( |
257 'The maximum message length supported is 2^13-1.'); | 263 'The maximum message length supported is 2^13-1.'); |
258 } | 264 } |
259 | 265 |
260 return new Uint8List.fromList(bytes); | 266 return new Uint8List.fromList(bytes); |
261 } | 267 } |
262 } | 268 } |
OLD | NEW |