public class HostnameUnverifiedException extends WebSocketException
The certificate of the peer does not match the expected hostname.
<p>
WebSocketException.getError() of this class returns HOSTNAME_UNVERIFIED.
</p>
<p> See <a href='https://github.com/TakahikoKawasaki/nv-websocket-client/pull/107' >Verify that certificate is valid for server hostname (#107)</a>. </p>
| Constructor and Description |
|---|
HostnameUnverifiedException(SSLSocket socket,
String hostname)
Constructor with the SSL socket and the expected hostname.
|
| Modifier and Type | Method and Description |
|---|---|
String |
getHostname()
Get the expected hostname.
|
SSLSocket |
getSSLSocket()
Get the SSL socket against which the hostname verification failed.
|
getErroraddSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toStringCopyright © 2021. All Rights Reserved.