Lines Matching refs:frag_len
50 size_t frag_len);
57 size_t frag_len);
61 static hm_fragment *dtls1_hm_fragment_new(size_t frag_len, int reassembly) in dtls1_hm_fragment_new() argument
70 if (frag_len) { in dtls1_hm_fragment_new()
71 if ((buf = OPENSSL_malloc(frag_len)) == NULL) { in dtls1_hm_fragment_new()
82 bitmask = OPENSSL_zalloc(RSMBLY_BITMASK_SIZE(frag_len)); in dtls1_hm_fragment_new()
436 size_t frag_off, frag_len, msg_len; in dtls1_preprocess_fragment() local
440 frag_len = msg_hdr->frag_len; in dtls1_preprocess_fragment()
443 if ((frag_off + frag_len) > msg_len in dtls1_preprocess_fragment()
555 size_t frag_len = frag->msg_header.frag_len; in dtls1_retrieve_buffered_fragment() local
561 if (ret && frag->msg_header.frag_len > 0) { in dtls1_retrieve_buffered_fragment()
565 frag->msg_header.frag_len); in dtls1_retrieve_buffered_fragment()
582 *len = frag_len; in dtls1_retrieve_buffered_fragment()
601 size_t frag_len = msg_hdr->frag_len; in dtls1_reassemble_fragment() local
605 if ((msg_hdr->frag_off + frag_len) > msg_hdr->msg_len || in dtls1_reassemble_fragment()
609 if (frag_len == 0) { in dtls1_reassemble_fragment()
624 frag->msg_header.frag_len = frag->msg_header.msg_len; in dtls1_reassemble_fragment()
643 while (frag_len) { in dtls1_reassemble_fragment()
646 frag_len > in dtls1_reassemble_fragment()
648 frag_len, 0, &readbytes); in dtls1_reassemble_fragment()
651 frag_len -= readbytes; in dtls1_reassemble_fragment()
659 frag_len, 0, &readbytes); in dtls1_reassemble_fragment()
660 if (i <= 0 || readbytes != frag_len) in dtls1_reassemble_fragment()
666 (long)(msg_hdr->frag_off + frag_len)); in dtls1_reassemble_fragment()
711 size_t frag_len = msg_hdr->frag_len; in dtls1_process_out_of_seq_message() local
715 if ((msg_hdr->frag_off + frag_len) > msg_hdr->msg_len) in dtls1_process_out_of_seq_message()
728 if (item != NULL && frag_len != msg_hdr->msg_len) in dtls1_process_out_of_seq_message()
741 while (frag_len) { in dtls1_process_out_of_seq_message()
744 frag_len > in dtls1_process_out_of_seq_message()
746 frag_len, 0, &readbytes); in dtls1_process_out_of_seq_message()
749 frag_len -= readbytes; in dtls1_process_out_of_seq_message()
752 if (frag_len != msg_hdr->msg_len) { in dtls1_process_out_of_seq_message()
756 if (frag_len > dtls1_max_handshake_message_len(s)) in dtls1_process_out_of_seq_message()
759 frag = dtls1_hm_fragment_new(frag_len, 0); in dtls1_process_out_of_seq_message()
765 if (frag_len) { in dtls1_process_out_of_seq_message()
770 frag->fragment, frag_len, 0, in dtls1_process_out_of_seq_message()
772 if (i<=0 || readbytes != frag_len) in dtls1_process_out_of_seq_message()
806 size_t mlen, frag_off, frag_len; in dtls_get_reassembled_message() local
822 ret = dtls1_retrieve_buffered_fragment(s, &frag_len); in dtls_get_reassembled_message()
828 s->init_num = frag_len; in dtls_get_reassembled_message()
829 *len = frag_len; in dtls_get_reassembled_message()
867 frag_len = msg_hdr.frag_len; in dtls_get_reassembled_message()
873 if (frag_len > s->rlayer.tlsrecs[s->rlayer.curr_rec].length) { in dtls_get_reassembled_message()
901 if (frag_len && frag_len < mlen) { in dtls_get_reassembled_message()
935 if (frag_len > 0) { in dtls_get_reassembled_message()
939 &p[frag_off], frag_len, 0, &readbytes); in dtls_get_reassembled_message()
958 if (readbytes != frag_len) { in dtls_get_reassembled_message()
980 *len = s->init_num = frag_len; in dtls_get_reassembled_message()
1153 frag->msg_header.frag_len = s->d1->w_msg_hdr.msg_len; in dtls1_buffer_message()
1218 frag->msg_header.frag_len); in dtls1_retransmit_message()
1251 size_t frag_off, size_t frag_len) in dtls1_set_message_header() argument
1259 frag_off, frag_len); in dtls1_set_message_header()
1266 size_t frag_off, size_t frag_len) in dtls1_set_message_header_int() argument
1274 msg_hdr->frag_len = frag_len; in dtls1_set_message_header_int()
1278 dtls1_fix_message_header(SSL_CONNECTION *s, size_t frag_off, size_t frag_len) in dtls1_fix_message_header() argument
1283 msg_hdr->frag_len = frag_len; in dtls1_fix_message_header()
1296 l2n3(msg_hdr->frag_len, p); in dtls1_write_message_header()
1310 n2l3(data, msg_hdr->frag_len); in dtls1_get_message_header()
1348 s->d1->w_msg_hdr.frag_len = msglen - DTLS1_HM_HEADER_LENGTH; in dtls1_close_construct_packet()