<div class="meta" robots="noindex">

</div>

Property

# SSLSocket.ConnectionType

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

<div class="warning">

<div class="title">

Warning

</div>

This item was deprecated in version 2019r2. Please use `SSLSocket.SSLConnectionTypes<sslsocket.sslconnectiontypes>` as a replacement.

</div>

## Description

Specifies the type of SSL connection.

## Notes

<div class="note">

<div class="title">

Note

</div>

Use the SSLSocket constant names for <span class="title-ref">ConnectionType</span>, and not the integer values so that the IDE can warn you when constants are removed or deprecated.

</div>

ConnectionType can take the following `SSLSocket</api/networking/sslsocket>` class constants:

| Class Constant | Value | Description                                                                                                                                                                                                                                                                                                                                                                                                                                                               |
|----------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| SSLv23         | 1     | A TLS/SSL connection established with this constant may understand the SSLv3, TLSv1, TLSv1.1 and TLSv1.2 protocols. If extensions are required (for example server name) a client will send out TLSv1 client hello messages including extensions and will indicate that it also understands TLSv1.1, TLSv1.2 and permits a fallback to SSLv3. A server will support SSLv3, TLSv1, TLSv1.1 and TLSv1.2 protocols. This is the best choice when compatibility is a concern. |
| TLSv1          | 3     | TLS (Transport Layer Security) version 1. (default)                                                                                                                                                                                                                                                                                                                                                                                                                       |
| TLSv11         | 4     | TLS (Transport Layer Security) version 1.1                                                                                                                                                                                                                                                                                                                                                                                                                                |
| TLSv12         | 5     | TLS (Transport Layer Security) version 1.2                                                                                                                                                                                                                                                                                                                                                                                                                                |

The default is TLSv1. If you need to change the connection type, close the connection first.

## Sample code

This example changes the connection type to TLSv1.

``` xojo
Socket1.ConnectionType = SSLSocket.TLSv1
```

## Compatibility

All project types on all supported operating systems.
