forked from wolfSSL/wolfssl
SSL default ticket encryption callback: check in len on decrypt
Make sure that the length of the data to decrypt is correct for the default ticket encryption implementation.
This commit is contained in:
@@ -38842,6 +38842,10 @@ static int DefTicketEncCb(WOLFSSL* ssl, byte key_name[WOLFSSL_TICKET_NAME_SZ],
|
||||
|
||||
WOLFSSL_ENTER("DefTicketEncCb");
|
||||
|
||||
if ((!enc) && (inLen != sizeof(InternalTicket))) {
|
||||
return BUFFER_E;
|
||||
}
|
||||
|
||||
/* Check we have setup the RNG, name and primary key. */
|
||||
if (keyCtx->expirary[0] == 0) {
|
||||
#ifndef SINGLE_THREADED
|
||||
|
Reference in New Issue
Block a user