Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(565)

Side by Side Diff: ppapi/api/private/ppb_flash_tcp_socket.idl

Issue 9405038: Add PPAPI interface for secure sockets in flash (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 8 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 /* Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 /* Copyright (c) 2012 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 5
6 /** 6 /**
7 * This file defines the <code>PPB_Flash_TCPSocket</code> interface. 7 * This file defines the <code>PPB_Flash_TCPSocket</code> interface.
8 */ 8 */
9 9
10 label Chrome { 10 label Chrome {
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after
70 * SSLHandshake() will fail without starting a handshake. Otherwise, any 70 * SSLHandshake() will fail without starting a handshake. Otherwise, any
71 * failure during the handshake process will cause the socket to be 71 * failure during the handshake process will cause the socket to be
72 * disconnected. 72 * disconnected.
73 */ 73 */
74 int32_t SSLHandshake([in] PP_Resource tcp_socket, 74 int32_t SSLHandshake([in] PP_Resource tcp_socket,
75 [in] str_t server_name, 75 [in] str_t server_name,
76 [in] uint16_t server_port, 76 [in] uint16_t server_port,
77 [in] PP_CompletionCallback callback); 77 [in] PP_CompletionCallback callback);
78 78
79 /** 79 /**
80 * Returns the <code>PPB_Flash_X509Certificate</code> for a socket connection
81 * if an SSL connection has been established using <code>SSL_Handshake</code>.
82 * If no SSL connection has been established, a null resource is returned.
83 */
84 PP_Resource GetX509Certificate([in] PP_Resource tcp_socket);
Ryan Sleevi 2012/02/16 21:29:23 Why only return a single certificate? A (typical)
raymes 2012/02/16 22:31:29 I guess the intention is only to return the server
Ryan Sleevi 2012/02/16 23:06:33 If going the Flash-specific interface route: GetSe
raymes 2012/02/21 19:07:40 Done.
85
86 /**
87 * Add a trusted/untrusted root certificate to be used for this connection.
88 * The <code>PP_Resource</code> must be a
89 * <code>PPB_Flash_X509Certificate<code>. <code>PP_TRUE</code> is returned
90 * upon success.
91 */
92 PP_Bool AddRootCertificates([in] PP_Resource certificate,
Ryan Sleevi 2012/02/16 23:06:33 Looking at the Flash API, I would suggest dropping
raymes 2012/02/21 19:07:40 Done.
93 [in] PP_Bool is_trusted);
94
95 /**
80 * Reads data from the socket. The size of |buffer| must be at least as large 96 * Reads data from the socket. The size of |buffer| must be at least as large
81 * as |bytes_to_read|. May perform a partial read. Returns the number of bytes 97 * as |bytes_to_read|. May perform a partial read. Returns the number of bytes
82 * read or an error code. If the return value is 0, then it indicates that 98 * read or an error code. If the return value is 0, then it indicates that
83 * end-of-file was reached. 99 * end-of-file was reached.
84 * This method won't return more than 1 megabyte, so if |bytes_to_read| 100 * This method won't return more than 1 megabyte, so if |bytes_to_read|
85 * exceeds 1 megabyte, it will always perform a partial read. 101 * exceeds 1 megabyte, it will always perform a partial read.
86 * Multiple outstanding read requests are not supported. 102 * Multiple outstanding read requests are not supported.
87 */ 103 */
88 int32_t Read([in] PP_Resource tcp_socket, 104 int32_t Read([in] PP_Resource tcp_socket,
89 [out] str_t buffer, 105 [out] str_t buffer,
(...skipping 15 matching lines...) Expand all
105 /** 121 /**
106 * Cancels any IO that may be pending, and disconnects the socket. Any pending 122 * Cancels any IO that may be pending, and disconnects the socket. Any pending
107 * callbacks will still run, reporting PP_Error_Aborted if pending IO was 123 * callbacks will still run, reporting PP_Error_Aborted if pending IO was
108 * interrupted. It is NOT valid to call Connect() again after a call to this 124 * interrupted. It is NOT valid to call Connect() again after a call to this
109 * method. Note: If the socket is destroyed when it is still connected, then 125 * method. Note: If the socket is destroyed when it is still connected, then
110 * it will be implicitly disconnected, so you are not required to call this 126 * it will be implicitly disconnected, so you are not required to call this
111 * method. 127 * method.
112 */ 128 */
113 void Disconnect([in] PP_Resource tcp_socket); 129 void Disconnect([in] PP_Resource tcp_socket);
114 }; 130 };
OLDNEW
« no previous file with comments | « no previous file | ppapi/api/private/ppb_flash_x509_certificate.idl » ('j') | ppapi/api/private/ppb_flash_x509_certificate.idl » ('J')

Powered by Google App Engine
This is Rietveld 408576698