LCOV - code coverage report
Current view: top level - waltz/quic - fd_quic_retry_private.h (source / functions) Hit Total Coverage
Test: cov.lcov Lines: 1 1 100.0 %
Date: 2024-11-13 11:58:15 Functions: 0 0 -

          Line data    Source code
       1             : #include "fd_quic_retry.h"
       2             : 
       3             : #include "fd_quic_proto.h"
       4             : #include "fd_quic_proto.c"
       5             : 
       6             : /* FD_QUIC_RETRY_MAX_PSEUDO_SZ is the max encoded size of a Retry pseudo
       7             :    header. */
       8             : 
       9             : #define FD_QUIC_RETRY_MAX_PSEUDO_SZ          \
      10             :   ( sizeof(uchar) + FD_QUIC_MAX_CONN_ID_SZ + \
      11             :     FD_QUIC_MAX_FOOTPRINT(retry_hdr) +       \
      12             :     FD_QUIC_RETRY_MAX_TOKEN_SZ )
      13             : 
      14             : /* FD_QUIC_RETRY_MAX_SZ is the max encoded size of a Retry packet. */
      15             : 
      16             : #define FD_QUIC_RETRY_MAX_SZ           \
      17             :   ( FD_QUIC_MAX_FOOTPRINT(retry_hdr) + \
      18             :     FD_QUIC_RETRY_MAX_TOKEN_SZ +       \
      19             :     FD_QUIC_CRYPTO_TAG_SZ )
      20             : 
      21             : /* FD_QUIC_RETRY_EXPIRE_SHIFT: Expiry timestamps (unix nanos) are right-
      22             :    shifted 22 bits to avoid leaking high-precision timing information.
      23             :    This results in a precision of ~4.19 ms. */
      24             : 
      25     6002472 : #define FD_QUIC_RETRY_EXPIRE_SHIFT (22)
      26             : 
      27             : ulong
      28             : fd_quic_retry_pseudo(
      29             :     uchar                     out[ FD_QUIC_RETRY_MAX_PSEUDO_SZ ],
      30             :     void const *              retry_pkt,
      31             :     ulong                     retry_pkt_sz,
      32             :     fd_quic_conn_id_t const * orig_dst_conn_id );

Generated by: LCOV version 1.14