src/java.base/share/classes/sun/security/ssl/CipherSuite.java
author erikj
Tue, 12 Sep 2017 19:03:39 +0200
changeset 47216 71c04702a3d5
parent 45064 jdk/src/java.base/share/classes/sun/security/ssl/CipherSuite.java@b1b45177051b
child 50768 68fa3d4026ea
child 56542 56aaa6cb3693
permissions -rw-r--r--
8187443: Forest Consolidation: Move files to unified layout Reviewed-by: darcy, ihse
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
     1
/*
45064
b1b45177051b 8140436: Negotiated Finite Field Diffie-Hellman Ephemeral Parameters for TLS
xuelei
parents: 39563
diff changeset
     2
 * Copyright (c) 2002, 2017, Oracle and/or its affiliates. All rights reserved.
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
     3
 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
90ce3da70b43 Initial load
duke
parents:
diff changeset
     4
 *
90ce3da70b43 Initial load
duke
parents:
diff changeset
     5
 * This code is free software; you can redistribute it and/or modify it
90ce3da70b43 Initial load
duke
parents:
diff changeset
     6
 * under the terms of the GNU General Public License version 2 only, as
5506
202f599c92aa 6943119: Rebrand source copyright notices
ohair
parents: 4236
diff changeset
     7
 * published by the Free Software Foundation.  Oracle designates this
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
     8
 * particular file as subject to the "Classpath" exception as provided
5506
202f599c92aa 6943119: Rebrand source copyright notices
ohair
parents: 4236
diff changeset
     9
 * by Oracle in the LICENSE file that accompanied this code.
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
    10
 *
90ce3da70b43 Initial load
duke
parents:
diff changeset
    11
 * This code is distributed in the hope that it will be useful, but WITHOUT
90ce3da70b43 Initial load
duke
parents:
diff changeset
    12
 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
90ce3da70b43 Initial load
duke
parents:
diff changeset
    13
 * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
90ce3da70b43 Initial load
duke
parents:
diff changeset
    14
 * version 2 for more details (a copy is included in the LICENSE file that
90ce3da70b43 Initial load
duke
parents:
diff changeset
    15
 * accompanied this code).
90ce3da70b43 Initial load
duke
parents:
diff changeset
    16
 *
90ce3da70b43 Initial load
duke
parents:
diff changeset
    17
 * You should have received a copy of the GNU General Public License version
90ce3da70b43 Initial load
duke
parents:
diff changeset
    18
 * 2 along with this work; if not, write to the Free Software Foundation,
90ce3da70b43 Initial load
duke
parents:
diff changeset
    19
 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
90ce3da70b43 Initial load
duke
parents:
diff changeset
    20
 *
5506
202f599c92aa 6943119: Rebrand source copyright notices
ohair
parents: 4236
diff changeset
    21
 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
202f599c92aa 6943119: Rebrand source copyright notices
ohair
parents: 4236
diff changeset
    22
 * or visit www.oracle.com if you need additional information or have any
202f599c92aa 6943119: Rebrand source copyright notices
ohair
parents: 4236
diff changeset
    23
 * questions.
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
    24
 */
90ce3da70b43 Initial load
duke
parents:
diff changeset
    25
90ce3da70b43 Initial load
duke
parents:
diff changeset
    26
90ce3da70b43 Initial load
duke
parents:
diff changeset
    27
package sun.security.ssl;
90ce3da70b43 Initial load
duke
parents:
diff changeset
    28
90ce3da70b43 Initial load
duke
parents:
diff changeset
    29
import java.util.*;
90ce3da70b43 Initial load
duke
parents:
diff changeset
    30
90ce3da70b43 Initial load
duke
parents:
diff changeset
    31
import java.security.NoSuchAlgorithmException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
    32
import java.security.InvalidKeyException;
7039
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
    33
import java.security.SecureRandom;
11904
f0eca4f34170 7145837: a little performance improvement on the usage of SecureRandom
xuelei
parents: 10917
diff changeset
    34
import java.security.KeyManagementException;
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
    35
16913
a6f4d1626ad9 8011680: Re-integrate AEAD implementation of JSSE
xuelei
parents: 16126
diff changeset
    36
import javax.crypto.Cipher;
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
    37
import javax.crypto.SecretKey;
90ce3da70b43 Initial load
duke
parents:
diff changeset
    38
import javax.crypto.spec.IvParameterSpec;
90ce3da70b43 Initial load
duke
parents:
diff changeset
    39
import javax.crypto.spec.SecretKeySpec;
90ce3da70b43 Initial load
duke
parents:
diff changeset
    40
90ce3da70b43 Initial load
duke
parents:
diff changeset
    41
import static sun.security.ssl.CipherSuite.KeyExchange.*;
7043
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
    42
import static sun.security.ssl.CipherSuite.PRF.*;
16913
a6f4d1626ad9 8011680: Re-integrate AEAD implementation of JSSE
xuelei
parents: 16126
diff changeset
    43
import static sun.security.ssl.CipherSuite.CipherType.*;
29488
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
    44
import static sun.security.ssl.CipherSuite.MacAlg.*;
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
    45
import static sun.security.ssl.CipherSuite.BulkCipher.*;
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
    46
import static sun.security.ssl.JsseJce.*;
45064
b1b45177051b 8140436: Negotiated Finite Field Diffie-Hellman Ephemeral Parameters for TLS
xuelei
parents: 39563
diff changeset
    47
import static sun.security.ssl.NamedGroupType.*;
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
    48
90ce3da70b43 Initial load
duke
parents:
diff changeset
    49
/**
90ce3da70b43 Initial load
duke
parents:
diff changeset
    50
 * An SSL/TLS CipherSuite. Constants for the standard key exchange, cipher,
90ce3da70b43 Initial load
duke
parents:
diff changeset
    51
 * and mac algorithms are also defined in this class.
90ce3da70b43 Initial load
duke
parents:
diff changeset
    52
 *
90ce3da70b43 Initial load
duke
parents:
diff changeset
    53
 * The CipherSuite class and the inner classes defined in this file roughly
90ce3da70b43 Initial load
duke
parents:
diff changeset
    54
 * follow the type safe enum pattern described in Effective Java. This means:
90ce3da70b43 Initial load
duke
parents:
diff changeset
    55
 *
90ce3da70b43 Initial load
duke
parents:
diff changeset
    56
 *  . instances are immutable, classes are final
90ce3da70b43 Initial load
duke
parents:
diff changeset
    57
 *
90ce3da70b43 Initial load
duke
parents:
diff changeset
    58
 *  . there is a unique instance of every value, i.e. there are never two
90ce3da70b43 Initial load
duke
parents:
diff changeset
    59
 *    instances representing the same CipherSuite, etc. This means equality
90ce3da70b43 Initial load
duke
parents:
diff changeset
    60
 *    tests can be performed using == instead of equals() (although that works
90ce3da70b43 Initial load
duke
parents:
diff changeset
    61
 *    as well). [A minor exception are *unsupported* CipherSuites read from a
90ce3da70b43 Initial load
duke
parents:
diff changeset
    62
 *    handshake message, but this is usually irrelevant]
90ce3da70b43 Initial load
duke
parents:
diff changeset
    63
 *
90ce3da70b43 Initial load
duke
parents:
diff changeset
    64
 *  . instances are obtained using the static valueOf() factory methods.
90ce3da70b43 Initial load
duke
parents:
diff changeset
    65
 *
90ce3da70b43 Initial load
duke
parents:
diff changeset
    66
 *  . properties are defined as final variables and made available as
90ce3da70b43 Initial load
duke
parents:
diff changeset
    67
 *    package private variables without method accessors
90ce3da70b43 Initial load
duke
parents:
diff changeset
    68
 *
90ce3da70b43 Initial load
duke
parents:
diff changeset
    69
 *  . if the member variable allowed is false, the given algorithm is either
90ce3da70b43 Initial load
duke
parents:
diff changeset
    70
 *    unavailable or disabled at compile time
90ce3da70b43 Initial load
duke
parents:
diff changeset
    71
 *
90ce3da70b43 Initial load
duke
parents:
diff changeset
    72
 */
10336
0bb1999251f8 7064075: Security libraries don't build with javac -Xlint:all,-deprecation -Werror
jjg
parents: 9035
diff changeset
    73
final class CipherSuite implements Comparable<CipherSuite> {
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
    74
90ce3da70b43 Initial load
duke
parents:
diff changeset
    75
    // minimum priority for supported CipherSuites
32649
2ee9017c7597 8136583: Core libraries should use blessed modifier order
martin
parents: 31706
diff changeset
    76
    static final int SUPPORTED_SUITES_PRIORITY = 1;
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
    77
90ce3da70b43 Initial load
duke
parents:
diff changeset
    78
    // minimum priority for default enabled CipherSuites
32649
2ee9017c7597 8136583: Core libraries should use blessed modifier order
martin
parents: 31706
diff changeset
    79
    static final int DEFAULT_SUITES_PRIORITY = 300;
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
    80
32649
2ee9017c7597 8136583: Core libraries should use blessed modifier order
martin
parents: 31706
diff changeset
    81
    private static final boolean ALLOW_ECC = Debug.getBooleanProperty
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
    82
        ("com.sun.net.ssl.enableECC", true);
90ce3da70b43 Initial load
duke
parents:
diff changeset
    83
90ce3da70b43 Initial load
duke
parents:
diff changeset
    84
    // Map Integer(id) -> CipherSuite
90ce3da70b43 Initial load
duke
parents:
diff changeset
    85
    // contains all known CipherSuites
32649
2ee9017c7597 8136583: Core libraries should use blessed modifier order
martin
parents: 31706
diff changeset
    86
    private static final Map<Integer,CipherSuite> idMap;
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
    87
90ce3da70b43 Initial load
duke
parents:
diff changeset
    88
    // Map String(name) -> CipherSuite
90ce3da70b43 Initial load
duke
parents:
diff changeset
    89
    // contains only supported CipherSuites (i.e. allowed == true)
32649
2ee9017c7597 8136583: Core libraries should use blessed modifier order
martin
parents: 31706
diff changeset
    90
    private static final Map<String,CipherSuite> nameMap;
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
    91
90ce3da70b43 Initial load
duke
parents:
diff changeset
    92
    // Protocol defined CipherSuite name, e.g. SSL_RSA_WITH_RC4_128_MD5
90ce3da70b43 Initial load
duke
parents:
diff changeset
    93
    // we use TLS_* only for new CipherSuites, still SSL_* for old ones
90ce3da70b43 Initial load
duke
parents:
diff changeset
    94
    final String name;
90ce3da70b43 Initial load
duke
parents:
diff changeset
    95
90ce3da70b43 Initial load
duke
parents:
diff changeset
    96
    // id in 16 bit MSB format, i.e. 0x0004 for SSL_RSA_WITH_RC4_128_MD5
90ce3da70b43 Initial load
duke
parents:
diff changeset
    97
    final int id;
90ce3da70b43 Initial load
duke
parents:
diff changeset
    98
90ce3da70b43 Initial load
duke
parents:
diff changeset
    99
    // priority for the internal default preference order. the higher the
90ce3da70b43 Initial load
duke
parents:
diff changeset
   100
    // better. Each supported CipherSuite *must* have a unique priority.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   101
    // Ciphersuites with priority >= DEFAULT_SUITES_PRIORITY are enabled
90ce3da70b43 Initial load
duke
parents:
diff changeset
   102
    // by default
90ce3da70b43 Initial load
duke
parents:
diff changeset
   103
    final int priority;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   104
7043
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   105
    // key exchange, bulk cipher, mac and prf algorithms. See those
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   106
    // classes below.
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   107
    final KeyExchange keyExchange;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   108
    final BulkCipher cipher;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   109
    final MacAlg macAlg;
7043
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   110
    final PRF prfAlg;
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   111
90ce3da70b43 Initial load
duke
parents:
diff changeset
   112
    // whether a CipherSuite qualifies as exportable under 512/40 bit rules.
7043
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   113
    // TLS 1.1+ (RFC 4346) must not negotiate to these suites.
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   114
    final boolean exportable;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   115
90ce3da70b43 Initial load
duke
parents:
diff changeset
   116
    // true iff implemented and enabled at compile time
90ce3da70b43 Initial load
duke
parents:
diff changeset
   117
    final boolean allowed;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   118
7039
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
   119
    // obsoleted since protocol version
30904
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   120
    //
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   121
    // TLS version is used.  If checking DTLS versions, please map to
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   122
    // TLS version firstly.  See ProtocolVersion.mapToTLSProtocol().
7039
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
   123
    final int obsoleted;
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
   124
30904
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   125
    // supported since protocol version (TLS version is used)
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   126
    //
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   127
    // TLS version is used.  If checking DTLS versions, please map to
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   128
    // TLS version firstly.  See ProtocolVersion.mapToTLSProtocol().
7043
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   129
    final int supported;
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   130
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   131
    /**
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   132
     * Constructor for implemented CipherSuites.
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   133
     */
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   134
    private CipherSuite(String name, int id, int priority,
29488
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
   135
            KeyExchange keyExchange, BulkCipher cipher, MacAlg mac,
7043
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   136
            boolean allowed, int obsoleted, int supported, PRF prfAlg) {
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   137
        this.name = name;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   138
        this.id = id;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   139
        this.priority = priority;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   140
        this.keyExchange = keyExchange;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   141
        this.cipher = cipher;
29488
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
   142
        this.macAlg = mac;
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   143
        this.exportable = cipher.exportable;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   144
        allowed &= keyExchange.allowed;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   145
        allowed &= cipher.allowed;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   146
        this.allowed = allowed;
7039
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
   147
        this.obsoleted = obsoleted;
7043
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   148
        this.supported = supported;
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   149
        this.prfAlg = prfAlg;
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   150
    }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   151
7043
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   152
    /**
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   153
     * Constructor for unimplemented CipherSuites.
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   154
     */
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   155
    private CipherSuite(String name, int id) {
90ce3da70b43 Initial load
duke
parents:
diff changeset
   156
        this.name = name;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   157
        this.id = id;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   158
        this.allowed = false;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   159
90ce3da70b43 Initial load
duke
parents:
diff changeset
   160
        this.priority = 0;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   161
        this.keyExchange = null;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   162
        this.cipher = null;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   163
        this.macAlg = null;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   164
        this.exportable = false;
7039
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
   165
        this.obsoleted = ProtocolVersion.LIMIT_MAX_VALUE;
7043
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   166
        this.supported = ProtocolVersion.LIMIT_MIN_VALUE;
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   167
        this.prfAlg = P_NONE;
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   168
    }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   169
90ce3da70b43 Initial load
duke
parents:
diff changeset
   170
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   171
     * Return whether this CipherSuite is available for use. A
90ce3da70b43 Initial load
duke
parents:
diff changeset
   172
     * CipherSuite may be unavailable even if it is supported
90ce3da70b43 Initial load
duke
parents:
diff changeset
   173
     * (i.e. allowed == true) if the required JCE cipher is not installed.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   174
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   175
    boolean isAvailable() {
90ce3da70b43 Initial load
duke
parents:
diff changeset
   176
        return allowed && keyExchange.isAvailable() && cipher.isAvailable();
90ce3da70b43 Initial load
duke
parents:
diff changeset
   177
    }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   178
6856
533f4ad71f88 6914943: Implement final TLS renegotiation fix
xuelei
parents: 5506
diff changeset
   179
    boolean isNegotiable() {
533f4ad71f88 6914943: Implement final TLS renegotiation fix
xuelei
parents: 5506
diff changeset
   180
        return this != C_SCSV && isAvailable();
533f4ad71f88 6914943: Implement final TLS renegotiation fix
xuelei
parents: 5506
diff changeset
   181
    }
533f4ad71f88 6914943: Implement final TLS renegotiation fix
xuelei
parents: 5506
diff changeset
   182
30904
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   183
    // See also CipherBox.calculatePacketSize().
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   184
    int calculatePacketSize(int fragmentSize,
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   185
            ProtocolVersion protocolVersion, boolean isDTLS) {
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   186
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   187
        int packetSize = fragmentSize;
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   188
        if (cipher != B_NULL) {
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   189
            int blockSize = cipher.ivSize;
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   190
            switch (cipher.cipherType) {
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   191
                case BLOCK_CIPHER:
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   192
                    packetSize += macAlg.size;
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   193
                    packetSize += 1;        // 1 byte padding length field
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   194
                    packetSize +=           // use the minimal padding
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   195
                            (blockSize - (packetSize % blockSize)) % blockSize;
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   196
                    if (protocolVersion.useTLS11PlusSpec()) {
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   197
                        packetSize += blockSize;        // explicit IV
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   198
                    }
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   199
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   200
                    break;
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   201
            case AEAD_CIPHER:
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   202
                packetSize += cipher.ivSize - cipher.fixedIvSize;   // record IV
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   203
                packetSize += cipher.tagSize;
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   204
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   205
                break;
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   206
            default:    // NULL_CIPHER or STREAM_CIPHER
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   207
                packetSize += macAlg.size;
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   208
            }
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   209
        }
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   210
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   211
        return packetSize +
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   212
            (isDTLS ? DTLSRecord.headerSize : SSLRecord.headerSize);
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   213
    }
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   214
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   215
    // See also CipherBox.calculateFragmentSize().
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   216
    int calculateFragSize(int packetLimit,
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   217
            ProtocolVersion protocolVersion, boolean isDTLS) {
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   218
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   219
        int fragSize = packetLimit -
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   220
                (isDTLS ? DTLSRecord.headerSize : SSLRecord.headerSize);
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   221
        if (cipher != B_NULL) {
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   222
            int blockSize = cipher.ivSize;
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   223
            switch (cipher.cipherType) {
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   224
            case BLOCK_CIPHER:
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   225
                if (protocolVersion.useTLS11PlusSpec()) {
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   226
                    fragSize -= blockSize;              // explicit IV
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   227
                }
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   228
                fragSize -= (fragSize % blockSize);     // cannot hold a block
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   229
                // No padding for a maximum fragment.
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   230
                fragSize -= 1;        // 1 byte padding length field: 0x00
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   231
                fragSize -= macAlg.size;
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   232
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   233
                break;
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   234
            case AEAD_CIPHER:
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   235
                fragSize -= cipher.tagSize;
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   236
                fragSize -= cipher.ivSize - cipher.fixedIvSize;     // record IV
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   237
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   238
                break;
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   239
            default:    // NULL_CIPHER or STREAM_CIPHER
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   240
                fragSize -= macAlg.size;
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   241
            }
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   242
        }
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   243
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   244
        return fragSize;
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   245
    }
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   246
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   247
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   248
     * Compares CipherSuites based on their priority. Has the effect of
90ce3da70b43 Initial load
duke
parents:
diff changeset
   249
     * sorting CipherSuites when put in a sorted collection, which is
90ce3da70b43 Initial load
duke
parents:
diff changeset
   250
     * used by CipherSuiteList. Follows standard Comparable contract.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   251
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   252
     * Note that for unsupported CipherSuites parsed from a handshake
90ce3da70b43 Initial load
duke
parents:
diff changeset
   253
     * message we violate the equals() contract.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   254
     */
14664
e71aa0962e70 8003950: Adds missing Override annotations and removes unnecessary imports in sun.security.ssl
xuelei
parents: 11904
diff changeset
   255
    @Override
10336
0bb1999251f8 7064075: Security libraries don't build with javac -Xlint:all,-deprecation -Werror
jjg
parents: 9035
diff changeset
   256
    public int compareTo(CipherSuite o) {
0bb1999251f8 7064075: Security libraries don't build with javac -Xlint:all,-deprecation -Werror
jjg
parents: 9035
diff changeset
   257
        return o.priority - priority;
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   258
    }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   259
90ce3da70b43 Initial load
duke
parents:
diff changeset
   260
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   261
     * Returns this.name.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   262
     */
14664
e71aa0962e70 8003950: Adds missing Override annotations and removes unnecessary imports in sun.security.ssl
xuelei
parents: 11904
diff changeset
   263
    @Override
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   264
    public String toString() {
90ce3da70b43 Initial load
duke
parents:
diff changeset
   265
        return name;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   266
    }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   267
90ce3da70b43 Initial load
duke
parents:
diff changeset
   268
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   269
     * Return a CipherSuite for the given name. The returned CipherSuite
90ce3da70b43 Initial load
duke
parents:
diff changeset
   270
     * is supported by this implementation but may not actually be
90ce3da70b43 Initial load
duke
parents:
diff changeset
   271
     * currently useable. See isAvailable().
90ce3da70b43 Initial load
duke
parents:
diff changeset
   272
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   273
     * @exception IllegalArgumentException if the CipherSuite is unknown or
90ce3da70b43 Initial load
duke
parents:
diff changeset
   274
     * unsupported.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   275
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   276
    static CipherSuite valueOf(String s) {
90ce3da70b43 Initial load
duke
parents:
diff changeset
   277
        if (s == null) {
90ce3da70b43 Initial load
duke
parents:
diff changeset
   278
            throw new IllegalArgumentException("Name must not be null");
90ce3da70b43 Initial load
duke
parents:
diff changeset
   279
        }
7039
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
   280
51
6fe31bc95bbc 6600143: Remove another 450 unnecessary casts
martin
parents: 2
diff changeset
   281
        CipherSuite c = nameMap.get(s);
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   282
        if ((c == null) || (c.allowed == false)) {
90ce3da70b43 Initial load
duke
parents:
diff changeset
   283
            throw new IllegalArgumentException("Unsupported ciphersuite " + s);
90ce3da70b43 Initial load
duke
parents:
diff changeset
   284
        }
7039
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
   285
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   286
        return c;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   287
    }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   288
90ce3da70b43 Initial load
duke
parents:
diff changeset
   289
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   290
     * Return a CipherSuite with the given ID. A temporary object is
90ce3da70b43 Initial load
duke
parents:
diff changeset
   291
     * constructed if the ID is unknown. Use isAvailable() to verify that
90ce3da70b43 Initial load
duke
parents:
diff changeset
   292
     * the CipherSuite can actually be used.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   293
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   294
    static CipherSuite valueOf(int id1, int id2) {
90ce3da70b43 Initial load
duke
parents:
diff changeset
   295
        id1 &= 0xff;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   296
        id2 &= 0xff;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   297
        int id = (id1 << 8) | id2;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   298
        CipherSuite c = idMap.get(id);
90ce3da70b43 Initial load
duke
parents:
diff changeset
   299
        if (c == null) {
90ce3da70b43 Initial load
duke
parents:
diff changeset
   300
            String h1 = Integer.toString(id1, 16);
90ce3da70b43 Initial load
duke
parents:
diff changeset
   301
            String h2 = Integer.toString(id2, 16);
90ce3da70b43 Initial load
duke
parents:
diff changeset
   302
            c = new CipherSuite("Unknown 0x" + h1 + ":0x" + h2, id);
90ce3da70b43 Initial load
duke
parents:
diff changeset
   303
        }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   304
        return c;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   305
    }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   306
30904
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   307
    // for use by SSLContextImpl only
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   308
    static Collection<CipherSuite> allowedCipherSuites() {
90ce3da70b43 Initial load
duke
parents:
diff changeset
   309
        return nameMap.values();
90ce3da70b43 Initial load
duke
parents:
diff changeset
   310
    }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   311
7043
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   312
    /*
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   313
     * Use this method when all of the values need to be specified.
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   314
     * This is primarily used when defining a new ciphersuite for
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   315
     * TLS 1.2+ that doesn't use the "default" PRF.
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   316
     */
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   317
    private static void add(String name, int id, int priority,
29488
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
   318
            KeyExchange keyExchange, BulkCipher cipher, MacAlg mac,
7043
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   319
            boolean allowed, int obsoleted, int supported, PRF prf) {
7039
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
   320
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   321
        CipherSuite c = new CipherSuite(name, id, priority, keyExchange,
29488
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
   322
            cipher, mac, allowed, obsoleted, supported, prf);
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   323
        if (idMap.put(id, c) != null) {
90ce3da70b43 Initial load
duke
parents:
diff changeset
   324
            throw new RuntimeException("Duplicate ciphersuite definition: "
90ce3da70b43 Initial load
duke
parents:
diff changeset
   325
                                        + id + ", " + name);
90ce3da70b43 Initial load
duke
parents:
diff changeset
   326
        }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   327
        if (c.allowed) {
90ce3da70b43 Initial load
duke
parents:
diff changeset
   328
            if (nameMap.put(name, c) != null) {
90ce3da70b43 Initial load
duke
parents:
diff changeset
   329
                throw new RuntimeException("Duplicate ciphersuite definition: "
90ce3da70b43 Initial load
duke
parents:
diff changeset
   330
                                            + id + ", " + name);
90ce3da70b43 Initial load
duke
parents:
diff changeset
   331
            }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   332
        }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   333
    }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   334
7043
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   335
    /*
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   336
     * Use this method when there is no lower protocol limit where this
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   337
     * suite can be used, and the PRF is P_SHA256.  That is, the
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   338
     * existing ciphersuites.  From RFC 5246:
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   339
     *
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   340
     *     All cipher suites in this document use P_SHA256.
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   341
     */
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   342
    private static void add(String name, int id, int priority,
29488
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
   343
            KeyExchange keyExchange, BulkCipher cipher, MacAlg mac,
7043
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   344
            boolean allowed, int obsoleted) {
29488
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
   345
        PRF prf = obsoleted < ProtocolVersion.TLS12.v ? P_NONE : P_SHA256;
7043
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   346
29488
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
   347
        add(name, id, priority, keyExchange, cipher, mac, allowed, obsoleted,
7043
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   348
            ProtocolVersion.LIMIT_MIN_VALUE, prf);
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   349
    }
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   350
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   351
    /*
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   352
     * Use this method when there is no upper protocol limit.  That is,
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   353
     * suites which have not been obsoleted.
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   354
     */
7039
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
   355
    private static void add(String name, int id, int priority,
29488
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
   356
            KeyExchange keyExchange, BulkCipher cipher, MacAlg mac,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
   357
            boolean allowed) {
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
   358
        add(name, id, priority, keyExchange, cipher, mac, allowed,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
   359
                ProtocolVersion.LIMIT_MAX_VALUE);
7039
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
   360
    }
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
   361
7043
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   362
    /*
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   363
     * Use this method to define an unimplemented suite.  This provides
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   364
     * a number<->name mapping that can be used for debugging.
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   365
     */
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   366
    private static void add(String name, int id) {
90ce3da70b43 Initial load
duke
parents:
diff changeset
   367
        CipherSuite c = new CipherSuite(name, id);
90ce3da70b43 Initial load
duke
parents:
diff changeset
   368
        if (idMap.put(id, c) != null) {
90ce3da70b43 Initial load
duke
parents:
diff changeset
   369
            throw new RuntimeException("Duplicate ciphersuite definition: "
90ce3da70b43 Initial load
duke
parents:
diff changeset
   370
                                        + id + ", " + name);
90ce3da70b43 Initial load
duke
parents:
diff changeset
   371
        }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   372
    }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   373
90ce3da70b43 Initial load
duke
parents:
diff changeset
   374
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   375
     * An SSL/TLS key exchange algorithm.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   376
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   377
    static enum KeyExchange {
90ce3da70b43 Initial load
duke
parents:
diff changeset
   378
90ce3da70b43 Initial load
duke
parents:
diff changeset
   379
        // key exchange algorithms
45064
b1b45177051b 8140436: Negotiated Finite Field Diffie-Hellman Ephemeral Parameters for TLS
xuelei
parents: 39563
diff changeset
   380
        K_NULL       ("NULL",       false,      NAMED_GROUP_NONE),
b1b45177051b 8140436: Negotiated Finite Field Diffie-Hellman Ephemeral Parameters for TLS
xuelei
parents: 39563
diff changeset
   381
        K_RSA        ("RSA",        true,       NAMED_GROUP_NONE),
b1b45177051b 8140436: Negotiated Finite Field Diffie-Hellman Ephemeral Parameters for TLS
xuelei
parents: 39563
diff changeset
   382
        K_RSA_EXPORT ("RSA_EXPORT", true,       NAMED_GROUP_NONE),
b1b45177051b 8140436: Negotiated Finite Field Diffie-Hellman Ephemeral Parameters for TLS
xuelei
parents: 39563
diff changeset
   383
        K_DH_RSA     ("DH_RSA",     false,      NAMED_GROUP_NONE),
b1b45177051b 8140436: Negotiated Finite Field Diffie-Hellman Ephemeral Parameters for TLS
xuelei
parents: 39563
diff changeset
   384
        K_DH_DSS     ("DH_DSS",     false,      NAMED_GROUP_NONE),
b1b45177051b 8140436: Negotiated Finite Field Diffie-Hellman Ephemeral Parameters for TLS
xuelei
parents: 39563
diff changeset
   385
        K_DHE_DSS    ("DHE_DSS",    true,       NAMED_GROUP_FFDHE),
b1b45177051b 8140436: Negotiated Finite Field Diffie-Hellman Ephemeral Parameters for TLS
xuelei
parents: 39563
diff changeset
   386
        K_DHE_RSA    ("DHE_RSA",    true,       NAMED_GROUP_FFDHE),
b1b45177051b 8140436: Negotiated Finite Field Diffie-Hellman Ephemeral Parameters for TLS
xuelei
parents: 39563
diff changeset
   387
        K_DH_ANON    ("DH_anon",    true,       NAMED_GROUP_FFDHE),
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   388
45064
b1b45177051b 8140436: Negotiated Finite Field Diffie-Hellman Ephemeral Parameters for TLS
xuelei
parents: 39563
diff changeset
   389
        K_ECDH_ECDSA ("ECDH_ECDSA",  ALLOW_ECC, NAMED_GROUP_ECDHE),
b1b45177051b 8140436: Negotiated Finite Field Diffie-Hellman Ephemeral Parameters for TLS
xuelei
parents: 39563
diff changeset
   390
        K_ECDH_RSA   ("ECDH_RSA",    ALLOW_ECC, NAMED_GROUP_ECDHE),
b1b45177051b 8140436: Negotiated Finite Field Diffie-Hellman Ephemeral Parameters for TLS
xuelei
parents: 39563
diff changeset
   391
        K_ECDHE_ECDSA("ECDHE_ECDSA", ALLOW_ECC, NAMED_GROUP_ECDHE),
b1b45177051b 8140436: Negotiated Finite Field Diffie-Hellman Ephemeral Parameters for TLS
xuelei
parents: 39563
diff changeset
   392
        K_ECDHE_RSA  ("ECDHE_RSA",   ALLOW_ECC, NAMED_GROUP_ECDHE),
b1b45177051b 8140436: Negotiated Finite Field Diffie-Hellman Ephemeral Parameters for TLS
xuelei
parents: 39563
diff changeset
   393
        K_ECDH_ANON  ("ECDH_anon",   ALLOW_ECC, NAMED_GROUP_ECDHE),
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   394
90ce3da70b43 Initial load
duke
parents:
diff changeset
   395
        // Kerberos cipher suites
45064
b1b45177051b 8140436: Negotiated Finite Field Diffie-Hellman Ephemeral Parameters for TLS
xuelei
parents: 39563
diff changeset
   396
        K_KRB5       ("KRB5", true,             NAMED_GROUP_NONE),
b1b45177051b 8140436: Negotiated Finite Field Diffie-Hellman Ephemeral Parameters for TLS
xuelei
parents: 39563
diff changeset
   397
        K_KRB5_EXPORT("KRB5_EXPORT", true,      NAMED_GROUP_NONE),
6856
533f4ad71f88 6914943: Implement final TLS renegotiation fix
xuelei
parents: 5506
diff changeset
   398
533f4ad71f88 6914943: Implement final TLS renegotiation fix
xuelei
parents: 5506
diff changeset
   399
        // renegotiation protection request signaling cipher suite
45064
b1b45177051b 8140436: Negotiated Finite Field Diffie-Hellman Ephemeral Parameters for TLS
xuelei
parents: 39563
diff changeset
   400
        K_SCSV       ("SCSV",        true,      NAMED_GROUP_NONE);
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   401
90ce3da70b43 Initial load
duke
parents:
diff changeset
   402
        // name of the key exchange algorithm, e.g. DHE_DSS
90ce3da70b43 Initial load
duke
parents:
diff changeset
   403
        final String name;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   404
        final boolean allowed;
45064
b1b45177051b 8140436: Negotiated Finite Field Diffie-Hellman Ephemeral Parameters for TLS
xuelei
parents: 39563
diff changeset
   405
        final NamedGroupType groupType;
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   406
        private final boolean alwaysAvailable;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   407
45064
b1b45177051b 8140436: Negotiated Finite Field Diffie-Hellman Ephemeral Parameters for TLS
xuelei
parents: 39563
diff changeset
   408
        KeyExchange(String name, boolean allowed, NamedGroupType groupType) {
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   409
            this.name = name;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   410
            this.allowed = allowed;
45064
b1b45177051b 8140436: Negotiated Finite Field Diffie-Hellman Ephemeral Parameters for TLS
xuelei
parents: 39563
diff changeset
   411
            this.groupType = groupType;
3957
c8fdb8fad795 6885204: JSSE should not require Kerberos to be present
vinnie
parents: 715
diff changeset
   412
            this.alwaysAvailable = allowed &&
c8fdb8fad795 6885204: JSSE should not require Kerberos to be present
vinnie
parents: 715
diff changeset
   413
                (!name.startsWith("EC")) && (!name.startsWith("KRB"));
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   414
        }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   415
90ce3da70b43 Initial load
duke
parents:
diff changeset
   416
        boolean isAvailable() {
90ce3da70b43 Initial load
duke
parents:
diff changeset
   417
            if (alwaysAvailable) {
90ce3da70b43 Initial load
duke
parents:
diff changeset
   418
                return true;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   419
            }
3957
c8fdb8fad795 6885204: JSSE should not require Kerberos to be present
vinnie
parents: 715
diff changeset
   420
45064
b1b45177051b 8140436: Negotiated Finite Field Diffie-Hellman Ephemeral Parameters for TLS
xuelei
parents: 39563
diff changeset
   421
            if (groupType == NAMED_GROUP_ECDHE) {
3957
c8fdb8fad795 6885204: JSSE should not require Kerberos to be present
vinnie
parents: 715
diff changeset
   422
                return (allowed && JsseJce.isEcAvailable());
c8fdb8fad795 6885204: JSSE should not require Kerberos to be present
vinnie
parents: 715
diff changeset
   423
            } else if (name.startsWith("KRB")) {
c8fdb8fad795 6885204: JSSE should not require Kerberos to be present
vinnie
parents: 715
diff changeset
   424
                return (allowed && JsseJce.isKerberosAvailable());
c8fdb8fad795 6885204: JSSE should not require Kerberos to be present
vinnie
parents: 715
diff changeset
   425
            } else {
c8fdb8fad795 6885204: JSSE should not require Kerberos to be present
vinnie
parents: 715
diff changeset
   426
                return allowed;
c8fdb8fad795 6885204: JSSE should not require Kerberos to be present
vinnie
parents: 715
diff changeset
   427
            }
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   428
        }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   429
14664
e71aa0962e70 8003950: Adds missing Override annotations and removes unnecessary imports in sun.security.ssl
xuelei
parents: 11904
diff changeset
   430
        @Override
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   431
        public String toString() {
90ce3da70b43 Initial load
duke
parents:
diff changeset
   432
            return name;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   433
        }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   434
    }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   435
16913
a6f4d1626ad9 8011680: Re-integrate AEAD implementation of JSSE
xuelei
parents: 16126
diff changeset
   436
    static enum CipherType {
30904
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   437
        NULL_CIPHER,           // null cipher
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   438
        STREAM_CIPHER,         // stream cipher
16913
a6f4d1626ad9 8011680: Re-integrate AEAD implementation of JSSE
xuelei
parents: 16126
diff changeset
   439
        BLOCK_CIPHER,          // block cipher in CBC mode
a6f4d1626ad9 8011680: Re-integrate AEAD implementation of JSSE
xuelei
parents: 16126
diff changeset
   440
        AEAD_CIPHER            // AEAD cipher
a6f4d1626ad9 8011680: Re-integrate AEAD implementation of JSSE
xuelei
parents: 16126
diff changeset
   441
    }
a6f4d1626ad9 8011680: Re-integrate AEAD implementation of JSSE
xuelei
parents: 16126
diff changeset
   442
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   443
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   444
     * An SSL/TLS bulk cipher algorithm. One instance per combination of
90ce3da70b43 Initial load
duke
parents:
diff changeset
   445
     * cipher and key length.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   446
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   447
     * Also contains a factory method to obtain in initialized CipherBox
90ce3da70b43 Initial load
duke
parents:
diff changeset
   448
     * for this algorithm.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   449
     */
29488
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
   450
    static enum BulkCipher {
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
   451
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
   452
        // export strength ciphers
30904
ec0224270f90 8043758: Datagram Transport Layer Security (DTLS)
xuelei
parents: 29488
diff changeset
   453
        B_NULL("NULL", NULL_CIPHER, 0, 0, 0, 0, true),
29488
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
   454
        B_RC4_40(CIPHER_RC4, STREAM_CIPHER, 5, 16, 0, 0, true),
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
   455
        B_RC2_40("RC2", BLOCK_CIPHER, 5, 16, 8, 0, false),
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
   456
        B_DES_40(CIPHER_DES,  BLOCK_CIPHER, 5, 8, 8, 0, true),
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
   457
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
   458
        // domestic strength ciphers
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
   459
        B_RC4_128(CIPHER_RC4, STREAM_CIPHER, 16, 0, 0, true),
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
   460
        B_DES(CIPHER_DES, BLOCK_CIPHER, 8, 8, 0, true),
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
   461
        B_3DES(CIPHER_3DES, BLOCK_CIPHER, 24, 8, 0, true),
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
   462
        B_IDEA("IDEA", BLOCK_CIPHER, 16, 8, 0, false),
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
   463
        B_AES_128(CIPHER_AES, BLOCK_CIPHER, 16, 16, 0, true),
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
   464
        B_AES_256(CIPHER_AES, BLOCK_CIPHER, 32, 16, 0, true),
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
   465
        B_AES_128_GCM(CIPHER_AES_GCM, AEAD_CIPHER, 16, 12, 4, true),
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
   466
        B_AES_256_GCM(CIPHER_AES_GCM, AEAD_CIPHER, 32, 12, 4, true);
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   467
90ce3da70b43 Initial load
duke
parents:
diff changeset
   468
        // descriptive name including key size, e.g. AES/128
90ce3da70b43 Initial load
duke
parents:
diff changeset
   469
        final String description;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   470
90ce3da70b43 Initial load
duke
parents:
diff changeset
   471
        // JCE cipher transformation string, e.g. AES/CBC/NoPadding
90ce3da70b43 Initial load
duke
parents:
diff changeset
   472
        final String transformation;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   473
90ce3da70b43 Initial load
duke
parents:
diff changeset
   474
        // algorithm name, e.g. AES
90ce3da70b43 Initial load
duke
parents:
diff changeset
   475
        final String algorithm;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   476
90ce3da70b43 Initial load
duke
parents:
diff changeset
   477
        // supported and compile time enabled. Also see isAvailable()
90ce3da70b43 Initial load
duke
parents:
diff changeset
   478
        final boolean allowed;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   479
90ce3da70b43 Initial load
duke
parents:
diff changeset
   480
        // number of bytes of entropy in the key
90ce3da70b43 Initial load
duke
parents:
diff changeset
   481
        final int keySize;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   482
90ce3da70b43 Initial load
duke
parents:
diff changeset
   483
        // length of the actual cipher key in bytes.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   484
        // for non-exportable ciphers, this is the same as keySize
90ce3da70b43 Initial load
duke
parents:
diff changeset
   485
        final int expandedKeySize;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   486
16913
a6f4d1626ad9 8011680: Re-integrate AEAD implementation of JSSE
xuelei
parents: 16126
diff changeset
   487
        // size of the IV
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   488
        final int ivSize;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   489
16913
a6f4d1626ad9 8011680: Re-integrate AEAD implementation of JSSE
xuelei
parents: 16126
diff changeset
   490
        // size of fixed IV
a6f4d1626ad9 8011680: Re-integrate AEAD implementation of JSSE
xuelei
parents: 16126
diff changeset
   491
        //
a6f4d1626ad9 8011680: Re-integrate AEAD implementation of JSSE
xuelei
parents: 16126
diff changeset
   492
        // record_iv_length = ivSize - fixedIvSize
a6f4d1626ad9 8011680: Re-integrate AEAD implementation of JSSE
xuelei
parents: 16126
diff changeset
   493
        final int fixedIvSize;
a6f4d1626ad9 8011680: Re-integrate AEAD implementation of JSSE
xuelei
parents: 16126
diff changeset
   494
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   495
        // exportable under 512/40 bit rules
90ce3da70b43 Initial load
duke
parents:
diff changeset
   496
        final boolean exportable;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   497
10915
1e20964cebf3 7064341: jsse/runtime security problem
xuelei
parents: 9035
diff changeset
   498
        // Is the cipher algorithm of Cipher Block Chaining (CBC) mode?
16913
a6f4d1626ad9 8011680: Re-integrate AEAD implementation of JSSE
xuelei
parents: 16126
diff changeset
   499
        final CipherType cipherType;
a6f4d1626ad9 8011680: Re-integrate AEAD implementation of JSSE
xuelei
parents: 16126
diff changeset
   500
a6f4d1626ad9 8011680: Re-integrate AEAD implementation of JSSE
xuelei
parents: 16126
diff changeset
   501
        // size of the authentication tag, only applicable to cipher suites in
a6f4d1626ad9 8011680: Re-integrate AEAD implementation of JSSE
xuelei
parents: 16126
diff changeset
   502
        // Galois Counter Mode (GCM)
a6f4d1626ad9 8011680: Re-integrate AEAD implementation of JSSE
xuelei
parents: 16126
diff changeset
   503
        //
a6f4d1626ad9 8011680: Re-integrate AEAD implementation of JSSE
xuelei
parents: 16126
diff changeset
   504
        // As far as we know, all supported GCM cipher suites use 128-bits
a6f4d1626ad9 8011680: Re-integrate AEAD implementation of JSSE
xuelei
parents: 16126
diff changeset
   505
        // authentication tags.
a6f4d1626ad9 8011680: Re-integrate AEAD implementation of JSSE
xuelei
parents: 16126
diff changeset
   506
        final int tagSize = 16;
10915
1e20964cebf3 7064341: jsse/runtime security problem
xuelei
parents: 9035
diff changeset
   507
11904
f0eca4f34170 7145837: a little performance improvement on the usage of SecureRandom
xuelei
parents: 10917
diff changeset
   508
        // The secure random used to detect the cipher availability.
32649
2ee9017c7597 8136583: Core libraries should use blessed modifier order
martin
parents: 31706
diff changeset
   509
        private static final SecureRandom secureRandom;
11904
f0eca4f34170 7145837: a little performance improvement on the usage of SecureRandom
xuelei
parents: 10917
diff changeset
   510
34826
4bbdce2630f8 8133070: Hot lock on BulkCipher.isAvailable
xuelei
parents: 34380
diff changeset
   511
        // runtime availability
4bbdce2630f8 8133070: Hot lock on BulkCipher.isAvailable
xuelei
parents: 34380
diff changeset
   512
        private final boolean isAvailable;
4bbdce2630f8 8133070: Hot lock on BulkCipher.isAvailable
xuelei
parents: 34380
diff changeset
   513
11904
f0eca4f34170 7145837: a little performance improvement on the usage of SecureRandom
xuelei
parents: 10917
diff changeset
   514
        static {
f0eca4f34170 7145837: a little performance improvement on the usage of SecureRandom
xuelei
parents: 10917
diff changeset
   515
            try {
f0eca4f34170 7145837: a little performance improvement on the usage of SecureRandom
xuelei
parents: 10917
diff changeset
   516
                secureRandom = JsseJce.getSecureRandom();
f0eca4f34170 7145837: a little performance improvement on the usage of SecureRandom
xuelei
parents: 10917
diff changeset
   517
            } catch (KeyManagementException kme) {
f0eca4f34170 7145837: a little performance improvement on the usage of SecureRandom
xuelei
parents: 10917
diff changeset
   518
                throw new RuntimeException(kme);
f0eca4f34170 7145837: a little performance improvement on the usage of SecureRandom
xuelei
parents: 10917
diff changeset
   519
            }
f0eca4f34170 7145837: a little performance improvement on the usage of SecureRandom
xuelei
parents: 10917
diff changeset
   520
        }
f0eca4f34170 7145837: a little performance improvement on the usage of SecureRandom
xuelei
parents: 10917
diff changeset
   521
16913
a6f4d1626ad9 8011680: Re-integrate AEAD implementation of JSSE
xuelei
parents: 16126
diff changeset
   522
        BulkCipher(String transformation, CipherType cipherType, int keySize,
a6f4d1626ad9 8011680: Re-integrate AEAD implementation of JSSE
xuelei
parents: 16126
diff changeset
   523
                int expandedKeySize, int ivSize,
a6f4d1626ad9 8011680: Re-integrate AEAD implementation of JSSE
xuelei
parents: 16126
diff changeset
   524
                int fixedIvSize, boolean allowed) {
a6f4d1626ad9 8011680: Re-integrate AEAD implementation of JSSE
xuelei
parents: 16126
diff changeset
   525
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   526
            this.transformation = transformation;
10915
1e20964cebf3 7064341: jsse/runtime security problem
xuelei
parents: 9035
diff changeset
   527
            String[] splits = transformation.split("/");
1e20964cebf3 7064341: jsse/runtime security problem
xuelei
parents: 9035
diff changeset
   528
            this.algorithm = splits[0];
16913
a6f4d1626ad9 8011680: Re-integrate AEAD implementation of JSSE
xuelei
parents: 16126
diff changeset
   529
            this.cipherType = cipherType;
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   530
            this.description = this.algorithm + "/" + (keySize << 3);
90ce3da70b43 Initial load
duke
parents:
diff changeset
   531
            this.keySize = keySize;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   532
            this.ivSize = ivSize;
16913
a6f4d1626ad9 8011680: Re-integrate AEAD implementation of JSSE
xuelei
parents: 16126
diff changeset
   533
            this.fixedIvSize = fixedIvSize;
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   534
            this.allowed = allowed;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   535
90ce3da70b43 Initial load
duke
parents:
diff changeset
   536
            this.expandedKeySize = expandedKeySize;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   537
            this.exportable = true;
34826
4bbdce2630f8 8133070: Hot lock on BulkCipher.isAvailable
xuelei
parents: 34380
diff changeset
   538
4bbdce2630f8 8133070: Hot lock on BulkCipher.isAvailable
xuelei
parents: 34380
diff changeset
   539
            // availability of this bulk cipher
4bbdce2630f8 8133070: Hot lock on BulkCipher.isAvailable
xuelei
parents: 34380
diff changeset
   540
            //
4bbdce2630f8 8133070: Hot lock on BulkCipher.isAvailable
xuelei
parents: 34380
diff changeset
   541
            // Currently all supported ciphers except AES are always available
4bbdce2630f8 8133070: Hot lock on BulkCipher.isAvailable
xuelei
parents: 34380
diff changeset
   542
            // via the JSSE internal implementations. We also assume AES/128 of
4bbdce2630f8 8133070: Hot lock on BulkCipher.isAvailable
xuelei
parents: 34380
diff changeset
   543
            // CBC mode is always available since it is shipped with the SunJCE
4bbdce2630f8 8133070: Hot lock on BulkCipher.isAvailable
xuelei
parents: 34380
diff changeset
   544
            // provider.  However, AES/256 is unavailable when the default JCE
4bbdce2630f8 8133070: Hot lock on BulkCipher.isAvailable
xuelei
parents: 34380
diff changeset
   545
            // policy jurisdiction files are installed because of key length
4bbdce2630f8 8133070: Hot lock on BulkCipher.isAvailable
xuelei
parents: 34380
diff changeset
   546
            // restrictions.
4bbdce2630f8 8133070: Hot lock on BulkCipher.isAvailable
xuelei
parents: 34380
diff changeset
   547
            this.isAvailable =
4bbdce2630f8 8133070: Hot lock on BulkCipher.isAvailable
xuelei
parents: 34380
diff changeset
   548
                    allowed ? isUnlimited(keySize, transformation) : false;
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   549
        }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   550
16913
a6f4d1626ad9 8011680: Re-integrate AEAD implementation of JSSE
xuelei
parents: 16126
diff changeset
   551
        BulkCipher(String transformation, CipherType cipherType, int keySize,
a6f4d1626ad9 8011680: Re-integrate AEAD implementation of JSSE
xuelei
parents: 16126
diff changeset
   552
                int ivSize, int fixedIvSize, boolean allowed) {
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   553
            this.transformation = transformation;
10915
1e20964cebf3 7064341: jsse/runtime security problem
xuelei
parents: 9035
diff changeset
   554
            String[] splits = transformation.split("/");
1e20964cebf3 7064341: jsse/runtime security problem
xuelei
parents: 9035
diff changeset
   555
            this.algorithm = splits[0];
16913
a6f4d1626ad9 8011680: Re-integrate AEAD implementation of JSSE
xuelei
parents: 16126
diff changeset
   556
            this.cipherType = cipherType;
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   557
            this.description = this.algorithm + "/" + (keySize << 3);
90ce3da70b43 Initial load
duke
parents:
diff changeset
   558
            this.keySize = keySize;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   559
            this.ivSize = ivSize;
16913
a6f4d1626ad9 8011680: Re-integrate AEAD implementation of JSSE
xuelei
parents: 16126
diff changeset
   560
            this.fixedIvSize = fixedIvSize;
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   561
            this.allowed = allowed;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   562
90ce3da70b43 Initial load
duke
parents:
diff changeset
   563
            this.expandedKeySize = keySize;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   564
            this.exportable = false;
34826
4bbdce2630f8 8133070: Hot lock on BulkCipher.isAvailable
xuelei
parents: 34380
diff changeset
   565
4bbdce2630f8 8133070: Hot lock on BulkCipher.isAvailable
xuelei
parents: 34380
diff changeset
   566
            // availability of this bulk cipher
4bbdce2630f8 8133070: Hot lock on BulkCipher.isAvailable
xuelei
parents: 34380
diff changeset
   567
            //
4bbdce2630f8 8133070: Hot lock on BulkCipher.isAvailable
xuelei
parents: 34380
diff changeset
   568
            // Currently all supported ciphers except AES are always available
4bbdce2630f8 8133070: Hot lock on BulkCipher.isAvailable
xuelei
parents: 34380
diff changeset
   569
            // via the JSSE internal implementations. We also assume AES/128 of
4bbdce2630f8 8133070: Hot lock on BulkCipher.isAvailable
xuelei
parents: 34380
diff changeset
   570
            // CBC mode is always available since it is shipped with the SunJCE
4bbdce2630f8 8133070: Hot lock on BulkCipher.isAvailable
xuelei
parents: 34380
diff changeset
   571
            // provider.  However, AES/256 is unavailable when the default JCE
4bbdce2630f8 8133070: Hot lock on BulkCipher.isAvailable
xuelei
parents: 34380
diff changeset
   572
            // policy jurisdiction files are installed because of key length
4bbdce2630f8 8133070: Hot lock on BulkCipher.isAvailable
xuelei
parents: 34380
diff changeset
   573
            // restrictions.
4bbdce2630f8 8133070: Hot lock on BulkCipher.isAvailable
xuelei
parents: 34380
diff changeset
   574
            this.isAvailable =
4bbdce2630f8 8133070: Hot lock on BulkCipher.isAvailable
xuelei
parents: 34380
diff changeset
   575
                    allowed ? isUnlimited(keySize, transformation) : false;
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   576
        }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   577
90ce3da70b43 Initial load
duke
parents:
diff changeset
   578
        /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   579
         * Return an initialized CipherBox for this BulkCipher.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   580
         * IV must be null for stream ciphers.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   581
         *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   582
         * @exception NoSuchAlgorithmException if anything goes wrong
90ce3da70b43 Initial load
duke
parents:
diff changeset
   583
         */
7039
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
   584
        CipherBox newCipher(ProtocolVersion version, SecretKey key,
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
   585
                IvParameterSpec iv, SecureRandom random,
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   586
                boolean encrypt) throws NoSuchAlgorithmException {
7039
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
   587
            return CipherBox.newCipherBox(version, this,
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
   588
                                            key, iv, random, encrypt);
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   589
        }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   590
90ce3da70b43 Initial load
duke
parents:
diff changeset
   591
        /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   592
         * Test if this bulk cipher is available. For use by CipherSuite.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   593
         */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   594
        boolean isAvailable() {
34826
4bbdce2630f8 8133070: Hot lock on BulkCipher.isAvailable
xuelei
parents: 34380
diff changeset
   595
            return this.isAvailable;
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   596
        }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   597
34826
4bbdce2630f8 8133070: Hot lock on BulkCipher.isAvailable
xuelei
parents: 34380
diff changeset
   598
        private static boolean isUnlimited(int keySize, String transformation) {
4bbdce2630f8 8133070: Hot lock on BulkCipher.isAvailable
xuelei
parents: 34380
diff changeset
   599
            int keySizeInBits = keySize * 8;
4bbdce2630f8 8133070: Hot lock on BulkCipher.isAvailable
xuelei
parents: 34380
diff changeset
   600
            if (keySizeInBits > 128) {    // need the JCE unlimited
4bbdce2630f8 8133070: Hot lock on BulkCipher.isAvailable
xuelei
parents: 34380
diff changeset
   601
                                          // strength jurisdiction policy
4bbdce2630f8 8133070: Hot lock on BulkCipher.isAvailable
xuelei
parents: 34380
diff changeset
   602
                try {
4bbdce2630f8 8133070: Hot lock on BulkCipher.isAvailable
xuelei
parents: 34380
diff changeset
   603
                    if (Cipher.getMaxAllowedKeyLength(
4bbdce2630f8 8133070: Hot lock on BulkCipher.isAvailable
xuelei
parents: 34380
diff changeset
   604
                            transformation) < keySizeInBits) {
16913
a6f4d1626ad9 8011680: Re-integrate AEAD implementation of JSSE
xuelei
parents: 16126
diff changeset
   605
34826
4bbdce2630f8 8133070: Hot lock on BulkCipher.isAvailable
xuelei
parents: 34380
diff changeset
   606
                        return false;
16913
a6f4d1626ad9 8011680: Re-integrate AEAD implementation of JSSE
xuelei
parents: 16126
diff changeset
   607
                    }
34826
4bbdce2630f8 8133070: Hot lock on BulkCipher.isAvailable
xuelei
parents: 34380
diff changeset
   608
                } catch (Exception e) {
4bbdce2630f8 8133070: Hot lock on BulkCipher.isAvailable
xuelei
parents: 34380
diff changeset
   609
                    return false;
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   610
                }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   611
            }
16913
a6f4d1626ad9 8011680: Re-integrate AEAD implementation of JSSE
xuelei
parents: 16126
diff changeset
   612
34826
4bbdce2630f8 8133070: Hot lock on BulkCipher.isAvailable
xuelei
parents: 34380
diff changeset
   613
            return true;
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   614
        }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   615
14664
e71aa0962e70 8003950: Adds missing Override annotations and removes unnecessary imports in sun.security.ssl
xuelei
parents: 11904
diff changeset
   616
        @Override
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   617
        public String toString() {
90ce3da70b43 Initial load
duke
parents:
diff changeset
   618
            return description;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   619
        }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   620
    }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   621
90ce3da70b43 Initial load
duke
parents:
diff changeset
   622
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   623
     * An SSL/TLS key MAC algorithm.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   624
     *
7043
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   625
     * Also contains a factory method to obtain an initialized MAC
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   626
     * for this algorithm.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   627
     */
29488
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
   628
    static enum MacAlg {
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
   629
        // MACs
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
   630
        M_NULL      ("NULL",     0,   0,   0),
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
   631
        M_MD5       ("MD5",     16,  64,   9),
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
   632
        M_SHA       ("SHA",     20,  64,   9),
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
   633
        M_SHA256    ("SHA256",  32,  64,   9),
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
   634
        M_SHA384    ("SHA384",  48, 128,  17);
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   635
90ce3da70b43 Initial load
duke
parents:
diff changeset
   636
        // descriptive name, e.g. MD5
90ce3da70b43 Initial load
duke
parents:
diff changeset
   637
        final String name;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   638
90ce3da70b43 Initial load
duke
parents:
diff changeset
   639
        // size of the MAC value (and MAC key) in bytes
90ce3da70b43 Initial load
duke
parents:
diff changeset
   640
        final int size;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   641
16113
946ec9b22004 8006777: Improve TLS handling of invalid messages
xuelei
parents: 14664
diff changeset
   642
        // block size of the underlying hash algorithm
946ec9b22004 8006777: Improve TLS handling of invalid messages
xuelei
parents: 14664
diff changeset
   643
        final int hashBlockSize;
946ec9b22004 8006777: Improve TLS handling of invalid messages
xuelei
parents: 14664
diff changeset
   644
946ec9b22004 8006777: Improve TLS handling of invalid messages
xuelei
parents: 14664
diff changeset
   645
        // minimal padding size of the underlying hash algorithm
946ec9b22004 8006777: Improve TLS handling of invalid messages
xuelei
parents: 14664
diff changeset
   646
        final int minimalPaddingSize;
946ec9b22004 8006777: Improve TLS handling of invalid messages
xuelei
parents: 14664
diff changeset
   647
946ec9b22004 8006777: Improve TLS handling of invalid messages
xuelei
parents: 14664
diff changeset
   648
        MacAlg(String name, int size,
946ec9b22004 8006777: Improve TLS handling of invalid messages
xuelei
parents: 14664
diff changeset
   649
                int hashBlockSize, int minimalPaddingSize) {
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   650
            this.name = name;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   651
            this.size = size;
16113
946ec9b22004 8006777: Improve TLS handling of invalid messages
xuelei
parents: 14664
diff changeset
   652
            this.hashBlockSize = hashBlockSize;
946ec9b22004 8006777: Improve TLS handling of invalid messages
xuelei
parents: 14664
diff changeset
   653
            this.minimalPaddingSize = minimalPaddingSize;
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   654
        }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   655
90ce3da70b43 Initial load
duke
parents:
diff changeset
   656
        /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   657
         * Return an initialized MAC for this MacAlg. ProtocolVersion
90ce3da70b43 Initial load
duke
parents:
diff changeset
   658
         * must either be SSL30 (SSLv3 custom MAC) or TLS10 (std. HMAC).
90ce3da70b43 Initial load
duke
parents:
diff changeset
   659
         *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   660
         * @exception NoSuchAlgorithmException if anything goes wrong
90ce3da70b43 Initial load
duke
parents:
diff changeset
   661
         */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   662
        MAC newMac(ProtocolVersion protocolVersion, SecretKey secret)
90ce3da70b43 Initial load
duke
parents:
diff changeset
   663
                throws NoSuchAlgorithmException, InvalidKeyException {
90ce3da70b43 Initial load
duke
parents:
diff changeset
   664
            return new MAC(this, protocolVersion, secret);
90ce3da70b43 Initial load
duke
parents:
diff changeset
   665
        }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   666
14664
e71aa0962e70 8003950: Adds missing Override annotations and removes unnecessary imports in sun.security.ssl
xuelei
parents: 11904
diff changeset
   667
        @Override
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   668
        public String toString() {
90ce3da70b43 Initial load
duke
parents:
diff changeset
   669
            return name;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   670
        }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   671
    }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   672
7807
d026f4f9c119 6996365: Evaluate the priorities of cipher suites
xuelei
parents: 7043
diff changeset
   673
    /**
d026f4f9c119 6996365: Evaluate the priorities of cipher suites
xuelei
parents: 7043
diff changeset
   674
     * PRFs (PseudoRandom Function) from TLS specifications.
d026f4f9c119 6996365: Evaluate the priorities of cipher suites
xuelei
parents: 7043
diff changeset
   675
     *
d026f4f9c119 6996365: Evaluate the priorities of cipher suites
xuelei
parents: 7043
diff changeset
   676
     * TLS 1.1- uses a single MD5/SHA1-based PRF algorithm for generating
d026f4f9c119 6996365: Evaluate the priorities of cipher suites
xuelei
parents: 7043
diff changeset
   677
     * the necessary material.
d026f4f9c119 6996365: Evaluate the priorities of cipher suites
xuelei
parents: 7043
diff changeset
   678
     *
d026f4f9c119 6996365: Evaluate the priorities of cipher suites
xuelei
parents: 7043
diff changeset
   679
     * In TLS 1.2+, all existing/known CipherSuites use SHA256, however
d026f4f9c119 6996365: Evaluate the priorities of cipher suites
xuelei
parents: 7043
diff changeset
   680
     * new Ciphersuites (e.g. RFC 5288) can define specific PRF hash
d026f4f9c119 6996365: Evaluate the priorities of cipher suites
xuelei
parents: 7043
diff changeset
   681
     * algorithms.
d026f4f9c119 6996365: Evaluate the priorities of cipher suites
xuelei
parents: 7043
diff changeset
   682
     */
7043
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   683
    static enum PRF {
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   684
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   685
        // PRF algorithms
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   686
        P_NONE(     "NONE",  0,   0),
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   687
        P_SHA256("SHA-256", 32,  64),
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   688
        P_SHA384("SHA-384", 48, 128),
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   689
        P_SHA512("SHA-512", 64, 128);  // not currently used.
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   690
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   691
        // PRF characteristics
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   692
        private final String prfHashAlg;
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   693
        private final int prfHashLength;
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   694
        private final int prfBlockSize;
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   695
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   696
        PRF(String prfHashAlg, int prfHashLength, int prfBlockSize) {
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   697
            this.prfHashAlg = prfHashAlg;
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   698
            this.prfHashLength = prfHashLength;
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   699
            this.prfBlockSize = prfBlockSize;
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   700
        }
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   701
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   702
        String getPRFHashAlg() {
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   703
            return prfHashAlg;
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   704
        }
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   705
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   706
        int getPRFHashLength() {
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   707
            return prfHashLength;
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   708
        }
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   709
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   710
        int getPRFBlockSize() {
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   711
            return prfBlockSize;
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   712
        }
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
   713
    }
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   714
90ce3da70b43 Initial load
duke
parents:
diff changeset
   715
    static {
90ce3da70b43 Initial load
duke
parents:
diff changeset
   716
        idMap = new HashMap<Integer,CipherSuite>();
90ce3da70b43 Initial load
duke
parents:
diff changeset
   717
        nameMap = new HashMap<String,CipherSuite>();
90ce3da70b43 Initial load
duke
parents:
diff changeset
   718
90ce3da70b43 Initial load
duke
parents:
diff changeset
   719
        final boolean F = false;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   720
        final boolean T = true;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   721
        // N: ciphersuites only allowed if we are not in FIPS mode
90ce3da70b43 Initial load
duke
parents:
diff changeset
   722
        final boolean N = (SunJSSE.isFIPS() == false);
90ce3da70b43 Initial load
duke
parents:
diff changeset
   723
7039
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
   724
        /*
34380
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   725
         * TLS Cipher Suite Registry, as of November 2015.
7039
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
   726
         *
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
   727
         * http://www.iana.org/assignments/tls-parameters/tls-parameters.xml
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
   728
         *
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
   729
         * Range      Registration Procedures   Notes
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
   730
         * 000-191    Standards Action          Refers to value of first byte
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
   731
         * 192-254    Specification Required    Refers to value of first byte
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
   732
         * 255        Reserved for Private Use  Refers to value of first byte
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
   733
         *
34380
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   734
         * Value      Description                                   Reference
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   735
         * 0x00,0x00  TLS_NULL_WITH_NULL_NULL                       [RFC5246]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   736
         * 0x00,0x01  TLS_RSA_WITH_NULL_MD5                         [RFC5246]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   737
         * 0x00,0x02  TLS_RSA_WITH_NULL_SHA                         [RFC5246]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   738
         * 0x00,0x03  TLS_RSA_EXPORT_WITH_RC4_40_MD5                [RFC4346]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   739
         * 0x00,0x04  TLS_RSA_WITH_RC4_128_MD5                      [RFC5246]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   740
         * 0x00,0x05  TLS_RSA_WITH_RC4_128_SHA                      [RFC5246]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   741
         * 0x00,0x06  TLS_RSA_EXPORT_WITH_RC2_CBC_40_MD5            [RFC4346]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   742
         * 0x00,0x07  TLS_RSA_WITH_IDEA_CBC_SHA                     [RFC5469]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   743
         * 0x00,0x08  TLS_RSA_EXPORT_WITH_DES40_CBC_SHA             [RFC4346]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   744
         * 0x00,0x09  TLS_RSA_WITH_DES_CBC_SHA                      [RFC5469]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   745
         * 0x00,0x0A  TLS_RSA_WITH_3DES_EDE_CBC_SHA                 [RFC5246]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   746
         * 0x00,0x0B  TLS_DH_DSS_EXPORT_WITH_DES40_CBC_SHA          [RFC4346]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   747
         * 0x00,0x0C  TLS_DH_DSS_WITH_DES_CBC_SHA                   [RFC5469]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   748
         * 0x00,0x0D  TLS_DH_DSS_WITH_3DES_EDE_CBC_SHA              [RFC5246]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   749
         * 0x00,0x0E  TLS_DH_RSA_EXPORT_WITH_DES40_CBC_SHA          [RFC4346]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   750
         * 0x00,0x0F  TLS_DH_RSA_WITH_DES_CBC_SHA                   [RFC5469]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   751
         * 0x00,0x10  TLS_DH_RSA_WITH_3DES_EDE_CBC_SHA              [RFC5246]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   752
         * 0x00,0x11  TLS_DHE_DSS_EXPORT_WITH_DES40_CBC_SHA         [RFC4346]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   753
         * 0x00,0x12  TLS_DHE_DSS_WITH_DES_CBC_SHA                  [RFC5469]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   754
         * 0x00,0x13  TLS_DHE_DSS_WITH_3DES_EDE_CBC_SHA             [RFC5246]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   755
         * 0x00,0x14  TLS_DHE_RSA_EXPORT_WITH_DES40_CBC_SHA         [RFC4346]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   756
         * 0x00,0x15  TLS_DHE_RSA_WITH_DES_CBC_SHA                  [RFC5469]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   757
         * 0x00,0x16  TLS_DHE_RSA_WITH_3DES_EDE_CBC_SHA             [RFC5246]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   758
         * 0x00,0x17  TLS_DH_anon_EXPORT_WITH_RC4_40_MD5            [RFC4346]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   759
         * 0x00,0x18  TLS_DH_anon_WITH_RC4_128_MD5                  [RFC5246]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   760
         * 0x00,0x19  TLS_DH_anon_EXPORT_WITH_DES40_CBC_SHA         [RFC4346]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   761
         * 0x00,0x1A  TLS_DH_anon_WITH_DES_CBC_SHA                  [RFC5469]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   762
         * 0x00,0x1B  TLS_DH_anon_WITH_3DES_EDE_CBC_SHA             [RFC5246]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   763
         * 0x00,0x1C-1D Reserved to avoid conflicts with SSLv3      [RFC5246]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   764
         * 0x00,0x1E  TLS_KRB5_WITH_DES_CBC_SHA                     [RFC2712]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   765
         * 0x00,0x1F  TLS_KRB5_WITH_3DES_EDE_CBC_SHA                [RFC2712]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   766
         * 0x00,0x20  TLS_KRB5_WITH_RC4_128_SHA                     [RFC2712]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   767
         * 0x00,0x21  TLS_KRB5_WITH_IDEA_CBC_SHA                    [RFC2712]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   768
         * 0x00,0x22  TLS_KRB5_WITH_DES_CBC_MD5                     [RFC2712]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   769
         * 0x00,0x23  TLS_KRB5_WITH_3DES_EDE_CBC_MD5                [RFC2712]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   770
         * 0x00,0x24  TLS_KRB5_WITH_RC4_128_MD5                     [RFC2712]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   771
         * 0x00,0x25  TLS_KRB5_WITH_IDEA_CBC_MD5                    [RFC2712]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   772
         * 0x00,0x26  TLS_KRB5_EXPORT_WITH_DES_CBC_40_SHA           [RFC2712]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   773
         * 0x00,0x27  TLS_KRB5_EXPORT_WITH_RC2_CBC_40_SHA           [RFC2712]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   774
         * 0x00,0x28  TLS_KRB5_EXPORT_WITH_RC4_40_SHA               [RFC2712]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   775
         * 0x00,0x29  TLS_KRB5_EXPORT_WITH_DES_CBC_40_MD5           [RFC2712]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   776
         * 0x00,0x2A  TLS_KRB5_EXPORT_WITH_RC2_CBC_40_MD5           [RFC2712]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   777
         * 0x00,0x2B  TLS_KRB5_EXPORT_WITH_RC4_40_MD5               [RFC2712]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   778
         * 0x00,0x2C  TLS_PSK_WITH_NULL_SHA                         [RFC4785]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   779
         * 0x00,0x2D  TLS_DHE_PSK_WITH_NULL_SHA                     [RFC4785]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   780
         * 0x00,0x2E  TLS_RSA_PSK_WITH_NULL_SHA                     [RFC4785]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   781
         * 0x00,0x2F  TLS_RSA_WITH_AES_128_CBC_SHA                  [RFC5246]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   782
         * 0x00,0x30  TLS_DH_DSS_WITH_AES_128_CBC_SHA               [RFC5246]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   783
         * 0x00,0x31  TLS_DH_RSA_WITH_AES_128_CBC_SHA               [RFC5246]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   784
         * 0x00,0x32  TLS_DHE_DSS_WITH_AES_128_CBC_SHA              [RFC5246]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   785
         * 0x00,0x33  TLS_DHE_RSA_WITH_AES_128_CBC_SHA              [RFC5246]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   786
         * 0x00,0x34  TLS_DH_anon_WITH_AES_128_CBC_SHA              [RFC5246]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   787
         * 0x00,0x35  TLS_RSA_WITH_AES_256_CBC_SHA                  [RFC5246]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   788
         * 0x00,0x36  TLS_DH_DSS_WITH_AES_256_CBC_SHA               [RFC5246]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   789
         * 0x00,0x37  TLS_DH_RSA_WITH_AES_256_CBC_SHA               [RFC5246]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   790
         * 0x00,0x38  TLS_DHE_DSS_WITH_AES_256_CBC_SHA              [RFC5246]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   791
         * 0x00,0x39  TLS_DHE_RSA_WITH_AES_256_CBC_SHA              [RFC5246]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   792
         * 0x00,0x3A  TLS_DH_anon_WITH_AES_256_CBC_SHA              [RFC5246]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   793
         * 0x00,0x3B  TLS_RSA_WITH_NULL_SHA256                      [RFC5246]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   794
         * 0x00,0x3C  TLS_RSA_WITH_AES_128_CBC_SHA256               [RFC5246]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   795
         * 0x00,0x3D  TLS_RSA_WITH_AES_256_CBC_SHA256               [RFC5246]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   796
         * 0x00,0x3E  TLS_DH_DSS_WITH_AES_128_CBC_SHA256            [RFC5246]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   797
         * 0x00,0x3F  TLS_DH_RSA_WITH_AES_128_CBC_SHA256            [RFC5246]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   798
         * 0x00,0x40  TLS_DHE_DSS_WITH_AES_128_CBC_SHA256           [RFC5246]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   799
         * 0x00,0x41  TLS_RSA_WITH_CAMELLIA_128_CBC_SHA             [RFC5932]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   800
         * 0x00,0x42  TLS_DH_DSS_WITH_CAMELLIA_128_CBC_SHA          [RFC5932]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   801
         * 0x00,0x43  TLS_DH_RSA_WITH_CAMELLIA_128_CBC_SHA          [RFC5932]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   802
         * 0x00,0x44  TLS_DHE_DSS_WITH_CAMELLIA_128_CBC_SHA         [RFC5932]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   803
         * 0x00,0x45  TLS_DHE_RSA_WITH_CAMELLIA_128_CBC_SHA         [RFC5932]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   804
         * 0x00,0x46  TLS_DH_anon_WITH_CAMELLIA_128_CBC_SHA         [RFC5932]
7039
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
   805
         * 0x00,0x47-4F Reserved to avoid conflicts with
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
   806
         *            deployed implementations                  [Pasi_Eronen]
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
   807
         * 0x00,0x50-58 Reserved to avoid conflicts             [Pasi Eronen]
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
   808
         * 0x00,0x59-5C Reserved to avoid conflicts with
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
   809
         *            deployed implementations                  [Pasi_Eronen]
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
   810
         * 0x00,0x5D-5F Unassigned
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
   811
         * 0x00,0x60-66 Reserved to avoid conflicts with widely
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
   812
         *            deployed implementations                  [Pasi_Eronen]
34380
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   813
         * 0x00,0x67  TLS_DHE_RSA_WITH_AES_128_CBC_SHA256           [RFC5246]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   814
         * 0x00,0x68  TLS_DH_DSS_WITH_AES_256_CBC_SHA256            [RFC5246]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   815
         * 0x00,0x69  TLS_DH_RSA_WITH_AES_256_CBC_SHA256            [RFC5246]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   816
         * 0x00,0x6A  TLS_DHE_DSS_WITH_AES_256_CBC_SHA256           [RFC5246]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   817
         * 0x00,0x6B  TLS_DHE_RSA_WITH_AES_256_CBC_SHA256           [RFC5246]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   818
         * 0x00,0x6C  TLS_DH_anon_WITH_AES_128_CBC_SHA256           [RFC5246]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   819
         * 0x00,0x6D  TLS_DH_anon_WITH_AES_256_CBC_SHA256           [RFC5246]
7039
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
   820
         * 0x00,0x6E-83 Unassigned
34380
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   821
         * 0x00,0x84  TLS_RSA_WITH_CAMELLIA_256_CBC_SHA             [RFC5932]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   822
         * 0x00,0x85  TLS_DH_DSS_WITH_CAMELLIA_256_CBC_SHA          [RFC5932]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   823
         * 0x00,0x86  TLS_DH_RSA_WITH_CAMELLIA_256_CBC_SHA          [RFC5932]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   824
         * 0x00,0x87  TLS_DHE_DSS_WITH_CAMELLIA_256_CBC_SHA         [RFC5932]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   825
         * 0x00,0x88  TLS_DHE_RSA_WITH_CAMELLIA_256_CBC_SHA         [RFC5932]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   826
         * 0x00,0x89  TLS_DH_anon_WITH_CAMELLIA_256_CBC_SHA         [RFC5932]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   827
         * 0x00,0x8A  TLS_PSK_WITH_RC4_128_SHA                      [RFC4279]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   828
         * 0x00,0x8B  TLS_PSK_WITH_3DES_EDE_CBC_SHA                 [RFC4279]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   829
         * 0x00,0x8C  TLS_PSK_WITH_AES_128_CBC_SHA                  [RFC4279]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   830
         * 0x00,0x8D  TLS_PSK_WITH_AES_256_CBC_SHA                  [RFC4279]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   831
         * 0x00,0x8E  TLS_DHE_PSK_WITH_RC4_128_SHA                  [RFC4279]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   832
         * 0x00,0x8F  TLS_DHE_PSK_WITH_3DES_EDE_CBC_SHA             [RFC4279]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   833
         * 0x00,0x90  TLS_DHE_PSK_WITH_AES_128_CBC_SHA              [RFC4279]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   834
         * 0x00,0x91  TLS_DHE_PSK_WITH_AES_256_CBC_SHA              [RFC4279]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   835
         * 0x00,0x92  TLS_RSA_PSK_WITH_RC4_128_SHA                  [RFC4279]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   836
         * 0x00,0x93  TLS_RSA_PSK_WITH_3DES_EDE_CBC_SHA             [RFC4279]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   837
         * 0x00,0x94  TLS_RSA_PSK_WITH_AES_128_CBC_SHA              [RFC4279]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   838
         * 0x00,0x95  TLS_RSA_PSK_WITH_AES_256_CBC_SHA              [RFC4279]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   839
         * 0x00,0x96  TLS_RSA_WITH_SEED_CBC_SHA                     [RFC4162]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   840
         * 0x00,0x97  TLS_DH_DSS_WITH_SEED_CBC_SHA                  [RFC4162]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   841
         * 0x00,0x98  TLS_DH_RSA_WITH_SEED_CBC_SHA                  [RFC4162]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   842
         * 0x00,0x99  TLS_DHE_DSS_WITH_SEED_CBC_SHA                 [RFC4162]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   843
         * 0x00,0x9A  TLS_DHE_RSA_WITH_SEED_CBC_SHA                 [RFC4162]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   844
         * 0x00,0x9B  TLS_DH_anon_WITH_SEED_CBC_SHA                 [RFC4162]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   845
         * 0x00,0x9C  TLS_RSA_WITH_AES_128_GCM_SHA256               [RFC5288]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   846
         * 0x00,0x9D  TLS_RSA_WITH_AES_256_GCM_SHA384               [RFC5288]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   847
         * 0x00,0x9E  TLS_DHE_RSA_WITH_AES_128_GCM_SHA256           [RFC5288]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   848
         * 0x00,0x9F  TLS_DHE_RSA_WITH_AES_256_GCM_SHA384           [RFC5288]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   849
         * 0x00,0xA0  TLS_DH_RSA_WITH_AES_128_GCM_SHA256            [RFC5288]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   850
         * 0x00,0xA1  TLS_DH_RSA_WITH_AES_256_GCM_SHA384            [RFC5288]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   851
         * 0x00,0xA2  TLS_DHE_DSS_WITH_AES_128_GCM_SHA256           [RFC5288]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   852
         * 0x00,0xA3  TLS_DHE_DSS_WITH_AES_256_GCM_SHA384           [RFC5288]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   853
         * 0x00,0xA4  TLS_DH_DSS_WITH_AES_128_GCM_SHA256            [RFC5288]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   854
         * 0x00,0xA5  TLS_DH_DSS_WITH_AES_256_GCM_SHA384            [RFC5288]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   855
         * 0x00,0xA6  TLS_DH_anon_WITH_AES_128_GCM_SHA256           [RFC5288]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   856
         * 0x00,0xA7  TLS_DH_anon_WITH_AES_256_GCM_SHA384           [RFC5288]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   857
         * 0x00,0xA8  TLS_PSK_WITH_AES_128_GCM_SHA256               [RFC5487]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   858
         * 0x00,0xA9  TLS_PSK_WITH_AES_256_GCM_SHA384               [RFC5487]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   859
         * 0x00,0xAA  TLS_DHE_PSK_WITH_AES_128_GCM_SHA256           [RFC5487]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   860
         * 0x00,0xAB  TLS_DHE_PSK_WITH_AES_256_GCM_SHA384           [RFC5487]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   861
         * 0x00,0xAC  TLS_RSA_PSK_WITH_AES_128_GCM_SHA256           [RFC5487]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   862
         * 0x00,0xAD  TLS_RSA_PSK_WITH_AES_256_GCM_SHA384           [RFC5487]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   863
         * 0x00,0xAE  TLS_PSK_WITH_AES_128_CBC_SHA256               [RFC5487]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   864
         * 0x00,0xAF  TLS_PSK_WITH_AES_256_CBC_SHA384               [RFC5487]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   865
         * 0x00,0xB0  TLS_PSK_WITH_NULL_SHA256                      [RFC5487]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   866
         * 0x00,0xB1  TLS_PSK_WITH_NULL_SHA384                      [RFC5487]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   867
         * 0x00,0xB2  TLS_DHE_PSK_WITH_AES_128_CBC_SHA256           [RFC5487]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   868
         * 0x00,0xB3  TLS_DHE_PSK_WITH_AES_256_CBC_SHA384           [RFC5487]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   869
         * 0x00,0xB4  TLS_DHE_PSK_WITH_NULL_SHA256                  [RFC5487]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   870
         * 0x00,0xB5  TLS_DHE_PSK_WITH_NULL_SHA384                  [RFC5487]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   871
         * 0x00,0xB6  TLS_RSA_PSK_WITH_AES_128_CBC_SHA256           [RFC5487]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   872
         * 0x00,0xB7  TLS_RSA_PSK_WITH_AES_256_CBC_SHA384           [RFC5487]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   873
         * 0x00,0xB8  TLS_RSA_PSK_WITH_NULL_SHA256                  [RFC5487]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   874
         * 0x00,0xB9  TLS_RSA_PSK_WITH_NULL_SHA384                  [RFC5487]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   875
         * 0x00,0xBA  TLS_RSA_WITH_CAMELLIA_128_CBC_SHA256          [RFC5932]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   876
         * 0x00,0xBB  TLS_DH_DSS_WITH_CAMELLIA_128_CBC_SHA256       [RFC5932]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   877
         * 0x00,0xBC  TLS_DH_RSA_WITH_CAMELLIA_128_CBC_SHA256       [RFC5932]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   878
         * 0x00,0xBD  TLS_DHE_DSS_WITH_CAMELLIA_128_CBC_SHA256      [RFC5932]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   879
         * 0x00,0xBE  TLS_DHE_RSA_WITH_CAMELLIA_128_CBC_SHA256      [RFC5932]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   880
         * 0x00,0xBF  TLS_DH_anon_WITH_CAMELLIA_128_CBC_SHA256      [RFC5932]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   881
         * 0x00,0xC0  TLS_RSA_WITH_CAMELLIA_256_CBC_SHA256          [RFC5932]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   882
         * 0x00,0xC1  TLS_DH_DSS_WITH_CAMELLIA_256_CBC_SHA256       [RFC5932]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   883
         * 0x00,0xC2  TLS_DH_RSA_WITH_CAMELLIA_256_CBC_SHA256       [RFC5932]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   884
         * 0x00,0xC3  TLS_DHE_DSS_WITH_CAMELLIA_256_CBC_SHA256      [RFC5932]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   885
         * 0x00,0xC4  TLS_DHE_RSA_WITH_CAMELLIA_256_CBC_SHA256      [RFC5932]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   886
         * 0x00,0xC5  TLS_DH_anon_WITH_CAMELLIA_256_CBC_SHA256      [RFC5932]
7039
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
   887
         * 0x00,0xC6-FE         Unassigned
34380
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   888
         * 0x00,0xFF  TLS_EMPTY_RENEGOTIATION_INFO_SCSV             [RFC5746]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   889
         * 0x01-55,*  Unassigned
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   890
         * 0x56,0x00  TLS_FALLBACK_SCSV                             [RFC7507]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   891
         * 0x56,0x01-0xC0,0x00  Unassigned
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   892
         * 0xC0,0x01  TLS_ECDH_ECDSA_WITH_NULL_SHA                  [RFC4492]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   893
         * 0xC0,0x02  TLS_ECDH_ECDSA_WITH_RC4_128_SHA               [RFC4492]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   894
         * 0xC0,0x03  TLS_ECDH_ECDSA_WITH_3DES_EDE_CBC_SHA          [RFC4492]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   895
         * 0xC0,0x04  TLS_ECDH_ECDSA_WITH_AES_128_CBC_SHA           [RFC4492]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   896
         * 0xC0,0x05  TLS_ECDH_ECDSA_WITH_AES_256_CBC_SHA           [RFC4492]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   897
         * 0xC0,0x06  TLS_ECDHE_ECDSA_WITH_NULL_SHA                 [RFC4492]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   898
         * 0xC0,0x07  TLS_ECDHE_ECDSA_WITH_RC4_128_SHA              [RFC4492]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   899
         * 0xC0,0x08  TLS_ECDHE_ECDSA_WITH_3DES_EDE_CBC_SHA         [RFC4492]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   900
         * 0xC0,0x09  TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA          [RFC4492]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   901
         * 0xC0,0x0A  TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA          [RFC4492]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   902
         * 0xC0,0x0B  TLS_ECDH_RSA_WITH_NULL_SHA                    [RFC4492]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   903
         * 0xC0,0x0C  TLS_ECDH_RSA_WITH_RC4_128_SHA                 [RFC4492]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   904
         * 0xC0,0x0D  TLS_ECDH_RSA_WITH_3DES_EDE_CBC_SHA            [RFC4492]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   905
         * 0xC0,0x0E  TLS_ECDH_RSA_WITH_AES_128_CBC_SHA             [RFC4492]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   906
         * 0xC0,0x0F  TLS_ECDH_RSA_WITH_AES_256_CBC_SHA             [RFC4492]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   907
         * 0xC0,0x10  TLS_ECDHE_RSA_WITH_NULL_SHA                   [RFC4492]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   908
         * 0xC0,0x11  TLS_ECDHE_RSA_WITH_RC4_128_SHA                [RFC4492]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   909
         * 0xC0,0x12  TLS_ECDHE_RSA_WITH_3DES_EDE_CBC_SHA           [RFC4492]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   910
         * 0xC0,0x13  TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA            [RFC4492]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   911
         * 0xC0,0x14  TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA            [RFC4492]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   912
         * 0xC0,0x15  TLS_ECDH_anon_WITH_NULL_SHA                   [RFC4492]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   913
         * 0xC0,0x16  TLS_ECDH_anon_WITH_RC4_128_SHA                [RFC4492]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   914
         * 0xC0,0x17  TLS_ECDH_anon_WITH_3DES_EDE_CBC_SHA           [RFC4492]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   915
         * 0xC0,0x18  TLS_ECDH_anon_WITH_AES_128_CBC_SHA            [RFC4492]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   916
         * 0xC0,0x19  TLS_ECDH_anon_WITH_AES_256_CBC_SHA            [RFC4492]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   917
         * 0xC0,0x1A  TLS_SRP_SHA_WITH_3DES_EDE_CBC_SHA             [RFC5054]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   918
         * 0xC0,0x1B  TLS_SRP_SHA_RSA_WITH_3DES_EDE_CBC_SHA         [RFC5054]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   919
         * 0xC0,0x1C  TLS_SRP_SHA_DSS_WITH_3DES_EDE_CBC_SHA         [RFC5054]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   920
         * 0xC0,0x1D  TLS_SRP_SHA_WITH_AES_128_CBC_SHA              [RFC5054]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   921
         * 0xC0,0x1E  TLS_SRP_SHA_RSA_WITH_AES_128_CBC_SHA          [RFC5054]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   922
         * 0xC0,0x1F  TLS_SRP_SHA_DSS_WITH_AES_128_CBC_SHA          [RFC5054]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   923
         * 0xC0,0x20  TLS_SRP_SHA_WITH_AES_256_CBC_SHA              [RFC5054]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   924
         * 0xC0,0x21  TLS_SRP_SHA_RSA_WITH_AES_256_CBC_SHA          [RFC5054]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   925
         * 0xC0,0x22  TLS_SRP_SHA_DSS_WITH_AES_256_CBC_SHA          [RFC5054]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   926
         * 0xC0,0x23  TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA256       [RFC5289]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   927
         * 0xC0,0x24  TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA384       [RFC5289]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   928
         * 0xC0,0x25  TLS_ECDH_ECDSA_WITH_AES_128_CBC_SHA256        [RFC5289]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   929
         * 0xC0,0x26  TLS_ECDH_ECDSA_WITH_AES_256_CBC_SHA384        [RFC5289]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   930
         * 0xC0,0x27  TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256         [RFC5289]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   931
         * 0xC0,0x28  TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384         [RFC5289]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   932
         * 0xC0,0x29  TLS_ECDH_RSA_WITH_AES_128_CBC_SHA256          [RFC5289]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   933
         * 0xC0,0x2A  TLS_ECDH_RSA_WITH_AES_256_CBC_SHA384          [RFC5289]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   934
         * 0xC0,0x2B  TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256       [RFC5289]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   935
         * 0xC0,0x2C  TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384       [RFC5289]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   936
         * 0xC0,0x2D  TLS_ECDH_ECDSA_WITH_AES_128_GCM_SHA256        [RFC5289]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   937
         * 0xC0,0x2E  TLS_ECDH_ECDSA_WITH_AES_256_GCM_SHA384        [RFC5289]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   938
         * 0xC0,0x2F  TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256         [RFC5289]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   939
         * 0xC0,0x30  TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384         [RFC5289]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   940
         * 0xC0,0x31  TLS_ECDH_RSA_WITH_AES_128_GCM_SHA256          [RFC5289]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   941
         * 0xC0,0x32  TLS_ECDH_RSA_WITH_AES_256_GCM_SHA384          [RFC5289]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   942
         * 0xC0,0x33  TLS_ECDHE_PSK_WITH_RC4_128_SHA                [RFC5489]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   943
         * 0xC0,0x34  TLS_ECDHE_PSK_WITH_3DES_EDE_CBC_SHA           [RFC5489]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   944
         * 0xC0,0x35  TLS_ECDHE_PSK_WITH_AES_128_CBC_SHA            [RFC5489]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   945
         * 0xC0,0x36  TLS_ECDHE_PSK_WITH_AES_256_CBC_SHA            [RFC5489]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   946
         * 0xC0,0x37  TLS_ECDHE_PSK_WITH_AES_128_CBC_SHA256         [RFC5489]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   947
         * 0xC0,0x38  TLS_ECDHE_PSK_WITH_AES_256_CBC_SHA384         [RFC5489]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   948
         * 0xC0,0x39  TLS_ECDHE_PSK_WITH_NULL_SHA                   [RFC5489]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   949
         * 0xC0,0x3A  TLS_ECDHE_PSK_WITH_NULL_SHA256                [RFC5489]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   950
         * 0xC0,0x3B  TLS_ECDHE_PSK_WITH_NULL_SHA384                [RFC5489]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   951
         * 0xC0,0x3C  TLS_RSA_WITH_ARIA_128_CBC_SHA256              [RFC6209]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   952
         * 0xC0,0x3D  TLS_RSA_WITH_ARIA_256_CBC_SHA384              [RFC6209]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   953
         * 0xC0,0x3E  TLS_DH_DSS_WITH_ARIA_128_CBC_SHA256           [RFC6209]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   954
         * 0xC0,0x3F  TLS_DH_DSS_WITH_ARIA_256_CBC_SHA384           [RFC6209]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   955
         * 0xC0,0x40  TLS_DH_RSA_WITH_ARIA_128_CBC_SHA256           [RFC6209]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   956
         * 0xC0,0x41  TLS_DH_RSA_WITH_ARIA_256_CBC_SHA384           [RFC6209]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   957
         * 0xC0,0x42  TLS_DHE_DSS_WITH_ARIA_128_CBC_SHA256          [RFC6209]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   958
         * 0xC0,0x43  TLS_DHE_DSS_WITH_ARIA_256_CBC_SHA384          [RFC6209]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   959
         * 0xC0,0x44  TLS_DHE_RSA_WITH_ARIA_128_CBC_SHA256          [RFC6209]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   960
         * 0xC0,0x45  TLS_DHE_RSA_WITH_ARIA_256_CBC_SHA384          [RFC6209]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   961
         * 0xC0,0x46  TLS_DH_anon_WITH_ARIA_128_CBC_SHA256          [RFC6209]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   962
         * 0xC0,0x47  TLS_DH_anon_WITH_ARIA_256_CBC_SHA384          [RFC6209]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   963
         * 0xC0,0x48  TLS_ECDHE_ECDSA_WITH_ARIA_128_CBC_SHA256      [RFC6209]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   964
         * 0xC0,0x49  TLS_ECDHE_ECDSA_WITH_ARIA_256_CBC_SHA384      [RFC6209]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   965
         * 0xC0,0x4A  TLS_ECDH_ECDSA_WITH_ARIA_128_CBC_SHA256       [RFC6209]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   966
         * 0xC0,0x4B  TLS_ECDH_ECDSA_WITH_ARIA_256_CBC_SHA384       [RFC6209]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   967
         * 0xC0,0x4C  TLS_ECDHE_RSA_WITH_ARIA_128_CBC_SHA256        [RFC6209]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   968
         * 0xC0,0x4D  TLS_ECDHE_RSA_WITH_ARIA_256_CBC_SHA384        [RFC6209]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   969
         * 0xC0,0x4E  TLS_ECDH_RSA_WITH_ARIA_128_CBC_SHA256         [RFC6209]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   970
         * 0xC0,0x4F  TLS_ECDH_RSA_WITH_ARIA_256_CBC_SHA384         [RFC6209]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   971
         * 0xC0,0x50  TLS_RSA_WITH_ARIA_128_GCM_SHA256              [RFC6209]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   972
         * 0xC0,0x51  TLS_RSA_WITH_ARIA_256_GCM_SHA384              [RFC6209]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   973
         * 0xC0,0x52  TLS_DHE_RSA_WITH_ARIA_128_GCM_SHA256          [RFC6209]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   974
         * 0xC0,0x53  TLS_DHE_RSA_WITH_ARIA_256_GCM_SHA384          [RFC6209]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   975
         * 0xC0,0x54  TLS_DH_RSA_WITH_ARIA_128_GCM_SHA256           [RFC6209]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   976
         * 0xC0,0x55  TLS_DH_RSA_WITH_ARIA_256_GCM_SHA384           [RFC6209]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   977
         * 0xC0,0x56  TLS_DHE_DSS_WITH_ARIA_128_GCM_SHA256          [RFC6209]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   978
         * 0xC0,0x57  TLS_DHE_DSS_WITH_ARIA_256_GCM_SHA384          [RFC6209]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   979
         * 0xC0,0x58  TLS_DH_DSS_WITH_ARIA_128_GCM_SHA256           [RFC6209]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   980
         * 0xC0,0x59  TLS_DH_DSS_WITH_ARIA_256_GCM_SHA384           [RFC6209]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   981
         * 0xC0,0x5A  TLS_DH_anon_WITH_ARIA_128_GCM_SHA256          [RFC6209]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   982
         * 0xC0,0x5B  TLS_DH_anon_WITH_ARIA_256_GCM_SHA384          [RFC6209]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   983
         * 0xC0,0x5C  TLS_ECDHE_ECDSA_WITH_ARIA_128_GCM_SHA256      [RFC6209]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   984
         * 0xC0,0x5D  TLS_ECDHE_ECDSA_WITH_ARIA_256_GCM_SHA384      [RFC6209]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   985
         * 0xC0,0x5E  TLS_ECDH_ECDSA_WITH_ARIA_128_GCM_SHA256       [RFC6209]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   986
         * 0xC0,0x5F  TLS_ECDH_ECDSA_WITH_ARIA_256_GCM_SHA384       [RFC6209]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   987
         * 0xC0,0x60  TLS_ECDHE_RSA_WITH_ARIA_128_GCM_SHA256        [RFC6209]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   988
         * 0xC0,0x61  TLS_ECDHE_RSA_WITH_ARIA_256_GCM_SHA384        [RFC6209]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   989
         * 0xC0,0x62  TLS_ECDH_RSA_WITH_ARIA_128_GCM_SHA256         [RFC6209]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   990
         * 0xC0,0x63  TLS_ECDH_RSA_WITH_ARIA_256_GCM_SHA384         [RFC6209]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   991
         * 0xC0,0x64  TLS_PSK_WITH_ARIA_128_CBC_SHA256              [RFC6209]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   992
         * 0xC0,0x65  TLS_PSK_WITH_ARIA_256_CBC_SHA384              [RFC6209]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   993
         * 0xC0,0x66  TLS_DHE_PSK_WITH_ARIA_128_CBC_SHA256          [RFC6209]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   994
         * 0xC0,0x67  TLS_DHE_PSK_WITH_ARIA_256_CBC_SHA384          [RFC6209]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   995
         * 0xC0,0x68  TLS_RSA_PSK_WITH_ARIA_128_CBC_SHA256          [RFC6209]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   996
         * 0xC0,0x69  TLS_RSA_PSK_WITH_ARIA_256_CBC_SHA384          [RFC6209]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   997
         * 0xC0,0x6A  TLS_PSK_WITH_ARIA_128_GCM_SHA256              [RFC6209]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   998
         * 0xC0,0x6B  TLS_PSK_WITH_ARIA_256_GCM_SHA384              [RFC6209]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
   999
         * 0xC0,0x6C  TLS_DHE_PSK_WITH_ARIA_128_GCM_SHA256          [RFC6209]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1000
         * 0xC0,0x6D  TLS_DHE_PSK_WITH_ARIA_256_GCM_SHA384          [RFC6209]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1001
         * 0xC0,0x6E  TLS_RSA_PSK_WITH_ARIA_128_GCM_SHA256          [RFC6209]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1002
         * 0xC0,0x6F  TLS_RSA_PSK_WITH_ARIA_256_GCM_SHA384          [RFC6209]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1003
         * 0xC0,0x70  TLS_ECDHE_PSK_WITH_ARIA_128_CBC_SHA256        [RFC6209]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1004
         * 0xC0,0x71  TLS_ECDHE_PSK_WITH_ARIA_256_CBC_SHA384        [RFC6209]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1005
         * 0xC0,0x72  TLS_ECDHE_ECDSA_WITH_CAMELLIA_128_CBC_SHA256  [RFC6367]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1006
         * 0xC0,0x73  TLS_ECDHE_ECDSA_WITH_CAMELLIA_256_CBC_SHA384  [RFC6367]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1007
         * 0xC0,0x74  TLS_ECDH_ECDSA_WITH_CAMELLIA_128_CBC_SHA256   [RFC6367]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1008
         * 0xC0,0x75  TLS_ECDH_ECDSA_WITH_CAMELLIA_256_CBC_SHA384   [RFC6367]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1009
         * 0xC0,0x76  TLS_ECDHE_RSA_WITH_CAMELLIA_128_CBC_SHA256    [RFC6367]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1010
         * 0xC0,0x77  TLS_ECDHE_RSA_WITH_CAMELLIA_256_CBC_SHA384    [RFC6367]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1011
         * 0xC0,0x78  TLS_ECDH_RSA_WITH_CAMELLIA_128_CBC_SHA256     [RFC6367]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1012
         * 0xC0,0x79  TLS_ECDH_RSA_WITH_CAMELLIA_256_CBC_SHA384     [RFC6367]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1013
         * 0xC0,0x7A  TLS_RSA_WITH_CAMELLIA_128_GCM_SHA256          [RFC6367]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1014
         * 0xC0,0x7B  TLS_RSA_WITH_CAMELLIA_256_GCM_SHA384          [RFC6367]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1015
         * 0xC0,0x7C  TLS_DHE_RSA_WITH_CAMELLIA_128_GCM_SHA256      [RFC6367]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1016
         * 0xC0,0x7D  TLS_DHE_RSA_WITH_CAMELLIA_256_GCM_SHA384      [RFC6367]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1017
         * 0xC0,0x7E  TLS_DH_RSA_WITH_CAMELLIA_128_GCM_SHA256       [RFC6367]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1018
         * 0xC0,0x7F  TLS_DH_RSA_WITH_CAMELLIA_256_GCM_SHA384       [RFC6367]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1019
         * 0xC0,0x80  TLS_DHE_DSS_WITH_CAMELLIA_128_GCM_SHA256      [RFC6367]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1020
         * 0xC0,0x81  TLS_DHE_DSS_WITH_CAMELLIA_256_GCM_SHA384      [RFC6367]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1021
         * 0xC0,0x82  TLS_DH_DSS_WITH_CAMELLIA_128_GCM_SHA256       [RFC6367]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1022
         * 0xC0,0x83  TLS_DH_DSS_WITH_CAMELLIA_256_GCM_SHA384       [RFC6367]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1023
         * 0xC0,0x84  TLS_DH_anon_WITH_CAMELLIA_128_GCM_SHA256      [RFC6367]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1024
         * 0xC0,0x85  TLS_DH_anon_WITH_CAMELLIA_256_GCM_SHA384      [RFC6367]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1025
         * 0xC0,0x86  TLS_ECDHE_ECDSA_WITH_CAMELLIA_128_GCM_SHA256  [RFC6367]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1026
         * 0xC0,0x87  TLS_ECDHE_ECDSA_WITH_CAMELLIA_256_GCM_SHA384  [RFC6367]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1027
         * 0xC0,0x88  TLS_ECDH_ECDSA_WITH_CAMELLIA_128_GCM_SHA256   [RFC6367]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1028
         * 0xC0,0x89  TLS_ECDH_ECDSA_WITH_CAMELLIA_256_GCM_SHA384   [RFC6367]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1029
         * 0xC0,0x8A  TLS_ECDHE_RSA_WITH_CAMELLIA_128_GCM_SHA256    [RFC6367]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1030
         * 0xC0,0x8B  TLS_ECDHE_RSA_WITH_CAMELLIA_256_GCM_SHA384    [RFC6367]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1031
         * 0xC0,0x8C  TLS_ECDH_RSA_WITH_CAMELLIA_128_GCM_SHA256     [RFC6367]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1032
         * 0xC0,0x8D  TLS_ECDH_RSA_WITH_CAMELLIA_256_GCM_SHA384     [RFC6367]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1033
         * 0xC0,0x8E  TLS_PSK_WITH_CAMELLIA_128_GCM_SHA256          [RFC6367]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1034
         * 0xC0,0x8F  TLS_PSK_WITH_CAMELLIA_256_GCM_SHA384          [RFC6367]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1035
         * 0xC0,0x90  TLS_DHE_PSK_WITH_CAMELLIA_128_GCM_SHA256      [RFC6367]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1036
         * 0xC0,0x91  TLS_DHE_PSK_WITH_CAMELLIA_256_GCM_SHA384      [RFC6367]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1037
         * 0xC0,0x92  TLS_RSA_PSK_WITH_CAMELLIA_128_GCM_SHA256      [RFC6367]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1038
         * 0xC0,0x93  TLS_RSA_PSK_WITH_CAMELLIA_256_GCM_SHA384      [RFC6367]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1039
         * 0xC0,0x94  TLS_PSK_WITH_CAMELLIA_128_CBC_SHA256          [RFC6367]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1040
         * 0xC0,0x95  TLS_PSK_WITH_CAMELLIA_256_CBC_SHA384          [RFC6367]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1041
         * 0xC0,0x96  TLS_DHE_PSK_WITH_CAMELLIA_128_CBC_SHA256      [RFC6367]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1042
         * 0xC0,0x97  TLS_DHE_PSK_WITH_CAMELLIA_256_CBC_SHA384      [RFC6367]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1043
         * 0xC0,0x98  TLS_RSA_PSK_WITH_CAMELLIA_128_CBC_SHA256      [RFC6367]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1044
         * 0xC0,0x99  TLS_RSA_PSK_WITH_CAMELLIA_256_CBC_SHA384      [RFC6367]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1045
         * 0xC0,0x9A  TLS_ECDHE_PSK_WITH_CAMELLIA_128_CBC_SHA256    [RFC6367]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1046
         * 0xC0,0x9B  TLS_ECDHE_PSK_WITH_CAMELLIA_256_CBC_SHA384    [RFC6367]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1047
         * 0xC0,0x9C  TLS_RSA_WITH_AES_128_CCM                      [RFC6655]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1048
         * 0xC0,0x9D  TLS_RSA_WITH_AES_256_CCM                      [RFC6655]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1049
         * 0xC0,0x9E  TLS_DHE_RSA_WITH_AES_128_CCM                  [RFC6655]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1050
         * 0xC0,0x9F  TLS_DHE_RSA_WITH_AES_256_CCM                  [RFC6655]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1051
         * 0xC0,0xA0  TLS_RSA_WITH_AES_128_CCM_8                    [RFC6655]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1052
         * 0xC0,0xA1  TLS_RSA_WITH_AES_256_CCM_8                    [RFC6655]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1053
         * 0xC0,0xA2  TLS_DHE_RSA_WITH_AES_128_CCM_8                [RFC6655]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1054
         * 0xC0,0xA3  TLS_DHE_RSA_WITH_AES_256_CCM_8                [RFC6655]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1055
         * 0xC0,0xA4  TLS_PSK_WITH_AES_128_CCM                      [RFC6655]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1056
         * 0xC0,0xA5  TLS_PSK_WITH_AES_256_CCM                      [RFC6655]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1057
         * 0xC0,0xA6  TLS_DHE_PSK_WITH_AES_128_CCM                  [RFC6655]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1058
         * 0xC0,0xA7  TLS_DHE_PSK_WITH_AES_256_CCM                  [RFC6655]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1059
         * 0xC0,0xA8  TLS_PSK_WITH_AES_128_CCM_8                    [RFC6655]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1060
         * 0xC0,0xA9  TLS_PSK_WITH_AES_256_CCM_8                    [RFC6655]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1061
         * 0xC0,0xAA  TLS_PSK_DHE_WITH_AES_128_CCM_8                [RFC6655]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1062
         * 0xC0,0xAB  TLS_PSK_DHE_WITH_AES_256_CCM_8                [RFC6655]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1063
         * 0xC0,0xAC  TLS_ECDHE_ECDSA_WITH_AES_128_CCM              [RFC7251]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1064
         * 0xC0,0xAD  TLS_ECDHE_ECDSA_WITH_AES_256_CCM              [RFC7251]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1065
         * 0xC0,0xAE  TLS_ECDHE_ECDSA_WITH_AES_128_CCM_8            [RFC7251]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1066
         * 0xC0,0xAF  TLS_ECDHE_ECDSA_WITH_AES_256_CCM_8            [RFC7251]
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1067
         * 0xC0,0xB0-FF  Unassigned
7039
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
  1068
         * 0xC1-FD,*  Unassigned
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
  1069
         * 0xFE,0x00-FD Unassigned
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
  1070
         * 0xFE,0xFE-FF Reserved to avoid conflicts with widely
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
  1071
         *            deployed implementations                  [Pasi_Eronen]
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
  1072
         * 0xFF,0x00-FF Reserved for Private Use                [RFC5246]
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
  1073
         */
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
  1074
29488
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1075
        add("SSL_NULL_WITH_NULL_NULL", 0x0000,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1076
                1,      K_NULL,     B_NULL,     M_NULL,     F);
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1077
7807
d026f4f9c119 6996365: Evaluate the priorities of cipher suites
xuelei
parents: 7043
diff changeset
  1078
        /*
d026f4f9c119 6996365: Evaluate the priorities of cipher suites
xuelei
parents: 7043
diff changeset
  1079
         * Definition of the CipherSuites that are enabled by default.
d026f4f9c119 6996365: Evaluate the priorities of cipher suites
xuelei
parents: 7043
diff changeset
  1080
         * They are listed in preference order, most preferred first, using
d026f4f9c119 6996365: Evaluate the priorities of cipher suites
xuelei
parents: 7043
diff changeset
  1081
         * the following criteria:
16913
a6f4d1626ad9 8011680: Re-integrate AEAD implementation of JSSE
xuelei
parents: 16126
diff changeset
  1082
         * 1. Prefer Suite B compliant cipher suites, see RFC6460 (To be
a6f4d1626ad9 8011680: Re-integrate AEAD implementation of JSSE
xuelei
parents: 16126
diff changeset
  1083
         *    changed later, see below).
a6f4d1626ad9 8011680: Re-integrate AEAD implementation of JSSE
xuelei
parents: 16126
diff changeset
  1084
         * 2. Prefer the stronger bulk cipher, in the order of AES_256(GCM),
31706
895170f33881 8043202: Prohibit RC4 cipher suites
asmotrak
parents: 30904
diff changeset
  1085
         *    AES_128(GCM), AES_256, AES_128, 3DES-EDE.
16913
a6f4d1626ad9 8011680: Re-integrate AEAD implementation of JSSE
xuelei
parents: 16126
diff changeset
  1086
         * 3. Prefer the stronger MAC algorithm, in the order of SHA384,
7807
d026f4f9c119 6996365: Evaluate the priorities of cipher suites
xuelei
parents: 7043
diff changeset
  1087
         *    SHA256, SHA, MD5.
16913
a6f4d1626ad9 8011680: Re-integrate AEAD implementation of JSSE
xuelei
parents: 16126
diff changeset
  1088
         * 4. Prefer the better performance of key exchange and digital
7807
d026f4f9c119 6996365: Evaluate the priorities of cipher suites
xuelei
parents: 7043
diff changeset
  1089
         *    signature algorithm, in the order of ECDHE-ECDSA, ECDHE-RSA,
d026f4f9c119 6996365: Evaluate the priorities of cipher suites
xuelei
parents: 7043
diff changeset
  1090
         *    RSA, ECDH-ECDSA, ECDH-RSA, DHE-RSA, DHE-DSS.
d026f4f9c119 6996365: Evaluate the priorities of cipher suites
xuelei
parents: 7043
diff changeset
  1091
         */
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1092
        int p = DEFAULT_SUITES_PRIORITY * 2;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1093
7043
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
  1094
        // shorten names to fit the following table cleanly.
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
  1095
        int max = ProtocolVersion.LIMIT_MAX_VALUE;
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
  1096
        int tls11 = ProtocolVersion.TLS11.v;
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
  1097
        int tls12 = ProtocolVersion.TLS12.v;
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
  1098
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
  1099
        //  ID           Key Exchange   Cipher     A  obs  suprt  PRF
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
  1100
        //  ======       ============   =========  =  ===  =====  ========
16913
a6f4d1626ad9 8011680: Re-integrate AEAD implementation of JSSE
xuelei
parents: 16126
diff changeset
  1101
22267
13f418b13938 8028518: Increase the priorities of GCM cipher suites
xuelei
parents: 16913
diff changeset
  1102
        // Suite B compliant cipher suites, see RFC 6460.
16913
a6f4d1626ad9 8011680: Re-integrate AEAD implementation of JSSE
xuelei
parents: 16126
diff changeset
  1103
        //
22267
13f418b13938 8028518: Increase the priorities of GCM cipher suites
xuelei
parents: 16913
diff changeset
  1104
        // Note that, at present this provider is not Suite B compliant. The
13f418b13938 8028518: Increase the priorities of GCM cipher suites
xuelei
parents: 16913
diff changeset
  1105
        // preference order of the GCM cipher suites does not follow the spec
13f418b13938 8028518: Increase the priorities of GCM cipher suites
xuelei
parents: 16913
diff changeset
  1106
        // of RFC 6460.  In this section, only two cipher suites are listed
13f418b13938 8028518: Increase the priorities of GCM cipher suites
xuelei
parents: 16913
diff changeset
  1107
        // so that applications can make use of Suite-B compliant cipher
13f418b13938 8028518: Increase the priorities of GCM cipher suites
xuelei
parents: 16913
diff changeset
  1108
        // suite firstly.
29488
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1109
        add("TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384",  0xc02c, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1110
            K_ECDHE_ECDSA, B_AES_256_GCM, M_NULL,   T, max, tls12, P_SHA384);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1111
        add("TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256",  0xc02b, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1112
            K_ECDHE_ECDSA, B_AES_128_GCM, M_NULL,   T, max, tls12, P_SHA256);
22267
13f418b13938 8028518: Increase the priorities of GCM cipher suites
xuelei
parents: 16913
diff changeset
  1113
13f418b13938 8028518: Increase the priorities of GCM cipher suites
xuelei
parents: 16913
diff changeset
  1114
        // AES_256(GCM)
29488
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1115
        add("TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384",    0xc030, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1116
            K_ECDHE_RSA,   B_AES_256_GCM, M_NULL,   T, max, tls12, P_SHA384);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1117
        add("TLS_RSA_WITH_AES_256_GCM_SHA384",          0x009d, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1118
            K_RSA,         B_AES_256_GCM, M_NULL,   T, max, tls12, P_SHA384);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1119
        add("TLS_ECDH_ECDSA_WITH_AES_256_GCM_SHA384",   0xc02e, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1120
            K_ECDH_ECDSA,  B_AES_256_GCM, M_NULL,   T, max, tls12, P_SHA384);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1121
        add("TLS_ECDH_RSA_WITH_AES_256_GCM_SHA384",     0xc032, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1122
            K_ECDH_RSA,    B_AES_256_GCM, M_NULL,   T, max, tls12, P_SHA384);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1123
        add("TLS_DHE_RSA_WITH_AES_256_GCM_SHA384",      0x009f, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1124
            K_DHE_RSA,     B_AES_256_GCM, M_NULL,   T, max, tls12, P_SHA384);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1125
        add("TLS_DHE_DSS_WITH_AES_256_GCM_SHA384",      0x00a3, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1126
            K_DHE_DSS,     B_AES_256_GCM, M_NULL,   T, max, tls12, P_SHA384);
22267
13f418b13938 8028518: Increase the priorities of GCM cipher suites
xuelei
parents: 16913
diff changeset
  1127
13f418b13938 8028518: Increase the priorities of GCM cipher suites
xuelei
parents: 16913
diff changeset
  1128
        // AES_128(GCM)
29488
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1129
        add("TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256",    0xc02f, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1130
            K_ECDHE_RSA,   B_AES_128_GCM, M_NULL,   T, max, tls12, P_SHA256);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1131
        add("TLS_RSA_WITH_AES_128_GCM_SHA256",          0x009c, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1132
            K_RSA,         B_AES_128_GCM, M_NULL,   T, max, tls12, P_SHA256);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1133
        add("TLS_ECDH_ECDSA_WITH_AES_128_GCM_SHA256",   0xc02d, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1134
            K_ECDH_ECDSA,  B_AES_128_GCM, M_NULL,   T, max, tls12, P_SHA256);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1135
        add("TLS_ECDH_RSA_WITH_AES_128_GCM_SHA256",     0xc031, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1136
            K_ECDH_RSA,    B_AES_128_GCM, M_NULL,   T, max, tls12, P_SHA256);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1137
        add("TLS_DHE_RSA_WITH_AES_128_GCM_SHA256",      0x009e, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1138
            K_DHE_RSA,     B_AES_128_GCM, M_NULL,   T, max, tls12, P_SHA256);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1139
        add("TLS_DHE_DSS_WITH_AES_128_GCM_SHA256",      0x00a2, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1140
            K_DHE_DSS,     B_AES_128_GCM, M_NULL,   T, max, tls12, P_SHA256);
16913
a6f4d1626ad9 8011680: Re-integrate AEAD implementation of JSSE
xuelei
parents: 16126
diff changeset
  1141
a6f4d1626ad9 8011680: Re-integrate AEAD implementation of JSSE
xuelei
parents: 16126
diff changeset
  1142
        // AES_256(CBC)
29488
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1143
        add("TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA384",  0xc024, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1144
            K_ECDHE_ECDSA, B_AES_256,     M_SHA384, T, max, tls12, P_SHA384);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1145
        add("TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384",    0xc028, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1146
            K_ECDHE_RSA,   B_AES_256,     M_SHA384, T, max, tls12, P_SHA384);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1147
        add("TLS_RSA_WITH_AES_256_CBC_SHA256",          0x003d, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1148
            K_RSA,         B_AES_256,     M_SHA256, T, max, tls12, P_SHA256);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1149
        add("TLS_ECDH_ECDSA_WITH_AES_256_CBC_SHA384",   0xc026, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1150
            K_ECDH_ECDSA,  B_AES_256,     M_SHA384, T, max, tls12, P_SHA384);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1151
        add("TLS_ECDH_RSA_WITH_AES_256_CBC_SHA384",     0xc02a, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1152
            K_ECDH_RSA,    B_AES_256,     M_SHA384, T, max, tls12, P_SHA384);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1153
        add("TLS_DHE_RSA_WITH_AES_256_CBC_SHA256",      0x006b, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1154
            K_DHE_RSA,     B_AES_256,     M_SHA256, T, max, tls12, P_SHA256);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1155
        add("TLS_DHE_DSS_WITH_AES_256_CBC_SHA256",      0x006a, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1156
            K_DHE_DSS,     B_AES_256,     M_SHA256, T, max, tls12, P_SHA256);
7807
d026f4f9c119 6996365: Evaluate the priorities of cipher suites
xuelei
parents: 7043
diff changeset
  1157
29488
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1158
        add("TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA",     0xC00A, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1159
            K_ECDHE_ECDSA, B_AES_256,     M_SHA,    T);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1160
        add("TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA",       0xC014, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1161
            K_ECDHE_RSA,   B_AES_256,     M_SHA,    T);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1162
        add("TLS_RSA_WITH_AES_256_CBC_SHA",             0x0035, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1163
            K_RSA,         B_AES_256,     M_SHA,    T);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1164
        add("TLS_ECDH_ECDSA_WITH_AES_256_CBC_SHA",      0xC005, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1165
            K_ECDH_ECDSA,  B_AES_256,     M_SHA,    T);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1166
        add("TLS_ECDH_RSA_WITH_AES_256_CBC_SHA",        0xC00F, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1167
            K_ECDH_RSA,    B_AES_256,     M_SHA,    T);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1168
        add("TLS_DHE_RSA_WITH_AES_256_CBC_SHA",         0x0039, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1169
            K_DHE_RSA,     B_AES_256,     M_SHA,    T);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1170
        add("TLS_DHE_DSS_WITH_AES_256_CBC_SHA",         0x0038, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1171
            K_DHE_DSS,     B_AES_256,     M_SHA,    T);
7043
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
  1172
16913
a6f4d1626ad9 8011680: Re-integrate AEAD implementation of JSSE
xuelei
parents: 16126
diff changeset
  1173
        // AES_128(CBC)
29488
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1174
        add("TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA256",  0xc023, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1175
            K_ECDHE_ECDSA, B_AES_128,     M_SHA256, T, max, tls12, P_SHA256);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1176
        add("TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256",    0xc027, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1177
            K_ECDHE_RSA,   B_AES_128,     M_SHA256, T, max, tls12, P_SHA256);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1178
        add("TLS_RSA_WITH_AES_128_CBC_SHA256",          0x003c, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1179
            K_RSA,         B_AES_128,     M_SHA256, T, max, tls12, P_SHA256);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1180
        add("TLS_ECDH_ECDSA_WITH_AES_128_CBC_SHA256",   0xc025, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1181
            K_ECDH_ECDSA,  B_AES_128,     M_SHA256, T, max, tls12, P_SHA256);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1182
        add("TLS_ECDH_RSA_WITH_AES_128_CBC_SHA256",     0xc029, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1183
            K_ECDH_RSA,    B_AES_128,     M_SHA256, T, max, tls12, P_SHA256);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1184
        add("TLS_DHE_RSA_WITH_AES_128_CBC_SHA256",      0x0067, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1185
            K_DHE_RSA,     B_AES_128,     M_SHA256, T, max, tls12, P_SHA256);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1186
        add("TLS_DHE_DSS_WITH_AES_128_CBC_SHA256",      0x0040, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1187
            K_DHE_DSS,     B_AES_128,     M_SHA256, T, max, tls12, P_SHA256);
7043
5e2d1edeb2c7 6916074: Add support for TLS 1.2
xuelei
parents: 7039
diff changeset
  1188
29488
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1189
        add("TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA",     0xC009, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1190
            K_ECDHE_ECDSA, B_AES_128,     M_SHA,    T);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1191
        add("TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA",       0xC013, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1192
            K_ECDHE_RSA,   B_AES_128,     M_SHA,    T);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1193
        add("TLS_RSA_WITH_AES_128_CBC_SHA",             0x002f, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1194
            K_RSA,         B_AES_128,     M_SHA,    T);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1195
        add("TLS_ECDH_ECDSA_WITH_AES_128_CBC_SHA",      0xC004, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1196
            K_ECDH_ECDSA,  B_AES_128,     M_SHA,    T);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1197
        add("TLS_ECDH_RSA_WITH_AES_128_CBC_SHA",        0xC00E, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1198
            K_ECDH_RSA,    B_AES_128,     M_SHA,    T);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1199
        add("TLS_DHE_RSA_WITH_AES_128_CBC_SHA",         0x0033, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1200
            K_DHE_RSA,     B_AES_128,     M_SHA,    T);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1201
        add("TLS_DHE_DSS_WITH_AES_128_CBC_SHA",         0x0032, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1202
            K_DHE_DSS,     B_AES_128,     M_SHA,    T);
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1203
16913
a6f4d1626ad9 8011680: Re-integrate AEAD implementation of JSSE
xuelei
parents: 16126
diff changeset
  1204
        // 3DES_EDE
29488
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1205
        add("TLS_ECDHE_ECDSA_WITH_3DES_EDE_CBC_SHA",    0xC008, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1206
            K_ECDHE_ECDSA, B_3DES,        M_SHA,    T);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1207
        add("TLS_ECDHE_RSA_WITH_3DES_EDE_CBC_SHA",      0xC012, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1208
            K_ECDHE_RSA,   B_3DES,        M_SHA,    T);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1209
        add("SSL_RSA_WITH_3DES_EDE_CBC_SHA",            0x000a, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1210
            K_RSA,         B_3DES,        M_SHA,    T);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1211
        add("TLS_ECDH_ECDSA_WITH_3DES_EDE_CBC_SHA",     0xC003, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1212
            K_ECDH_ECDSA,  B_3DES,        M_SHA,    T);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1213
        add("TLS_ECDH_RSA_WITH_3DES_EDE_CBC_SHA",       0xC00D, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1214
            K_ECDH_RSA,    B_3DES,        M_SHA,    T);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1215
        add("SSL_DHE_RSA_WITH_3DES_EDE_CBC_SHA",        0x0016, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1216
            K_DHE_RSA,     B_3DES,        M_SHA,    T);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1217
        add("SSL_DHE_DSS_WITH_3DES_EDE_CBC_SHA",        0x0013, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1218
            K_DHE_DSS,     B_3DES,        M_SHA,    N);
6856
533f4ad71f88 6914943: Implement final TLS renegotiation fix
xuelei
parents: 5506
diff changeset
  1219
533f4ad71f88 6914943: Implement final TLS renegotiation fix
xuelei
parents: 5506
diff changeset
  1220
        // Renegotiation protection request Signalling Cipher Suite Value (SCSV)
29488
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1221
        add("TLS_EMPTY_RENEGOTIATION_INFO_SCSV",        0x00ff, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1222
            K_SCSV,        B_NULL,        M_NULL,   T);
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1223
7807
d026f4f9c119 6996365: Evaluate the priorities of cipher suites
xuelei
parents: 7043
diff changeset
  1224
        /*
d026f4f9c119 6996365: Evaluate the priorities of cipher suites
xuelei
parents: 7043
diff changeset
  1225
         * Definition of the CipherSuites that are supported but not enabled
d026f4f9c119 6996365: Evaluate the priorities of cipher suites
xuelei
parents: 7043
diff changeset
  1226
         * by default.
d026f4f9c119 6996365: Evaluate the priorities of cipher suites
xuelei
parents: 7043
diff changeset
  1227
         * They are listed in preference order, preferred first, using the
d026f4f9c119 6996365: Evaluate the priorities of cipher suites
xuelei
parents: 7043
diff changeset
  1228
         * following criteria:
d026f4f9c119 6996365: Evaluate the priorities of cipher suites
xuelei
parents: 7043
diff changeset
  1229
         * 1. CipherSuites for KRB5 need additional KRB5 service
d026f4f9c119 6996365: Evaluate the priorities of cipher suites
xuelei
parents: 7043
diff changeset
  1230
         *    configuration, and these suites are not common in practice,
d026f4f9c119 6996365: Evaluate the priorities of cipher suites
xuelei
parents: 7043
diff changeset
  1231
         *    so we put KRB5 based cipher suites at the end of the supported
d026f4f9c119 6996365: Evaluate the priorities of cipher suites
xuelei
parents: 7043
diff changeset
  1232
         *    list.
d026f4f9c119 6996365: Evaluate the priorities of cipher suites
xuelei
parents: 7043
diff changeset
  1233
         * 2. If a cipher suite has been obsoleted, we put it at the end of
d026f4f9c119 6996365: Evaluate the priorities of cipher suites
xuelei
parents: 7043
diff changeset
  1234
         *    the list.
d026f4f9c119 6996365: Evaluate the priorities of cipher suites
xuelei
parents: 7043
diff changeset
  1235
         * 3. Prefer the stronger bulk cipher, in the order of AES_256,
27722
0fb5bf040fd0 8043200: Decrease the preference mode of RC4 in the enabled cipher suite list
xuelei
parents: 25859
diff changeset
  1236
         *    AES_128, 3DES-EDE, RC-4, DES, DES40, RC4_40, NULL.
7807
d026f4f9c119 6996365: Evaluate the priorities of cipher suites
xuelei
parents: 7043
diff changeset
  1237
         * 4. Prefer the stronger MAC algorithm, in the order of SHA384,
d026f4f9c119 6996365: Evaluate the priorities of cipher suites
xuelei
parents: 7043
diff changeset
  1238
         *    SHA256, SHA, MD5.
d026f4f9c119 6996365: Evaluate the priorities of cipher suites
xuelei
parents: 7043
diff changeset
  1239
         * 5. Prefer the better performance of key exchange and digital
d026f4f9c119 6996365: Evaluate the priorities of cipher suites
xuelei
parents: 7043
diff changeset
  1240
         *    signature algorithm, in the order of ECDHE-ECDSA, ECDHE-RSA,
d026f4f9c119 6996365: Evaluate the priorities of cipher suites
xuelei
parents: 7043
diff changeset
  1241
         *    RSA, ECDH-ECDSA, ECDH-RSA, DHE-RSA, DHE-DSS, anonymous.
d026f4f9c119 6996365: Evaluate the priorities of cipher suites
xuelei
parents: 7043
diff changeset
  1242
         */
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1243
        p = DEFAULT_SUITES_PRIORITY;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1244
29488
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1245
        add("TLS_DH_anon_WITH_AES_256_GCM_SHA384",      0x00a7, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1246
            K_DH_ANON,     B_AES_256_GCM, M_NULL,   N, max, tls12, P_SHA384);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1247
        add("TLS_DH_anon_WITH_AES_128_GCM_SHA256",      0x00a6, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1248
            K_DH_ANON,     B_AES_128_GCM, M_NULL,   N, max, tls12, P_SHA256);
16913
a6f4d1626ad9 8011680: Re-integrate AEAD implementation of JSSE
xuelei
parents: 16126
diff changeset
  1249
29488
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1250
        add("TLS_DH_anon_WITH_AES_256_CBC_SHA256",      0x006d, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1251
            K_DH_ANON,     B_AES_256,     M_SHA256, N, max, tls12, P_SHA256);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1252
        add("TLS_ECDH_anon_WITH_AES_256_CBC_SHA",       0xC019, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1253
            K_ECDH_ANON,   B_AES_256,     M_SHA,    N);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1254
        add("TLS_DH_anon_WITH_AES_256_CBC_SHA",         0x003a, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1255
            K_DH_ANON,     B_AES_256,     M_SHA,    N);
7807
d026f4f9c119 6996365: Evaluate the priorities of cipher suites
xuelei
parents: 7043
diff changeset
  1256
29488
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1257
        add("TLS_DH_anon_WITH_AES_128_CBC_SHA256",      0x006c, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1258
            K_DH_ANON,     B_AES_128,     M_SHA256, N, max, tls12, P_SHA256);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1259
        add("TLS_ECDH_anon_WITH_AES_128_CBC_SHA",       0xC018, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1260
            K_ECDH_ANON,   B_AES_128,     M_SHA,    N);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1261
        add("TLS_DH_anon_WITH_AES_128_CBC_SHA",         0x0034, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1262
            K_DH_ANON,     B_AES_128,     M_SHA,    N);
7807
d026f4f9c119 6996365: Evaluate the priorities of cipher suites
xuelei
parents: 7043
diff changeset
  1263
29488
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1264
        add("TLS_ECDH_anon_WITH_3DES_EDE_CBC_SHA",      0xC017, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1265
            K_ECDH_ANON,   B_3DES,        M_SHA,    N);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1266
        add("SSL_DH_anon_WITH_3DES_EDE_CBC_SHA",        0x001b, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1267
            K_DH_ANON,     B_3DES,        M_SHA,    N);
27722
0fb5bf040fd0 8043200: Decrease the preference mode of RC4 in the enabled cipher suite list
xuelei
parents: 25859
diff changeset
  1268
31706
895170f33881 8043202: Prohibit RC4 cipher suites
asmotrak
parents: 30904
diff changeset
  1269
        // RC-4
895170f33881 8043202: Prohibit RC4 cipher suites
asmotrak
parents: 30904
diff changeset
  1270
        add("TLS_ECDHE_ECDSA_WITH_RC4_128_SHA",         0xC007, --p,
895170f33881 8043202: Prohibit RC4 cipher suites
asmotrak
parents: 30904
diff changeset
  1271
            K_ECDHE_ECDSA, B_RC4_128,     M_SHA,    N);
895170f33881 8043202: Prohibit RC4 cipher suites
asmotrak
parents: 30904
diff changeset
  1272
        add("TLS_ECDHE_RSA_WITH_RC4_128_SHA",           0xC011, --p,
895170f33881 8043202: Prohibit RC4 cipher suites
asmotrak
parents: 30904
diff changeset
  1273
            K_ECDHE_RSA,   B_RC4_128,     M_SHA,    N);
895170f33881 8043202: Prohibit RC4 cipher suites
asmotrak
parents: 30904
diff changeset
  1274
        add("SSL_RSA_WITH_RC4_128_SHA",                 0x0005, --p,
895170f33881 8043202: Prohibit RC4 cipher suites
asmotrak
parents: 30904
diff changeset
  1275
            K_RSA,         B_RC4_128,     M_SHA,    N);
895170f33881 8043202: Prohibit RC4 cipher suites
asmotrak
parents: 30904
diff changeset
  1276
        add("TLS_ECDH_ECDSA_WITH_RC4_128_SHA",          0xC002, --p,
895170f33881 8043202: Prohibit RC4 cipher suites
asmotrak
parents: 30904
diff changeset
  1277
            K_ECDH_ECDSA,  B_RC4_128,     M_SHA,    N);
895170f33881 8043202: Prohibit RC4 cipher suites
asmotrak
parents: 30904
diff changeset
  1278
        add("TLS_ECDH_RSA_WITH_RC4_128_SHA",            0xC00C, --p,
895170f33881 8043202: Prohibit RC4 cipher suites
asmotrak
parents: 30904
diff changeset
  1279
            K_ECDH_RSA,    B_RC4_128,     M_SHA,    N);
895170f33881 8043202: Prohibit RC4 cipher suites
asmotrak
parents: 30904
diff changeset
  1280
        add("SSL_RSA_WITH_RC4_128_MD5",                 0x0004, --p,
895170f33881 8043202: Prohibit RC4 cipher suites
asmotrak
parents: 30904
diff changeset
  1281
            K_RSA,         B_RC4_128,     M_MD5,    N);
895170f33881 8043202: Prohibit RC4 cipher suites
asmotrak
parents: 30904
diff changeset
  1282
29488
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1283
        add("TLS_ECDH_anon_WITH_RC4_128_SHA",           0xC016, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1284
            K_ECDH_ANON,   B_RC4_128,     M_SHA,    N);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1285
        add("SSL_DH_anon_WITH_RC4_128_MD5",             0x0018, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1286
            K_DH_ANON,     B_RC4_128,     M_MD5,    N);
7807
d026f4f9c119 6996365: Evaluate the priorities of cipher suites
xuelei
parents: 7043
diff changeset
  1287
27722
0fb5bf040fd0 8043200: Decrease the preference mode of RC4 in the enabled cipher suite list
xuelei
parents: 25859
diff changeset
  1288
        // weak cipher suites obsoleted in TLS 1.2
29488
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1289
        add("SSL_RSA_WITH_DES_CBC_SHA",                 0x0009, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1290
            K_RSA,         B_DES,         M_SHA,    N, tls12);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1291
        add("SSL_DHE_RSA_WITH_DES_CBC_SHA",             0x0015, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1292
            K_DHE_RSA,     B_DES,         M_SHA,    N, tls12);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1293
        add("SSL_DHE_DSS_WITH_DES_CBC_SHA",             0x0012, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1294
            K_DHE_DSS,     B_DES,         M_SHA,    N, tls12);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1295
        add("SSL_DH_anon_WITH_DES_CBC_SHA",             0x001a, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1296
            K_DH_ANON,     B_DES,         M_SHA,    N, tls12);
27722
0fb5bf040fd0 8043200: Decrease the preference mode of RC4 in the enabled cipher suite list
xuelei
parents: 25859
diff changeset
  1297
0fb5bf040fd0 8043200: Decrease the preference mode of RC4 in the enabled cipher suite list
xuelei
parents: 25859
diff changeset
  1298
        // weak cipher suites obsoleted in TLS 1.1
29488
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1299
        add("SSL_RSA_EXPORT_WITH_DES40_CBC_SHA",        0x0008, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1300
            K_RSA_EXPORT,  B_DES_40,      M_SHA,    N, tls11);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1301
        add("SSL_DHE_RSA_EXPORT_WITH_DES40_CBC_SHA",    0x0014, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1302
            K_DHE_RSA,     B_DES_40,      M_SHA,    N, tls11);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1303
        add("SSL_DHE_DSS_EXPORT_WITH_DES40_CBC_SHA",    0x0011, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1304
            K_DHE_DSS,     B_DES_40,      M_SHA,    N, tls11);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1305
        add("SSL_DH_anon_EXPORT_WITH_DES40_CBC_SHA",    0x0019, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1306
            K_DH_ANON,     B_DES_40,      M_SHA,    N, tls11);
27722
0fb5bf040fd0 8043200: Decrease the preference mode of RC4 in the enabled cipher suite list
xuelei
parents: 25859
diff changeset
  1307
29488
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1308
        add("SSL_RSA_EXPORT_WITH_RC4_40_MD5",           0x0003, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1309
            K_RSA_EXPORT,  B_RC4_40,      M_MD5,    N, tls11);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1310
        add("SSL_DH_anon_EXPORT_WITH_RC4_40_MD5",       0x0017, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1311
            K_DH_ANON,     B_RC4_40,      M_MD5,    N, tls11);
7807
d026f4f9c119 6996365: Evaluate the priorities of cipher suites
xuelei
parents: 7043
diff changeset
  1312
29488
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1313
        add("TLS_RSA_WITH_NULL_SHA256",                 0x003b, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1314
            K_RSA,         B_NULL,        M_SHA256, N, max, tls12, P_SHA256);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1315
        add("TLS_ECDHE_ECDSA_WITH_NULL_SHA",            0xC006, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1316
            K_ECDHE_ECDSA, B_NULL,        M_SHA,    N);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1317
        add("TLS_ECDHE_RSA_WITH_NULL_SHA",              0xC010, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1318
            K_ECDHE_RSA,   B_NULL,        M_SHA,    N);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1319
        add("SSL_RSA_WITH_NULL_SHA",                    0x0002, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1320
            K_RSA,         B_NULL,        M_SHA,    N);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1321
        add("TLS_ECDH_ECDSA_WITH_NULL_SHA",             0xC001, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1322
            K_ECDH_ECDSA,  B_NULL,        M_SHA,    N);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1323
        add("TLS_ECDH_RSA_WITH_NULL_SHA",               0xC00B, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1324
            K_ECDH_RSA,    B_NULL,        M_SHA,    N);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1325
        add("TLS_ECDH_anon_WITH_NULL_SHA",              0xC015, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1326
            K_ECDH_ANON,   B_NULL,        M_SHA,    N);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1327
        add("SSL_RSA_WITH_NULL_MD5",                    0x0001, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1328
            K_RSA,         B_NULL,        M_MD5,    N);
7807
d026f4f9c119 6996365: Evaluate the priorities of cipher suites
xuelei
parents: 7043
diff changeset
  1329
6856
533f4ad71f88 6914943: Implement final TLS renegotiation fix
xuelei
parents: 5506
diff changeset
  1330
        // Supported Kerberos ciphersuites from RFC2712
29488
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1331
        add("TLS_KRB5_WITH_3DES_EDE_CBC_SHA",           0x001f, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1332
            K_KRB5,        B_3DES,        M_SHA,    N);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1333
        add("TLS_KRB5_WITH_3DES_EDE_CBC_MD5",           0x0023, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1334
            K_KRB5,        B_3DES,        M_MD5,    N);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1335
        add("TLS_KRB5_WITH_RC4_128_SHA",                0x0020, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1336
            K_KRB5,        B_RC4_128,     M_SHA,    N);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1337
        add("TLS_KRB5_WITH_RC4_128_MD5",                0x0024, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1338
            K_KRB5,        B_RC4_128,     M_MD5,    N);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1339
        add("TLS_KRB5_WITH_DES_CBC_SHA",                0x001e, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1340
            K_KRB5,        B_DES,         M_SHA,    N, tls12);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1341
        add("TLS_KRB5_WITH_DES_CBC_MD5",                0x0022, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1342
            K_KRB5,        B_DES,         M_MD5,    N, tls12);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1343
        add("TLS_KRB5_EXPORT_WITH_DES_CBC_40_SHA",      0x0026, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1344
            K_KRB5_EXPORT, B_DES_40,      M_SHA,    N, tls11);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1345
        add("TLS_KRB5_EXPORT_WITH_DES_CBC_40_MD5",      0x0029, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1346
            K_KRB5_EXPORT, B_DES_40,      M_MD5,    N, tls11);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1347
        add("TLS_KRB5_EXPORT_WITH_RC4_40_SHA",          0x0028, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1348
            K_KRB5_EXPORT, B_RC4_40,      M_SHA,    N, tls11);
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1349
        add("TLS_KRB5_EXPORT_WITH_RC4_40_MD5",          0x002b, --p,
1f25b971e59a 6996366: convert MacAlg to an enum
jnimeh
parents: 27722
diff changeset
  1350
            K_KRB5_EXPORT, B_RC4_40,      M_MD5,    N, tls11);
7039
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
  1351
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
  1352
        /*
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
  1353
         * Other values from the TLS Cipher Suite Registry, as of August 2010.
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
  1354
         *
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
  1355
         * http://www.iana.org/assignments/tls-parameters/tls-parameters.xml
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
  1356
         *
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
  1357
         * Range      Registration Procedures   Notes
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
  1358
         * 000-191    Standards Action          Refers to value of first byte
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
  1359
         * 192-254    Specification Required    Refers to value of first byte
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
  1360
         * 255        Reserved for Private Use  Refers to value of first byte
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
  1361
         */
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1362
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1363
        // Register the names of a few additional CipherSuites.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1364
        // Makes them show up as names instead of numbers in
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1365
        // the debug output.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1366
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1367
        // remaining unsupported ciphersuites defined in RFC2246.
34380
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1368
        add("SSL_RSA_EXPORT_WITH_RC2_CBC_40_MD5",           0x0006);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1369
        add("SSL_RSA_WITH_IDEA_CBC_SHA",                    0x0007);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1370
        add("SSL_DH_DSS_EXPORT_WITH_DES40_CBC_SHA",         0x000b);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1371
        add("SSL_DH_DSS_WITH_DES_CBC_SHA",                  0x000c);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1372
        add("SSL_DH_DSS_WITH_3DES_EDE_CBC_SHA",             0x000d);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1373
        add("SSL_DH_RSA_EXPORT_WITH_DES40_CBC_SHA",         0x000e);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1374
        add("SSL_DH_RSA_WITH_DES_CBC_SHA",                  0x000f);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1375
        add("SSL_DH_RSA_WITH_3DES_EDE_CBC_SHA",             0x0010);
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1376
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1377
        // SSL 3.0 Fortezza ciphersuites
34380
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1378
        add("SSL_FORTEZZA_DMS_WITH_NULL_SHA",               0x001c);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1379
        add("SSL_FORTEZZA_DMS_WITH_FORTEZZA_CBC_SHA",       0x001d);
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1380
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1381
        // 1024/56 bit exportable ciphersuites from expired internet draft
34380
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1382
        add("SSL_RSA_EXPORT1024_WITH_DES_CBC_SHA",          0x0062);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1383
        add("SSL_DHE_DSS_EXPORT1024_WITH_DES_CBC_SHA",      0x0063);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1384
        add("SSL_RSA_EXPORT1024_WITH_RC4_56_SHA",           0x0064);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1385
        add("SSL_DHE_DSS_EXPORT1024_WITH_RC4_56_SHA",       0x0065);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1386
        add("SSL_DHE_DSS_WITH_RC4_128_SHA",                 0x0066);
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1387
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1388
        // Netscape old and new SSL 3.0 FIPS ciphersuites
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1389
        // see http://www.mozilla.org/projects/security/pki/nss/ssl/fips-ssl-ciphersuites.html
34380
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1390
        add("NETSCAPE_RSA_FIPS_WITH_3DES_EDE_CBC_SHA",      0xffe0);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1391
        add("NETSCAPE_RSA_FIPS_WITH_DES_CBC_SHA",           0xffe1);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1392
        add("SSL_RSA_FIPS_WITH_DES_CBC_SHA",                0xfefe);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1393
        add("SSL_RSA_FIPS_WITH_3DES_EDE_CBC_SHA",           0xfeff);
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1394
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1395
        // Unsupported Kerberos cipher suites from RFC 2712
34380
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1396
        add("TLS_KRB5_WITH_IDEA_CBC_SHA",                   0x0021);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1397
        add("TLS_KRB5_WITH_IDEA_CBC_MD5",                   0x0025);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1398
        add("TLS_KRB5_EXPORT_WITH_RC2_CBC_40_SHA",          0x0027);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1399
        add("TLS_KRB5_EXPORT_WITH_RC2_CBC_40_MD5",          0x002a);
7039
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
  1400
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
  1401
        // Unsupported cipher suites from RFC 4162
34380
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1402
        add("TLS_RSA_WITH_SEED_CBC_SHA",                    0x0096);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1403
        add("TLS_DH_DSS_WITH_SEED_CBC_SHA",                 0x0097);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1404
        add("TLS_DH_RSA_WITH_SEED_CBC_SHA",                 0x0098);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1405
        add("TLS_DHE_DSS_WITH_SEED_CBC_SHA",                0x0099);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1406
        add("TLS_DHE_RSA_WITH_SEED_CBC_SHA",                0x009a);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1407
        add("TLS_DH_anon_WITH_SEED_CBC_SHA",                0x009b);
7039
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
  1408
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
  1409
        // Unsupported cipher suites from RFC 4279
34380
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1410
        add("TLS_PSK_WITH_RC4_128_SHA",                     0x008a);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1411
        add("TLS_PSK_WITH_3DES_EDE_CBC_SHA",                0x008b);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1412
        add("TLS_PSK_WITH_AES_128_CBC_SHA",                 0x008c);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1413
        add("TLS_PSK_WITH_AES_256_CBC_SHA",                 0x008d);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1414
        add("TLS_DHE_PSK_WITH_RC4_128_SHA",                 0x008e);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1415
        add("TLS_DHE_PSK_WITH_3DES_EDE_CBC_SHA",            0x008f);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1416
        add("TLS_DHE_PSK_WITH_AES_128_CBC_SHA",             0x0090);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1417
        add("TLS_DHE_PSK_WITH_AES_256_CBC_SHA",             0x0091);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1418
        add("TLS_RSA_PSK_WITH_RC4_128_SHA",                 0x0092);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1419
        add("TLS_RSA_PSK_WITH_3DES_EDE_CBC_SHA",            0x0093);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1420
        add("TLS_RSA_PSK_WITH_AES_128_CBC_SHA",             0x0094);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1421
        add("TLS_RSA_PSK_WITH_AES_256_CBC_SHA",             0x0095);
7039
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
  1422
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
  1423
        // Unsupported cipher suites from RFC 4785
34380
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1424
        add("TLS_PSK_WITH_NULL_SHA",                        0x002c);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1425
        add("TLS_DHE_PSK_WITH_NULL_SHA",                    0x002d);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1426
        add("TLS_RSA_PSK_WITH_NULL_SHA",                    0x002e);
7039
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
  1427
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
  1428
        // Unsupported cipher suites from RFC 5246
34380
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1429
        add("TLS_DH_DSS_WITH_AES_128_CBC_SHA",              0x0030);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1430
        add("TLS_DH_RSA_WITH_AES_128_CBC_SHA",              0x0031);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1431
        add("TLS_DH_DSS_WITH_AES_256_CBC_SHA",              0x0036);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1432
        add("TLS_DH_RSA_WITH_AES_256_CBC_SHA",              0x0037);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1433
        add("TLS_DH_DSS_WITH_AES_128_CBC_SHA256",           0x003e);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1434
        add("TLS_DH_RSA_WITH_AES_128_CBC_SHA256",           0x003f);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1435
        add("TLS_DH_DSS_WITH_AES_256_CBC_SHA256",           0x0068);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1436
        add("TLS_DH_RSA_WITH_AES_256_CBC_SHA256",           0x0069);
7039
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
  1437
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
  1438
        // Unsupported cipher suites from RFC 5288
34380
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1439
        add("TLS_DH_RSA_WITH_AES_128_GCM_SHA256",           0x00a0);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1440
        add("TLS_DH_RSA_WITH_AES_256_GCM_SHA384",           0x00a1);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1441
        add("TLS_DH_DSS_WITH_AES_128_GCM_SHA256",           0x00a4);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1442
        add("TLS_DH_DSS_WITH_AES_256_GCM_SHA384",           0x00a5);
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1443
7039
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
  1444
        // Unsupported cipher suites from RFC 5487
34380
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1445
        add("TLS_PSK_WITH_AES_128_GCM_SHA256",              0x00a8);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1446
        add("TLS_PSK_WITH_AES_256_GCM_SHA384",              0x00a9);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1447
        add("TLS_DHE_PSK_WITH_AES_128_GCM_SHA256",          0x00aa);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1448
        add("TLS_DHE_PSK_WITH_AES_256_GCM_SHA384",          0x00ab);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1449
        add("TLS_RSA_PSK_WITH_AES_128_GCM_SHA256",          0x00ac);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1450
        add("TLS_RSA_PSK_WITH_AES_256_GCM_SHA384",          0x00ad);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1451
        add("TLS_PSK_WITH_AES_128_CBC_SHA256",              0x00ae);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1452
        add("TLS_PSK_WITH_AES_256_CBC_SHA384",              0x00af);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1453
        add("TLS_PSK_WITH_NULL_SHA256",                     0x00b0);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1454
        add("TLS_PSK_WITH_NULL_SHA384",                     0x00b1);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1455
        add("TLS_DHE_PSK_WITH_AES_128_CBC_SHA256",          0x00b2);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1456
        add("TLS_DHE_PSK_WITH_AES_256_CBC_SHA384",          0x00b3);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1457
        add("TLS_DHE_PSK_WITH_NULL_SHA256",                 0x00b4);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1458
        add("TLS_DHE_PSK_WITH_NULL_SHA384",                 0x00b5);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1459
        add("TLS_RSA_PSK_WITH_AES_128_CBC_SHA256",          0x00b6);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1460
        add("TLS_RSA_PSK_WITH_AES_256_CBC_SHA384",          0x00b7);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1461
        add("TLS_RSA_PSK_WITH_NULL_SHA256",                 0x00b8);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1462
        add("TLS_RSA_PSK_WITH_NULL_SHA384",                 0x00b9);
7039
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
  1463
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
  1464
        // Unsupported cipher suites from RFC 5932
34380
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1465
        add("TLS_RSA_WITH_CAMELLIA_128_CBC_SHA",            0x0041);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1466
        add("TLS_DH_DSS_WITH_CAMELLIA_128_CBC_SHA",         0x0042);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1467
        add("TLS_DH_RSA_WITH_CAMELLIA_128_CBC_SHA",         0x0043);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1468
        add("TLS_DHE_DSS_WITH_CAMELLIA_128_CBC_SHA",        0x0044);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1469
        add("TLS_DHE_RSA_WITH_CAMELLIA_128_CBC_SHA",        0x0045);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1470
        add("TLS_DH_anon_WITH_CAMELLIA_128_CBC_SHA",        0x0046);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1471
        add("TLS_RSA_WITH_CAMELLIA_256_CBC_SHA",            0x0084);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1472
        add("TLS_DH_DSS_WITH_CAMELLIA_256_CBC_SHA",         0x0085);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1473
        add("TLS_DH_RSA_WITH_CAMELLIA_256_CBC_SHA",         0x0086);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1474
        add("TLS_DHE_DSS_WITH_CAMELLIA_256_CBC_SHA",        0x0087);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1475
        add("TLS_DHE_RSA_WITH_CAMELLIA_256_CBC_SHA",        0x0088);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1476
        add("TLS_DH_anon_WITH_CAMELLIA_256_CBC_SHA",        0x0089);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1477
        add("TLS_RSA_WITH_CAMELLIA_128_CBC_SHA256",         0x00ba);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1478
        add("TLS_DH_DSS_WITH_CAMELLIA_128_CBC_SHA256",      0x00bb);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1479
        add("TLS_DH_RSA_WITH_CAMELLIA_128_CBC_SHA256",      0x00bc);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1480
        add("TLS_DHE_DSS_WITH_CAMELLIA_128_CBC_SHA256",     0x00bd);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1481
        add("TLS_DHE_RSA_WITH_CAMELLIA_128_CBC_SHA256",     0x00be);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1482
        add("TLS_DH_anon_WITH_CAMELLIA_128_CBC_SHA256",     0x00bf);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1483
        add("TLS_RSA_WITH_CAMELLIA_256_CBC_SHA256",         0x00c0);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1484
        add("TLS_DH_DSS_WITH_CAMELLIA_256_CBC_SHA256",      0x00c1);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1485
        add("TLS_DH_RSA_WITH_CAMELLIA_256_CBC_SHA256",      0x00c2);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1486
        add("TLS_DHE_DSS_WITH_CAMELLIA_256_CBC_SHA256",     0x00c3);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1487
        add("TLS_DHE_RSA_WITH_CAMELLIA_256_CBC_SHA256",     0x00c4);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1488
        add("TLS_DH_anon_WITH_CAMELLIA_256_CBC_SHA256",     0x00c5);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1489
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1490
        // TLS Fallback Signaling Cipher Suite Value (SCSV) RFC 7507
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1491
        add("TLS_FALLBACK_SCSV", 0x5600);
7039
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
  1492
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
  1493
        // Unsupported cipher suites from RFC 5054
34380
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1494
        add("TLS_SRP_SHA_WITH_3DES_EDE_CBC_SHA",            0xc01a);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1495
        add("TLS_SRP_SHA_RSA_WITH_3DES_EDE_CBC_SHA",        0xc01b);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1496
        add("TLS_SRP_SHA_DSS_WITH_3DES_EDE_CBC_SHA",        0xc01c);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1497
        add("TLS_SRP_SHA_WITH_AES_128_CBC_SHA",             0xc01d);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1498
        add("TLS_SRP_SHA_RSA_WITH_AES_128_CBC_SHA",         0xc01e);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1499
        add("TLS_SRP_SHA_DSS_WITH_AES_128_CBC_SHA",         0xc01f);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1500
        add("TLS_SRP_SHA_WITH_AES_256_CBC_SHA",             0xc020);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1501
        add("TLS_SRP_SHA_RSA_WITH_AES_256_CBC_SHA",         0xc021);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1502
        add("TLS_SRP_SHA_DSS_WITH_AES_256_CBC_SHA",         0xc022);
7039
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
  1503
6464c8e62a18 4873188: Support TLS 1.1
xuelei
parents: 6856
diff changeset
  1504
        // Unsupported cipher suites from RFC 5489
34380
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1505
        add("TLS_ECDHE_PSK_WITH_RC4_128_SHA",               0xc033);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1506
        add("TLS_ECDHE_PSK_WITH_3DES_EDE_CBC_SHA",          0xc034);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1507
        add("TLS_ECDHE_PSK_WITH_AES_128_CBC_SHA",           0xc035);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1508
        add("TLS_ECDHE_PSK_WITH_AES_256_CBC_SHA",           0xc036);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1509
        add("TLS_ECDHE_PSK_WITH_AES_128_CBC_SHA256",        0xc037);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1510
        add("TLS_ECDHE_PSK_WITH_AES_256_CBC_SHA384",        0xc038);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1511
        add("TLS_ECDHE_PSK_WITH_NULL_SHA",                  0xc039);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1512
        add("TLS_ECDHE_PSK_WITH_NULL_SHA256",               0xc03a);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1513
        add("TLS_ECDHE_PSK_WITH_NULL_SHA384",               0xc03b);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1514
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1515
        // Unsupported cipher suites from RFC 6209
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1516
        add("TLS_RSA_WITH_ARIA_128_CBC_SHA256",             0xc03c);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1517
        add("TLS_RSA_WITH_ARIA_256_CBC_SHA384",             0xc03d);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1518
        add("TLS_DH_DSS_WITH_ARIA_128_CBC_SHA256",          0xc03e);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1519
        add("TLS_DH_DSS_WITH_ARIA_256_CBC_SHA384",          0xc03f);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1520
        add("TLS_DH_RSA_WITH_ARIA_128_CBC_SHA256",          0xc040);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1521
        add("TLS_DH_RSA_WITH_ARIA_256_CBC_SHA384",          0xc041);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1522
        add("TLS_DHE_DSS_WITH_ARIA_128_CBC_SHA256",         0xc042);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1523
        add("TLS_DHE_DSS_WITH_ARIA_256_CBC_SHA384",         0xc043);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1524
        add("TLS_DHE_RSA_WITH_ARIA_128_CBC_SHA256",         0xc044);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1525
        add("TLS_DHE_RSA_WITH_ARIA_256_CBC_SHA384",         0xc045);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1526
        add("TLS_DH_anon_WITH_ARIA_128_CBC_SHA256",         0xc046);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1527
        add("TLS_DH_anon_WITH_ARIA_256_CBC_SHA384",         0xc047);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1528
        add("TLS_ECDHE_ECDSA_WITH_ARIA_128_CBC_SHA256",     0xc048);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1529
        add("TLS_ECDHE_ECDSA_WITH_ARIA_256_CBC_SHA384",     0xc049);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1530
        add("TLS_ECDH_ECDSA_WITH_ARIA_128_CBC_SHA256",      0xc04a);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1531
        add("TLS_ECDH_ECDSA_WITH_ARIA_256_CBC_SHA384",      0xc04b);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1532
        add("TLS_ECDHE_RSA_WITH_ARIA_128_CBC_SHA256",       0xc04c);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1533
        add("TLS_ECDHE_RSA_WITH_ARIA_256_CBC_SHA384",       0xc04d);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1534
        add("TLS_ECDH_RSA_WITH_ARIA_128_CBC_SHA256",        0xc04e);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1535
        add("TLS_ECDH_RSA_WITH_ARIA_256_CBC_SHA384",        0xc04f);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1536
        add("TLS_RSA_WITH_ARIA_128_GCM_SHA256",             0xc050);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1537
        add("TLS_RSA_WITH_ARIA_256_GCM_SHA384",             0xc051);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1538
        add("TLS_DHE_RSA_WITH_ARIA_128_GCM_SHA256",         0xc052);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1539
        add("TLS_DHE_RSA_WITH_ARIA_256_GCM_SHA384",         0xc053);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1540
        add("TLS_DH_RSA_WITH_ARIA_128_GCM_SHA256",          0xc054);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1541
        add("TLS_DH_RSA_WITH_ARIA_256_GCM_SHA384",          0xc055);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1542
        add("TLS_DHE_DSS_WITH_ARIA_128_GCM_SHA256",         0xc056);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1543
        add("TLS_DHE_DSS_WITH_ARIA_256_GCM_SHA384",         0xc057);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1544
        add("TLS_DH_DSS_WITH_ARIA_128_GCM_SHA256",          0xc058);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1545
        add("TLS_DH_DSS_WITH_ARIA_256_GCM_SHA384",          0xc059);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1546
        add("TLS_DH_anon_WITH_ARIA_128_GCM_SHA256",         0xc05a);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1547
        add("TLS_DH_anon_WITH_ARIA_256_GCM_SHA384",         0xc05b);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1548
        add("TLS_ECDHE_ECDSA_WITH_ARIA_128_GCM_SHA256",     0xc05c);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1549
        add("TLS_ECDHE_ECDSA_WITH_ARIA_256_GCM_SHA384",     0xc05d);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1550
        add("TLS_ECDH_ECDSA_WITH_ARIA_128_GCM_SHA256",      0xc05e);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1551
        add("TLS_ECDH_ECDSA_WITH_ARIA_256_GCM_SHA384",      0xc05f);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1552
        add("TLS_ECDHE_RSA_WITH_ARIA_128_GCM_SHA256",       0xc060);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1553
        add("TLS_ECDHE_RSA_WITH_ARIA_256_GCM_SHA384",       0xc061);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1554
        add("TLS_ECDH_RSA_WITH_ARIA_128_GCM_SHA256",        0xc062);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1555
        add("TLS_ECDH_RSA_WITH_ARIA_256_GCM_SHA384",        0xc063);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1556
        add("TLS_PSK_WITH_ARIA_128_CBC_SHA256",             0xc064);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1557
        add("TLS_PSK_WITH_ARIA_256_CBC_SHA384",             0xc065);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1558
        add("TLS_DHE_PSK_WITH_ARIA_128_CBC_SHA256",         0xc066);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1559
        add("TLS_DHE_PSK_WITH_ARIA_256_CBC_SHA384",         0xc067);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1560
        add("TLS_RSA_PSK_WITH_ARIA_128_CBC_SHA256",         0xc068);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1561
        add("TLS_RSA_PSK_WITH_ARIA_256_CBC_SHA384",         0xc069);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1562
        add("TLS_PSK_WITH_ARIA_128_GCM_SHA256",             0xc06a);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1563
        add("TLS_PSK_WITH_ARIA_256_GCM_SHA384",             0xc06b);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1564
        add("TLS_DHE_PSK_WITH_ARIA_128_GCM_SHA256",         0xc06c);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1565
        add("TLS_DHE_PSK_WITH_ARIA_256_GCM_SHA384",         0xc06d);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1566
        add("TLS_RSA_PSK_WITH_ARIA_128_GCM_SHA256",         0xc06e);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1567
        add("TLS_RSA_PSK_WITH_ARIA_256_GCM_SHA384",         0xc06f);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1568
        add("TLS_ECDHE_PSK_WITH_ARIA_128_CBC_SHA256",       0xc070);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1569
        add("TLS_ECDHE_PSK_WITH_ARIA_256_CBC_SHA384",       0xc071);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1570
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1571
        // Unsupported cipher suites from RFC 6367
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1572
        add("TLS_ECDHE_ECDSA_WITH_CAMELLIA_128_CBC_SHA256", 0xc072);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1573
        add("TLS_ECDHE_ECDSA_WITH_CAMELLIA_256_CBC_SHA384", 0xc073);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1574
        add("TLS_ECDH_ECDSA_WITH_CAMELLIA_128_CBC_SHA256",  0xc074);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1575
        add("TLS_ECDH_ECDSA_WITH_CAMELLIA_256_CBC_SHA384",  0xc075);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1576
        add("TLS_ECDHE_RSA_WITH_CAMELLIA_128_CBC_SHA256",   0xc076);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1577
        add("TLS_ECDHE_RSA_WITH_CAMELLIA_256_CBC_SHA384",   0xc077);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1578
        add("TLS_ECDH_RSA_WITH_CAMELLIA_128_CBC_SHA256",    0xc078);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1579
        add("TLS_ECDH_RSA_WITH_CAMELLIA_256_CBC_SHA384",    0xc079);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1580
        add("TLS_RSA_WITH_CAMELLIA_128_GCM_SHA256",         0xc07a);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1581
        add("TLS_RSA_WITH_CAMELLIA_256_GCM_SHA384",         0xc07b);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1582
        add("TLS_DHE_RSA_WITH_CAMELLIA_128_GCM_SHA256",     0xc07c);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1583
        add("TLS_DHE_RSA_WITH_CAMELLIA_256_GCM_SHA384",     0xc07d);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1584
        add("TLS_DH_RSA_WITH_CAMELLIA_128_GCM_SHA256",      0xc07e);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1585
        add("TLS_DH_RSA_WITH_CAMELLIA_256_GCM_SHA384",      0xc07f);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1586
        add("TLS_DHE_DSS_WITH_CAMELLIA_128_GCM_SHA256",     0xc080);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1587
        add("TLS_DHE_DSS_WITH_CAMELLIA_256_GCM_SHA384",     0xc081);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1588
        add("TLS_DH_DSS_WITH_CAMELLIA_128_GCM_SHA256",      0xc082);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1589
        add("TLS_DH_DSS_WITH_CAMELLIA_256_GCM_SHA384",      0xc083);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1590
        add("TLS_DH_anon_WITH_CAMELLIA_128_GCM_SHA256",     0xc084);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1591
        add("TLS_DH_anon_WITH_CAMELLIA_256_GCM_SHA384",     0xc085);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1592
        add("TLS_ECDHE_ECDSA_WITH_CAMELLIA_128_GCM_SHA256", 0xc086);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1593
        add("TLS_ECDHE_ECDSA_WITH_CAMELLIA_256_GCM_SHA384", 0xc087);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1594
        add("TLS_ECDH_ECDSA_WITH_CAMELLIA_128_GCM_SHA256",  0xc088);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1595
        add("TLS_ECDH_ECDSA_WITH_CAMELLIA_256_GCM_SHA384",  0xc089);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1596
        add("TLS_ECDHE_RSA_WITH_CAMELLIA_128_GCM_SHA256",   0xc08a);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1597
        add("TLS_ECDHE_RSA_WITH_CAMELLIA_256_GCM_SHA384",   0xc08b);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1598
        add("TLS_ECDH_RSA_WITH_CAMELLIA_128_GCM_SHA256",    0xc08c);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1599
        add("TLS_ECDH_RSA_WITH_CAMELLIA_256_GCM_SHA384",    0xc08d);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1600
        add("TLS_PSK_WITH_CAMELLIA_128_GCM_SHA256",         0xc08e);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1601
        add("TLS_PSK_WITH_CAMELLIA_256_GCM_SHA384",         0xc08f);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1602
        add("TLS_DHE_PSK_WITH_CAMELLIA_128_GCM_SHA256",     0xc090);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1603
        add("TLS_DHE_PSK_WITH_CAMELLIA_256_GCM_SHA384",     0xc091);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1604
        add("TLS_RSA_PSK_WITH_CAMELLIA_128_GCM_SHA256",     0xc092);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1605
        add("TLS_RSA_PSK_WITH_CAMELLIA_256_GCM_SHA384",     0xc093);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1606
        add("TLS_PSK_WITH_CAMELLIA_128_CBC_SHA256",         0xc094);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1607
        add("TLS_PSK_WITH_CAMELLIA_256_CBC_SHA384",         0xc095);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1608
        add("TLS_DHE_PSK_WITH_CAMELLIA_128_CBC_SHA256",     0xc096);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1609
        add("TLS_DHE_PSK_WITH_CAMELLIA_256_CBC_SHA384",     0xc097);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1610
        add("TLS_RSA_PSK_WITH_CAMELLIA_128_CBC_SHA256",     0xc098);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1611
        add("TLS_RSA_PSK_WITH_CAMELLIA_256_CBC_SHA384",     0xc099);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1612
        add("TLS_ECDHE_PSK_WITH_CAMELLIA_128_CBC_SHA256",   0xc09a);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1613
        add("TLS_ECDHE_PSK_WITH_CAMELLIA_256_CBC_SHA384",   0xc09b);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1614
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1615
        // Unsupported cipher suites from RFC 6655
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1616
        add("TLS_RSA_WITH_AES_128_CCM",                     0xc09c);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1617
        add("TLS_RSA_WITH_AES_256_CCM",                     0xc09d);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1618
        add("TLS_DHE_RSA_WITH_AES_128_CCM",                 0xc09e);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1619
        add("TLS_DHE_RSA_WITH_AES_256_CCM",                 0xc09f);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1620
        add("TLS_RSA_WITH_AES_128_CCM_8",                   0xc0A0);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1621
        add("TLS_RSA_WITH_AES_256_CCM_8",                   0xc0A1);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1622
        add("TLS_DHE_RSA_WITH_AES_128_CCM_8",               0xc0A2);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1623
        add("TLS_DHE_RSA_WITH_AES_256_CCM_8",               0xc0A3);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1624
        add("TLS_PSK_WITH_AES_128_CCM",                     0xc0A4);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1625
        add("TLS_PSK_WITH_AES_256_CCM",                     0xc0A5);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1626
        add("TLS_DHE_PSK_WITH_AES_128_CCM",                 0xc0A6);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1627
        add("TLS_DHE_PSK_WITH_AES_256_CCM",                 0xc0A7);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1628
        add("TLS_PSK_WITH_AES_128_CCM_8",                   0xc0A8);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1629
        add("TLS_PSK_WITH_AES_256_CCM_8",                   0xc0A9);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1630
        add("TLS_PSK_DHE_WITH_AES_128_CCM_8",               0xc0Aa);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1631
        add("TLS_PSK_DHE_WITH_AES_256_CCM_8",               0xc0Ab);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1632
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1633
        // Unsupported cipher suites from RFC 7251
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1634
        add("TLS_ECDHE_ECDSA_WITH_AES_128_CCM",             0xc0Ac);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1635
        add("TLS_ECDHE_ECDSA_WITH_AES_256_CCM",             0xc0Ad);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1636
        add("TLS_ECDHE_ECDSA_WITH_AES_128_CCM_8",           0xc0Ae);
2b2609379881 8144093: JEP 244/8051498 - TLS Application-Layer Protocol Negotiation Extension
vinnie
parents: 33236
diff changeset
  1637
        add("TLS_ECDHE_ECDSA_WITH_AES_256_CCM_8",           0xc0Af);
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1638
    }
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1639
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1640
    // ciphersuite SSL_NULL_WITH_NULL_NULL
32649
2ee9017c7597 8136583: Core libraries should use blessed modifier order
martin
parents: 31706
diff changeset
  1641
    static final CipherSuite C_NULL = CipherSuite.valueOf(0, 0);
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1642
6856
533f4ad71f88 6914943: Implement final TLS renegotiation fix
xuelei
parents: 5506
diff changeset
  1643
    // ciphersuite TLS_EMPTY_RENEGOTIATION_INFO_SCSV
32649
2ee9017c7597 8136583: Core libraries should use blessed modifier order
martin
parents: 31706
diff changeset
  1644
    static final CipherSuite C_SCSV = CipherSuite.valueOf(0x00, 0xff);
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1645
}