Package org.mariadb.jdbc.client.tls

## Class DefaultTlsSocketPlugin

- java.lang.Object
- - org.mariadb.jdbc.client.tls.DefaultTlsSocketPlugin

All Implemented Interfaces:
  `TlsSocketPlugin`

    public class DefaultTlsSocketPlugin
    extends Object
    implements TlsSocketPlugin

### Constructor Summary

Constructors
`DefaultTlsSocketPlugin()`

### Method Summary

All Methods Instance Methods Concrete Methods
`SSLSocketFactory` `getSocketFactory​(Configuration conf, ExceptionFactory exceptionFactory)` Get socket factory.
`String` `type()` plugin type.
`void` `verify​(String host, SSLSession session, long serverThreadId)` Host name verifier implementation.

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

### Methods inherited from interface org.mariadb.jdbc.plugin.TlsSocketPlugin

`createSocket`

### Constructor Detail

#### DefaultTlsSocketPlugin

    public DefaultTlsSocketPlugin()

### Method Detail

#### type

    public String type()

Description copied from interface: `TlsSocketPlugin`
plugin type.

Specified by:
  `type` in interface `TlsSocketPlugin`
Returns:
  plugin type

#### getSocketFactory

    public SSLSocketFactory getSocketFactory​(Configuration conf,
                                             ExceptionFactory exceptionFactory)
                                      throws SQLException

Description copied from interface: `TlsSocketPlugin`
Get socket factory.

Specified by:
  `getSocketFactory` in interface `TlsSocketPlugin`
Parameters:
  `conf` - connection string option. Non-standard option are stored in `nonMappedOptions` if any specific option is needed.
  `exceptionFactory` - exception handler
Returns:
  custom SSL socket factory
Throws:
  `SQLException` - if socket factory configuration failed.

#### verify

    public void verify​(String host,
                       SSLSession session,
                       long serverThreadId)
                throws SSLException

Description copied from interface: `TlsSocketPlugin`
Host name verifier implementation.

Specified by:
  `verify` in interface `TlsSocketPlugin`
Parameters:
  `host` - hostname
  `session` - ssl session
  `serverThreadId` - current server threadId
Throws:
  `SSLException` - if verification fail