2017-09-12 22:42:36 +02:00
<?xml version="1.0" encoding="UTF-8" ?>
2019-04-01 12:33:56 +02:00
<class name= "StreamPeerSSL" inherits= "StreamPeer" category= "Core" version= "3.2" >
2017-09-12 22:42:36 +02:00
<brief_description >
SSL Stream peer.
</brief_description>
<description >
SSL Stream peer. This object can be used to connect to SSL servers.
</description>
<tutorials >
2018-11-05 08:46:27 +01:00
<link > https://docs.godotengine.org/en/latest/tutorials/networking/ssl_certificates.html</link>
2017-09-12 22:42:36 +02:00
</tutorials>
<methods >
<method name= "accept_stream" >
<return type= "int" enum= "Error" >
</return>
2018-07-26 11:56:21 +02:00
<argument index= "0" name= "base" type= "StreamPeer" >
2017-09-12 22:42:36 +02:00
</argument>
<description >
</description>
</method>
<method name= "connect_to_stream" >
<return type= "int" enum= "Error" >
</return>
<argument index= "0" name= "stream" type= "StreamPeer" >
</argument>
<argument index= "1" name= "validate_certs" type= "bool" default= "false" >
</argument>
<argument index= "2" name= "for_hostname" type= "String" default= """" >
</argument>
<description >
2019-04-17 13:42:56 +02:00
Connect to a peer using an underlying [StreamPeer] "stream", when "validate_certs" is [code]true[/code], [StreamPeerSSL] will validate that the certificate presented by the peer matches the "for_hostname".
2017-09-12 22:42:36 +02:00
</description>
</method>
<method name= "disconnect_from_stream" >
<return type= "void" >
</return>
<description >
Disconnect from host.
</description>
</method>
<method name= "get_status" qualifiers= "const" >
<return type= "int" enum= "StreamPeerSSL.Status" >
</return>
<description >
2019-05-24 04:15:43 +02:00
Returns the status of the connection, one of STATUS_* enum.
2017-09-12 22:42:36 +02:00
</description>
</method>
2018-02-09 15:03:34 +01:00
<method name= "poll" >
<return type= "void" >
</return>
<description >
Poll the connection to check for incoming bytes. Call this right before "get_available_bytes()" for it to work properly.
</description>
</method>
2017-09-12 22:42:36 +02:00
</methods>
2018-07-26 11:56:21 +02:00
<members >
<member name= "blocking_handshake" type= "bool" setter= "set_blocking_handshake_enabled" getter= "is_blocking_handshake_enabled" >
</member>
</members>
2017-09-12 22:42:36 +02:00
<constants >
2017-11-24 23:16:30 +01:00
<constant name= "STATUS_DISCONNECTED" value= "0" enum= "Status" >
2019-03-29 23:37:35 +01:00
A status representing a [StreamPeerSSL] that is disconnected.
2017-09-12 22:42:36 +02:00
</constant>
2018-10-07 15:52:07 +02:00
<constant name= "STATUS_HANDSHAKING" value= "1" enum= "Status" >
</constant>
2018-07-26 11:56:21 +02:00
<constant name= "STATUS_CONNECTED" value= "2" enum= "Status" >
2019-03-29 23:37:35 +01:00
A status representing a [StreamPeerSSL] that is connected to a host.
2017-09-12 22:42:36 +02:00
</constant>
2018-07-26 11:56:21 +02:00
<constant name= "STATUS_ERROR" value= "3" enum= "Status" >
2017-09-12 22:42:36 +02:00
</constant>
2018-07-26 11:56:21 +02:00
<constant name= "STATUS_ERROR_HOSTNAME_MISMATCH" value= "4" enum= "Status" >
2017-09-12 22:42:36 +02:00
An error status that shows a mismatch in the SSL certificate domain presented by the host and the domain requested for validation.
</constant>
</constants>
</class>