Lines Matching refs:msg_hdr
154 static hm_fragment *dtls1_hm_fragment_new(const struct hm_header_st *msg_hdr) { in dtls1_hm_fragment_new() argument
161 frag->type = msg_hdr->type; in dtls1_hm_fragment_new()
162 frag->seq = msg_hdr->seq; in dtls1_hm_fragment_new()
163 frag->msg_len = msg_hdr->msg_len; in dtls1_hm_fragment_new()
167 (uint8_t *)OPENSSL_malloc(DTLS1_HM_HEADER_LENGTH + msg_hdr->msg_len); in dtls1_hm_fragment_new()
175 !CBB_add_u8(&cbb, msg_hdr->type) || in dtls1_hm_fragment_new()
176 !CBB_add_u24(&cbb, msg_hdr->msg_len) || in dtls1_hm_fragment_new()
177 !CBB_add_u16(&cbb, msg_hdr->seq) || in dtls1_hm_fragment_new()
179 !CBB_add_u24(&cbb, msg_hdr->msg_len) || in dtls1_hm_fragment_new()
187 if (msg_hdr->msg_len > 0) { in dtls1_hm_fragment_new()
189 if (msg_hdr->msg_len + 7 < msg_hdr->msg_len) { in dtls1_hm_fragment_new()
193 size_t bitmask_len = (msg_hdr->msg_len + 7) / 8; in dtls1_hm_fragment_new()
270 SSL *ssl, const struct hm_header_st *msg_hdr) { in dtls1_get_incoming_message() argument
271 if (msg_hdr->seq < ssl->d1->handshake_read_seq || in dtls1_get_incoming_message()
272 msg_hdr->seq - ssl->d1->handshake_read_seq >= SSL_MAX_HANDSHAKE_FLIGHT) { in dtls1_get_incoming_message()
276 size_t idx = msg_hdr->seq % SSL_MAX_HANDSHAKE_FLIGHT; in dtls1_get_incoming_message()
279 assert(frag->seq == msg_hdr->seq); in dtls1_get_incoming_message()
282 if (frag->type != msg_hdr->type || in dtls1_get_incoming_message()
283 frag->msg_len != msg_hdr->msg_len) { in dtls1_get_incoming_message()
292 frag = dtls1_hm_fragment_new(msg_hdr); in dtls1_get_incoming_message()
341 struct hm_header_st msg_hdr; in dtls1_process_handshake_record() local
343 if (!dtls1_parse_fragment(&cbs, &msg_hdr, &body)) { in dtls1_process_handshake_record()
349 const size_t frag_off = msg_hdr.frag_off; in dtls1_process_handshake_record()
350 const size_t frag_len = msg_hdr.frag_len; in dtls1_process_handshake_record()
351 const size_t msg_len = msg_hdr.msg_len; in dtls1_process_handshake_record()
361 if (ssl->d1->r_epoch == 1 && msg_hdr.seq != ssl->d1->handshake_read_seq) { in dtls1_process_handshake_record()
367 if (msg_hdr.seq < ssl->d1->handshake_read_seq || in dtls1_process_handshake_record()
368 msg_hdr.seq > in dtls1_process_handshake_record()
374 hm_fragment *frag = dtls1_get_incoming_message(ssl, &msg_hdr); in dtls1_process_handshake_record()