if (rl->msg_callback != NULL) {
unsigned char *recordstart;
+ const int version1_3 = rl->isdtls ? DTLS1_3_VERSION : TLS1_3_VERSION;
recordstart = WPACKET_get_curr(thispkt) - len - headerlen;
rl->msg_callback(1, thiswr->rec_version, SSL3_RT_HEADER, recordstart,
headerlen, rl->cbarg);
- if (rl->version == TLS1_3_VERSION && rl->enc_ctx != NULL) {
+ if (rl->version == version1_3 && rl->enc_ctx != NULL) {
unsigned char ctype = thistempl->type;
rl->msg_callback(1, thiswr->rec_version, SSL3_RT_INNER_CONTENT_TYPE,
return 0;
}
} else {
+ const int version1_3 = rl->isdtls ? DTLS1_3_VERSION : TLS1_3_VERSION;
+
if (rl->version == TLS_ANY_VERSION) {
if ((rec->rec_version >> 8) != SSL3_VERSION_MAJOR) {
if (rl->is_first_record) {
return 0;
}
}
- } else if (rl->version == TLS1_3_VERSION) {
+ } else if (rl->version == version1_3) {
/*
* In this case we know we are going to negotiate TLSv1.3, but we've
* had an HRR, so we haven't actually done so yet. In TLSv1.3 we