jdk/src/java.base/share/classes/sun/security/internal/spec/TlsRsaPremasterSecretParameterSpec.java
changeset 32649 2ee9017c7597
parent 25859 3317bb8137f4
child 35279 5afd2941dfb7
equal deleted inserted replaced
32648:1fa861caf840 32649:2ee9017c7597
    48      * be the maximum version supported by the client (i.e. the version it
    48      * be the maximum version supported by the client (i.e. the version it
    49      * requested in its client hello version). However, we (and other
    49      * requested in its client hello version). However, we (and other
    50      * implementations) used to send the active negotiated version. The
    50      * implementations) used to send the active negotiated version. The
    51      * system property below allows to toggle the behavior.
    51      * system property below allows to toggle the behavior.
    52      */
    52      */
    53     private final static String PROP_NAME =
    53     private static final String PROP_NAME =
    54                                 "com.sun.net.ssl.rsaPreMasterSecretFix";
    54                                 "com.sun.net.ssl.rsaPreMasterSecretFix";
    55 
    55 
    56     /*
    56     /*
    57      * Default is "false" (old behavior) for compatibility reasons in
    57      * Default is "false" (old behavior) for compatibility reasons in
    58      * SSLv3/TLSv1.  Later protocols (TLSv1.1+) do not use this property.
    58      * SSLv3/TLSv1.  Later protocols (TLSv1.1+) do not use this property.
    59      */
    59      */
    60     private final static boolean rsaPreMasterSecretFix =
    60     private static final boolean rsaPreMasterSecretFix =
    61             AccessController.doPrivileged(new PrivilegedAction<Boolean>() {
    61             AccessController.doPrivileged(new PrivilegedAction<Boolean>() {
    62                 public Boolean run() {
    62                 public Boolean run() {
    63                     String value = System.getProperty(PROP_NAME);
    63                     String value = System.getProperty(PROP_NAME);
    64                     if (value != null && value.equalsIgnoreCase("true")) {
    64                     if (value != null && value.equalsIgnoreCase("true")) {
    65                         return Boolean.TRUE;
    65                         return Boolean.TRUE;