Skip to content

Commit 4a26af0

Browse files
committed
dtls 1.3: Add cid size to output buffer length
1 parent ee2b77c commit 4a26af0

1 file changed

Lines changed: 8 additions & 0 deletions

File tree

src/internal.c

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24794,6 +24794,14 @@ int SendData(WOLFSSL* ssl, const void* data, int sz)
2479424794
if (IsEncryptionOn(ssl, 1) || ssl->options.tls1_3)
2479524795
outputSz += cipherExtraData(ssl);
2479624796

24797+
#if defined(WOLFSSL_DTLS) && defined(WOLFSSL_DTLS_CID)
24798+
if (ssl->options.dtls) {
24799+
unsigned int cidSz = 0;
24800+
if (wolfSSL_dtls_cid_get_tx_size(ssl, &cidSz) == WOLFSSL_SUCCESS)
24801+
outputSz += cidSz;
24802+
}
24803+
#endif
24804+
2479724805
/* check for available size */
2479824806
if ((ret = CheckAvailableSize(ssl, outputSz)) != 0)
2479924807
return ssl->error = ret;

0 commit comments

Comments
 (0)