test/tls13encryptiontest.c:330: error: BUFFER_OVERRUN_L3
  Offset added: 8 Size: [1, +oo] by call to `load_record`.
Showing all 9 steps of the trace


test/tls13encryptiontest.c:360:14: Call
358.   
359.           /* Decrypt it */
360.           if (!TEST_int_eq(tls13_enc(s, &rec, 1, 0), 1)) {
                    ^
361.               TEST_info("Failed to decrypt record %"OSSLzu"", ctr);
362.               goto err;

ssl/record/ssl3_record_tls13.c:24:1: Parameter `recs->data->strlen`
  22.    *       an internal error occurred.
  23.    */
  24. > int tls13_enc(SSL *s, SSL3_RECORD *recs, size_t n_recs, int send)
  25.   {
  26.       EVP_CIPHER_CTX *ctx;

test/tls13encryptiontest.c:330:14: Call
328.           /* Load the record */
329.           ivlen = EVP_CIPHER_iv_length(ciph);
330.           if (!load_record(&rec, &refdata[ctr], &key, s->read_iv, ivlen,
                    ^
331.                            RECORD_LAYER_get_read_sequence(&s->rlayer))) {
332.               TEST_error("Failed loading key into EVP_CIPHER_CTX");

test/tls13encryptiontest.c:224:1: <Length trace>
222.   }
223.   
224. > static int load_record(SSL3_RECORD *rec, RECORD_DATA *recd, unsigned char **key,
225.                          unsigned char *iv, size_t ivlen, unsigned char *seq)
226.   {

test/tls13encryptiontest.c:224:1: Parameter `recd->seq->strlen`
  222.   }
  223.   
  224. > static int load_record(SSL3_RECORD *rec, RECORD_DATA *recd, unsigned char **key,
  225.                          unsigned char *iv, size_t ivlen, unsigned char *seq)
  226.   {

test/tls13encryptiontest.c:232:10: Call
  230.       *key = OPENSSL_hexstr2buf(recd->key, NULL);
  231.       ivtmp = OPENSSL_hexstr2buf(recd->iv, NULL);
  232.       sq = OPENSSL_hexstr2buf(recd->seq, NULL);
                  ^
  233.       pt = multihexstr2buf(recd->plaintext, &ptlen);
  234.   

crypto/o_str.c:161:9: Assignment
    159.       if ((hexbuf = OPENSSL_malloc(s >> 1)) == NULL) {
    160.           CRYPTOerr(CRYPTO_F_OPENSSL_HEXSTR2BUF, ERR_R_MALLOC_FAILURE);
    161.           return NULL;
                   ^
    162.       }
    163.       for (p = (const unsigned char *)str, q = hexbuf; *p; ) {

test/tls13encryptiontest.c:232:5: Assignment
  230.       *key = OPENSSL_hexstr2buf(recd->key, NULL);
  231.       ivtmp = OPENSSL_hexstr2buf(recd->iv, NULL);
  232.       sq = OPENSSL_hexstr2buf(recd->seq, NULL);
             ^
  233.       pt = multihexstr2buf(recd->plaintext, &ptlen);
  234.   

test/tls13encryptiontest.c:246:5: Array access: Offset added: 8 Size: [1, +oo] by call to `load_record` 
  244.       memcpy(rec->data, pt, ptlen);
  245.       OPENSSL_free(pt);
  246.       memcpy(seq, sq, SEQ_NUM_SIZE);
             ^
  247.       OPENSSL_free(sq);
  248.       memcpy(iv, ivtmp, ivlen);
