Merge pull request #761 from yuanzh78/patch-2

Update s3_lib.c ssl_get_algorithm2()
This commit is contained in:
Zhi Guan
2019-09-03 18:45:16 +08:00
committed by GitHub

View File

@@ -4219,6 +4219,12 @@ long ssl_get_algorithm2(SSL *s)
} else if (s->s3->tmp.new_cipher->algorithm_mkey & SSL_PSK) {
if (alg2 == (SSL_HANDSHAKE_MAC_SHA384 | TLS1_PRF_SHA384))
return SSL_HANDSHAKE_MAC_DEFAULT | TLS1_PRF;
} else{
// in the end of finish msg of gmssl handshake, to get the correct hash algo
printf("ssl_get_algorithm2=0x08x\n", ssl_get_algorithm2);
if (alg2 == 0x909){
return SSL_HANDSHAKE_MAC_SM3 | TLS1_PRF_SM3;
}
}
return alg2;
}