Skip to content

Commit 219131a

Browse files
committed
Merge yaoweibin branch of upstream_check_module to
Update ssl_check for services mandating newer versions of TLS xiaokai-wang#2
2 parents 77b1a6b + 9aecf15 commit 219131a

File tree

1 file changed

+20
-15
lines changed

1 file changed

+20
-15
lines changed

ngx_http_upstream_check_module.c

+20-15
Original file line numberDiff line numberDiff line change
@@ -629,27 +629,32 @@ static ngx_str_t fastcgi_default_params[] = {
629629
*/
630630
static char sslv3_client_hello_pkt[] = {
631631
"\x16" /* ContentType : 0x16 = Hanshake */
632-
"\x03\x00" /* ProtocolVersion : 0x0300 = SSLv3 */
633-
"\x00\x79" /* ContentLength : 0x79 bytes after this one */
632+
"\x03\x01" /* ProtocolVersion : 0x0301 = TLSv1.0 */
633+
"\x00\x6f" /* ContentLength : 0x6f bytes after this one */
634634
"\x01" /* HanshakeType : 0x01 = CLIENT HELLO */
635-
"\x00\x00\x75" /* HandshakeLength : 0x75 bytes after this one */
636-
"\x03\x00" /* Hello Version : 0x0300 = v3 */
635+
"\x00\x00\x6b" /* HandshakeLength : 0x6b bytes after this one */
636+
"\x03\x03" /* Hello Version : 0x0303 = TLSv1.2 */
637637
"\x00\x00\x00\x00" /* Unix GMT Time (s) : filled with <now> (@0x0B) */
638638
NGX_SSL_RANDOM /* Random : must be exactly 28 bytes */
639639
"\x00" /* Session ID length : empty (no session ID) */
640-
"\x00\x4E" /* Cipher Suite Length : 78 bytes after this one */
641-
"\x00\x01" "\x00\x02" "\x00\x03" "\x00\x04" /* 39 most common ciphers : */
642-
"\x00\x05" "\x00\x06" "\x00\x07" "\x00\x08" /* 0x01...0x1B, 0x2F...0x3A */
643-
"\x00\x09" "\x00\x0A" "\x00\x0B" "\x00\x0C" /* This covers RSA/DH, */
644-
"\x00\x0D" "\x00\x0E" "\x00\x0F" "\x00\x10" /* various bit lengths, */
645-
"\x00\x11" "\x00\x12" "\x00\x13" "\x00\x14" /* SHA1/MD5, DES/3DES/AES... */
646-
"\x00\x15" "\x00\x16" "\x00\x17" "\x00\x18"
647-
"\x00\x19" "\x00\x1A" "\x00\x1B" "\x00\x2F"
648-
"\x00\x30" "\x00\x31" "\x00\x32" "\x00\x33"
649-
"\x00\x34" "\x00\x35" "\x00\x36" "\x00\x37"
650-
"\x00\x38" "\x00\x39" "\x00\x3A"
640+
"\x00\x1a" /* Cipher Suite Length : \x1a bytes after this one */
641+
"\xc0\x2b" "\xc0\x2f" "\xcc\xa9" "\xcc\xa8" /* 13 modern ciphers */
642+
"\xc0\x0a" "\xc0\x09" "\xc0\x13" "\xc0\x14"
643+
"\x00\x33" "\x00\x39" "\x00\x2f" "\x00\x35"
644+
"\x00\x0a"
651645
"\x01" /* Compression Length : 0x01 = 1 byte for types */
652646
"\x00" /* Compression Type : 0x00 = NULL compression */
647+
"\x00\x28" /* Extensions length */
648+
"\x00\x0a" /* EC extension */
649+
"\x00\x08" /* extension length */
650+
"\x00\x06" /* curves length */
651+
"\x00\x17" "\x00\x18" "\x00\x19" /* Three curves */
652+
"\x00\x0d" /* Signature extension */
653+
"\x00\x18" /* extension length */
654+
"\x00\x16" /* hash list length */
655+
"\x04\x01" "\x05\x01" "\x06\x01" "\x02\x01" /* 11 hash algorithms */
656+
"\x04\x03" "\x05\x03" "\x06\x03" "\x02\x03"
657+
"\x05\x02" "\x04\x02" "\x02\x02"
653658
};
654659

655660

0 commit comments

Comments
 (0)