com.amazon.redshift.ssl.jdbc4

## Class LibPQFactory

- java.lang.Object
- - javax.net.SocketFactory
  - - javax.net.ssl.SSLSocketFactory
    - - com.amazon.redshift.ssl.WrappedFactory
      - - com.amazon.redshift.ssl.LibPQFactory
        - - com.amazon.redshift.ssl.jdbc4.LibPQFactory

All Implemented Interfaces:
  HostnameVerifier

Deprecated.
prefer `LibPQFactory`

    @Deprecated
    public class LibPQFactory
    extends LibPQFactory
    implements HostnameVerifier

### Nested Class Summary

### Nested classes/interfaces inherited from class com.amazon.redshift.ssl.LibPQFactory

`LibPQFactory.ConsoleCallbackHandler`

### Field Summary

### Fields inherited from class com.amazon.redshift.ssl.WrappedFactory

`factory`

### Constructor Summary

Constructors
Constructor and Description
`LibPQFactory(Properties info)` Deprecated. prefer `LibPQFactory`

### Method Summary

Methods
`boolean` `verify(String hostname, SSLSession session)` Deprecated. use PgjdbcHostnameVerifier
`static boolean` `verifyHostName(String hostname, String pattern)` Deprecated. use `RedshiftjdbcHostnameVerifier`

### Methods inherited from class com.amazon.redshift.ssl.LibPQFactory

`throwKeyManagerException`

### Methods inherited from class com.amazon.redshift.ssl.WrappedFactory

`createSocket, createSocket, createSocket, createSocket, createSocket, getDefaultCipherSuites, getSupportedCipherSuites`

### Methods inherited from class javax.net.ssl.SSLSocketFactory

`getDefault`

### Methods inherited from class javax.net.SocketFactory

`createSocket`

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

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

### Constructor Detail

#### LibPQFactory

    @Deprecated
    public LibPQFactory(Properties info)
                 throws RedshiftException

Deprecated. prefer `LibPQFactory`

Parameters:
  `info` - the connection parameters The following parameters are used: sslmode,sslcert,sslkey,sslrootcert,sslhostnameverifier,sslpasswordcallback,sslpassword
Throws:
  `RedshiftException` - if security error appears when initializing factory

### Method Detail

#### verifyHostName

    @Deprecated
    public static boolean verifyHostName(String hostname,
                                    String pattern)

Deprecated. use `RedshiftjdbcHostnameVerifier`
Verifies if given hostname matches pattern.

Parameters:
  `hostname` - input hostname
  `pattern` - domain name pattern
Returns:
  true when domain matches pattern

#### verify

    @Deprecated
    public boolean verify(String hostname,
                            SSLSession session)

Deprecated. use PgjdbcHostnameVerifier
Verifies the server certificate according to the libpq rules. The cn attribute of the certificate is matched against the hostname. If the cn attribute starts with an asterisk (*), it will be treated as a wildcard, and will match all characters except a dot (.). This means the certificate will not match subdomains. If the connection is made using an IP address instead of a hostname, the IP address will be matched (without doing any DNS lookups).

Specified by:
  `verify` in interface `HostnameVerifier`
Parameters:
  `hostname` - Hostname or IP address of the server.
  `session` - The SSL session.
Returns:
  true if the certificate belongs to the server, false otherwise.
See Also:
  `RedshiftjdbcHostnameVerifier`