ssl/tls13_enc.c:55: error: INTEGER_OVERFLOW_L2
  ([0, +oo] - 1):unsigned64 by call to `WPACKET_close`.
Showing all 11 steps of the trace


ssl/tls13_enc.c:52:17: Call
50.       if (!WPACKET_init_static_len(&pkt, hkdflabel, sizeof(hkdflabel), 0)
51.               || !WPACKET_put_bytes_u16(&pkt, outlen)
52.               || !WPACKET_start_sub_packet_u8(&pkt)
                      ^
53.               || !WPACKET_memcpy(&pkt, label_prefix, sizeof(label_prefix) - 1)
54.               || !WPACKET_memcpy(&pkt, label, labellen)

ssl/packet.c:277:1: Parameter `lenbytes`
  275.   }
  276.   
  277. > int WPACKET_start_sub_packet_len__(WPACKET *pkt, size_t lenbytes)
  278.   {
  279.       WPACKET_SUB *sub;

ssl/packet.c:294:5: Assignment
  292.       pkt->subs = sub;
  293.       sub->pwritten = pkt->written + lenbytes;
  294.       sub->lenbytes = lenbytes;
             ^
  295.   
  296.       if (lenbytes == 0) {

ssl/tls13_enc.c:55:17: Call
53.               || !WPACKET_memcpy(&pkt, label_prefix, sizeof(label_prefix) - 1)
54.               || !WPACKET_memcpy(&pkt, label, labellen)
55.               || !WPACKET_close(&pkt)
                      ^
56.               || !WPACKET_sub_memcpy_u8(&pkt, hash, (hash == NULL) ? 0 : hashlen)
57.               || !WPACKET_get_total_written(&pkt, &hkdflabellen)

ssl/packet.c:245:1: Parameter `pkt->curr`
  243.   }
  244.   
  245. > int WPACKET_close(WPACKET *pkt)
  246.   {
  247.       /*

ssl/packet.c:254:12: Call
  252.           return 0;
  253.   
  254.       return wpacket_intern_close(pkt, pkt->subs, 1);
                    ^
  255.   }
  256.   

ssl/packet.c:188:1: <LHS trace>
186.    * (i.e. it fills in all the lengths), but doesn't actually close anything.
187.    */
188. > static int wpacket_intern_close(WPACKET *pkt, WPACKET_SUB *sub, int doclose)
189.   {
190.       size_t packlen = pkt->written - sub->pwritten;

ssl/packet.c:188:1: Parameter `pkt->curr`
    186.    * (i.e. it fills in all the lengths), but doesn't actually close anything.
    187.    */
    188. > static int wpacket_intern_close(WPACKET *pkt, WPACKET_SUB *sub, int doclose)
    189.   {
    190.       size_t packlen = pkt->written - sub->pwritten;

ssl/packet.c:188:1: <RHS trace>
186.    * (i.e. it fills in all the lengths), but doesn't actually close anything.
187.    */
188. > static int wpacket_intern_close(WPACKET *pkt, WPACKET_SUB *sub, int doclose)
189.   {
190.       size_t packlen = pkt->written - sub->pwritten;

ssl/packet.c:188:1: Parameter `sub->lenbytes`
    186.    * (i.e. it fills in all the lengths), but doesn't actually close anything.
    187.    */
    188. > static int wpacket_intern_close(WPACKET *pkt, WPACKET_SUB *sub, int doclose)
    189.   {
    190.       size_t packlen = pkt->written - sub->pwritten;

ssl/packet.c:203:13: Binary operation: ([0, +oo] - 1):unsigned64 by call to `WPACKET_close` 
    201.   
    202.           /* Deallocate any bytes allocated for the length of the WPACKET */
    203.           if ((pkt->curr - sub->lenbytes) == sub->packet_len) {
                       ^
    204.               pkt->written -= sub->lenbytes;
    205.               pkt->curr -= sub->lenbytes;
