Package NeoVisionaries.WebSockets
Class HostnameUnverifiedException
- java.lang.Object
-
- java.lang.Throwable
-
- java.lang.Exception
-
- NeoVisionaries.WebSockets.WebSocketException
-
- NeoVisionaries.WebSockets.HostnameUnverifiedException
-
- All Implemented Interfaces:
java.io.Serializable
public class HostnameUnverifiedException extends WebSocketException
The certificate of the peer does not match the expected hostname.
Read included Apache License 2.0:HERE
AllNeoVisionaries.WebSockets.*
Code Obtained From:GitHub 'NV' (Takahiko Kawasaki)
Public Archive.
WebSocketException.getError()
of this class returnsHOSTNAME_UNVERIFIED
.See Verify that certificate is valid for server hostname (#107).
- Since:
- 2.1
- See Also:
- Serialized Form
Hi-Lited Source-Code:- View Here: NeoVisionaries/WebSockets/HostnameUnverifiedException.java
- Open New Browser-Tab: NeoVisionaries/WebSockets/HostnameUnverifiedException.java
File Size: 2,694 Bytes Line Count: 104 '\n' Characters Found
-
-
Constructor Summary
Constructors Constructor Description HostnameUnverifiedException(javax.net.ssl.SSLSocket socket, String hostname)
Constructor with the SSL socket and the expected hostname.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description String
getHostname()
Get the expected hostname.javax.net.ssl.SSLSocket
getSSLSocket()
Get the SSL socket against which the hostname verification failed.-
Methods inherited from class NeoVisionaries.WebSockets.WebSocketException
getError
-
-
-
-
Constructor Detail
-
HostnameUnverifiedException
public HostnameUnverifiedException(javax.net.ssl.SSLSocket socket, java.lang.String hostname)
Constructor with the SSL socket and the expected hostname.- Parameters:
socket
- The SSL socket against which the hostname verification failed.hostname
- The expected hostname.
-
-
Method Detail
-
getSSLSocket
public javax.net.ssl.SSLSocket getSSLSocket()
Get the SSL socket against which the hostname verification failed.- Returns:
- The SSL socket.
- Code:
- Exact Method Body:
return mSSLSocket;
-
getHostname
public java.lang.String getHostname()
Get the expected hostname.- Returns:
- The expected hostname.
- Code:
- Exact Method Body:
return mHostname;
-
-