Class TlsRsaPremasterSecretParameterSpec

  • All Implemented Interfaces:
    java.security.spec.AlgorithmParameterSpec

    final class TlsRsaPremasterSecretParameterSpec
    extends java.lang.Object
    implements java.security.spec.AlgorithmParameterSpec
    Parámetros para el RSA premaster secret de SSL/TLS.

    Instances of this class are immutable.

    Since:
    1.6
    • Constructor Summary

      Constructors 
      Constructor Description
      TlsRsaPremasterSecretParameterSpec​(int clientVer, int serverVer)
      Constructs a new TlsRsaPremasterSecretParameterSpec.
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      private static int checkVersion​(int version)  
      (package private) int getClientVersion()
      Returns the version of the TLS protocol by which the client wishes to communicate during this session.
      (package private) int getServerVersion()
      Returns the negotiated version of the TLS protocol which contains the lower of that suggested by the client in the client hello and the highest supported by the server.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • clientVersion

        private final int clientVersion
      • serverVersion

        private final int serverVersion
    • Constructor Detail

      • TlsRsaPremasterSecretParameterSpec

        TlsRsaPremasterSecretParameterSpec​(int clientVer,
                                           int serverVer)
        Constructs a new TlsRsaPremasterSecretParameterSpec.
        Parameters:
        clientVer - the version of the TLS protocol by which the client wishes to communicate during this session
        serverVer - the negotiated version of the TLS protocol which contains the lower of that suggested by the client in the client hello and the highest supported by the server.
        Throws:
        java.lang.IllegalArgumentException - if clientVersion or serverVersion are negative or larger than (2^16 - 1)
    • Method Detail

      • getClientVersion

        int getClientVersion()
        Returns the version of the TLS protocol by which the client wishes to communicate during this session.
        Returns:
        the version of the TLS protocol in ClientHello message
      • getServerVersion

        int getServerVersion()
        Returns the negotiated version of the TLS protocol which contains the lower of that suggested by the client in the client hello and the highest supported by the server.
        Returns:
        the negotiated version of the TLS protocol in ServerHello message
      • checkVersion

        private static int checkVersion​(int version)