src/java.base/share/classes/sun/security/ssl/ECPointFormatsExtension.java
changeset 57718 a93b7b28f644
parent 55353 946f7f2d321c
child 58679 9c3209ff7550
equal deleted inserted replaced
57716:bfcdcd00e4fb 57718:a93b7b28f644
    32 import javax.net.ssl.SSLProtocolException;
    32 import javax.net.ssl.SSLProtocolException;
    33 import static sun.security.ssl.SSLExtension.CH_EC_POINT_FORMATS;
    33 import static sun.security.ssl.SSLExtension.CH_EC_POINT_FORMATS;
    34 import sun.security.ssl.SSLExtension.ExtensionConsumer;
    34 import sun.security.ssl.SSLExtension.ExtensionConsumer;
    35 import sun.security.ssl.SSLExtension.SSLExtensionSpec;
    35 import sun.security.ssl.SSLExtension.SSLExtensionSpec;
    36 import sun.security.ssl.SSLHandshake.HandshakeMessage;
    36 import sun.security.ssl.SSLHandshake.HandshakeMessage;
    37 import sun.security.ssl.NamedGroup.NamedGroupType;
    37 import sun.security.ssl.NamedGroup.NamedGroupSpec;
    38 
    38 
    39 /**
    39 /**
    40  * Pack of the "ec_point_formats" extensions [RFC 4492].
    40  * Pack of the "ec_point_formats" extensions [RFC 4492].
    41  */
    41  */
    42 final class ECPointFormatsExtension {
    42 final class ECPointFormatsExtension {
   177             }
   177             }
   178 
   178 
   179             // Produce the extension.
   179             // Produce the extension.
   180             //
   180             //
   181             // produce the extension only if EC cipher suite is activated.
   181             // produce the extension only if EC cipher suite is activated.
   182             if (NamedGroupType.NAMED_GROUP_ECDHE.isSupported(
   182             if (NamedGroupSpec.NAMED_GROUP_ECDHE.isSupported(
   183                     chc.activeCipherSuites)) {
   183                     chc.activeCipherSuites)) {
   184                 // We are using uncompressed ECPointFormat only at present.
   184                 // We are using uncompressed ECPointFormat only at present.
   185                 byte[] extData = new byte[] {0x01, 0x00};
   185                 byte[] extData = new byte[] {0x01, 0x00};
   186 
   186 
   187                 // Update the context.
   187                 // Update the context.