forked from wolfSSL/wolfssl
Fix resumption code around when not available
Can't set a ticket if the encryption callback is NULL. If no useable pre-shared key is found then we won't do PSK.
This commit is contained in:
@ -8062,7 +8062,7 @@ int TLSX_PopulateExtensions(WOLFSSL* ssl, byte isServer)
|
|||||||
}
|
}
|
||||||
|
|
||||||
#if defined(HAVE_SESSION_TICKET)
|
#if defined(HAVE_SESSION_TICKET)
|
||||||
if (ssl->options.resuming) {
|
if (ssl->options.resuming && ssl->ctx->ticketEncCb != NULL) {
|
||||||
WOLFSSL_SESSION* sess = &ssl->session;
|
WOLFSSL_SESSION* sess = &ssl->session;
|
||||||
word32 milli;
|
word32 milli;
|
||||||
|
|
||||||
|
@ -3173,6 +3173,9 @@ static int DoPreSharedKeys(WOLFSSL* ssl, const byte* input, word32 helloSz,
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (current == NULL)
|
||||||
|
return 0;
|
||||||
|
|
||||||
/* Hash the rest of the ClientHello. */
|
/* Hash the rest of the ClientHello. */
|
||||||
ret = HashInputRaw(ssl, input + helloSz - bindersLen, bindersLen);
|
ret = HashInputRaw(ssl, input + helloSz - bindersLen, bindersLen);
|
||||||
if (ret != 0)
|
if (ret != 0)
|
||||||
|
Reference in New Issue
Block a user