class Starttls extends Object
| Modifier and Type | Class and Description |
|---|---|
(package private) static class |
Starttls.Protocol
Enumeration of known application-level TCP-based protocols that support
STARTTLS extension, with their standard port numbers.
|
| Constructor and Description |
|---|
Starttls() |
| Modifier and Type | Method and Description |
|---|---|
(package private) static boolean |
consider(String host,
int port)
Make an effort to guess the right application protocol for STARTTLS
extension, either by standard port or by interrogating the user; then
obtain the appropriate protocol handler and run it.
|
(package private) static boolean |
obtainProtocolHandlerAndRun(String handlerSuffix,
String host,
int port)
Load a given application specific protocol STARTTLS handler and run it.
|
static boolean consider(String host, int port) throws IOException
host - the host to connect toport - the port to connect totrue if getting a certificate via STARTTLS handler
is believed to be successful, false otherwiseIOExceptionstatic boolean obtainProtocolHandlerAndRun(String handlerSuffix, String host, int port)
handlerSuffix - the protocol handler name suffix, named after
protocol itselfhost - the host to connect toport - the port to connect totrue if getting a certificate via STARTTLS handler
is believed to be successful, false otherwise