Regarding with commit #4899aad884880bb8ef1859ea6b57eded013cd2b4, send no certificate alert only if SSLv3, otherwise proceed with size 0 certificate.

pull/1319/head
Go Hosohara 2017-07-30 18:00:12 +09:00 committed by Jacob Barthelmeh
parent a918dfdb33
commit d6e22346e3
1 changed files with 12 additions and 3 deletions

View File

@ -13206,9 +13206,18 @@ int SendCertificate(WOLFSSL* ssl)
return 0; /* not needed */
if (ssl->options.sendVerify == SEND_BLANK_CERT) {
SendAlert(ssl, alert_warning, no_certificate);
return 0;
}
if (ssl->version.major == SSLv3_MAJOR
&& ssl->version.minor == SSLv3_MINOR){
SendAlert(ssl, alert_warning, no_certificate);
return 0;
} else {
certSz = 0;
certChainSz = 0;
headerSz = CERT_HEADER_SZ;
length = CERT_HEADER_SZ;
listSz = 0;
}
}
else {
if (!ssl->buffers.certificate) {
WOLFSSL_MSG("Send Cert missing certificate buffer");