Class SNIHostName


public final class SNIHostName extends SNIServerName
Instances of this class represent a server name of type host_name in a Server Name Indication (SNI) extension.

As described in section 3, "Server Name Indication", of TLS Extensions (RFC 6066), "HostName" contains the fully qualified DNS hostname of the server, as understood by the client. The encoded server name value of a hostname is represented as a byte string using ASCII encoding without a trailing dot. This allows the support of Internationalized Domain Names (IDN) through the use of A-labels (the ASCII-Compatible Encoding (ACE) form of a valid string of Internationalized Domain Names for Applications (IDNA)) defined in RFC 5890.

Note that SNIHostName objects are immutable.

Since:
1.8
External Specifications
See Also:
  • Constructor Summary

    Constructors
    Constructor
    Description
    SNIHostName(byte[] encoded)
    Creates an SNIHostName using the specified encoded value.
    SNIHostName(String hostname)
    Creates an SNIHostName using the specified hostname.
  • Method Summary

    Modifier and Type
    Method
    Description
    static SNIMatcher
    Creates an SNIMatcher object for SNIHostNames.
    boolean
    equals(Object other)
    Compares this server name to the specified object.
    Returns the StandardCharsets.US_ASCII-compliant hostname of this SNIHostName object.
    int
    Returns a hash code value for this SNIHostName.
    Returns a string representation of the object, including the DNS hostname in this SNIHostName object.

    Methods declared in class SNIServerName

    getEncoded, getType
    Modifier and Type
    Method
    Description
    final byte[]
    Returns a copy of the encoded server name value of this server name.
    final int
    Returns the name type of this server name.

    Methods declared in class Object

    clone, finalize, getClass, notify, notifyAll, wait, wait, wait
    Modifier and Type
    Method
    Description
    protected Object
    Answers a new instance of the same class as the receiver, whose slots have been filled in with the values in the slots of the receiver.
    protected void
    Deprecated, for removal: This API element is subject to removal in a future version.
    May cause performance issues, deadlocks and hangs.
    final Class<? extends Object>
    Answers the unique instance of java.lang.Class which represents the class of the receiver.
    final void
    Causes one thread which is waiting on the receiver to be made ready to run.
    final void
    Causes all threads which are waiting on the receiver to be made ready to run.
    final void
    Causes the thread which sent this message to be made not ready to run pending some change in the receiver (as indicated by notify or notifyAll).
    final void
    wait(long time)
    Causes the thread which sent this message to be made not ready to run either pending some change in the receiver (as indicated by notify or notifyAll) or the expiration of the timeout.
    final void
    wait(long time, int frac)
    Causes the thread which sent this message to be made not ready to run either pending some change in the receiver (as indicated by notify or notifyAll) or the expiration of the timeout.