Use certificate_request specific to TLS 1.3

This commit is contained in:
Henry Case 2018-03-26 16:08:18 +01:00 committed by Henry Dorsett Case
parent c6745f1879
commit 6acee69d6b

View File

@ -1152,8 +1152,12 @@ func (c *Conn) readHandshake() (interface{}, error) {
m = new(certificateMsg)
}
case typeCertificateRequest:
m = &certificateRequestMsg{
hasSignatureAndHash: c.vers >= VersionTLS12,
if c.vers >= VersionTLS13 {
m = new(certificateRequestMsg13)
} else {
m = &certificateRequestMsg{
hasSignatureAndHash: c.vers >= VersionTLS12,
}
}
case typeCertificateStatus:
m = new(certificateStatusMsg)