mirror of https://github.com/wolfSSL/wolfssl.git
update tls13 to handle an OCSP_WANT_READ, update
async client test to retry connect on OCSP_WANT_READ instead of timing outpull/6632/head
parent
9ea681030f
commit
2e4b651b87
|
@ -10,7 +10,8 @@ jobs:
|
||||||
config: [
|
config: [
|
||||||
# Add new configs here
|
# Add new configs here
|
||||||
'--enable-asynccrypt --enable-all --enable-dtls13',
|
'--enable-asynccrypt --enable-all --enable-dtls13',
|
||||||
'--enable-asynccrypt-sw',
|
'--enable-asynccrypt-sw --enable-ocspstapling --enable-ocspstapling2',
|
||||||
|
'--enable-ocsp CFLAGS="-DTEST_NONBLOCK_CERTS"',
|
||||||
]
|
]
|
||||||
name: make check
|
name: make check
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
|
|
@ -223,6 +223,9 @@ static int NonBlockingSSL_Connect(WOLFSSL* ssl)
|
||||||
#ifdef WOLFSSL_ASYNC_CRYPT
|
#ifdef WOLFSSL_ASYNC_CRYPT
|
||||||
|| error == WC_PENDING_E
|
|| error == WC_PENDING_E
|
||||||
#endif
|
#endif
|
||||||
|
#ifdef WOLFSSL_NONBLOCK_OCSP
|
||||||
|
|| error == OCSP_WANT_READ
|
||||||
|
#endif
|
||||||
) {
|
) {
|
||||||
#ifndef WOLFSSL_CALLBACKS
|
#ifndef WOLFSSL_CALLBACKS
|
||||||
ret = wolfSSL_connect(ssl);
|
ret = wolfSSL_connect(ssl);
|
||||||
|
|
|
@ -11479,12 +11479,12 @@ int DoTls13HandShakeMsgType(WOLFSSL* ssl, byte* input, word32* inOutIdx,
|
||||||
* == 0) */
|
* == 0) */
|
||||||
*inOutIdx -= HANDSHAKE_HEADER_SZ;
|
*inOutIdx -= HANDSHAKE_HEADER_SZ;
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
|
|
||||||
/* reset error */
|
/* make sure async error is cleared */
|
||||||
if (ret == 0 && ssl->error == WC_PENDING_E)
|
if (ret == 0 && (ssl->error == WC_PENDING_E || ssl->error == OCSP_WANT_READ)) {
|
||||||
ssl->error = 0;
|
ssl->error = 0;
|
||||||
|
}
|
||||||
|
#endif
|
||||||
if (ret == 0 && type != client_hello && type != session_ticket &&
|
if (ret == 0 && type != client_hello && type != session_ticket &&
|
||||||
type != key_update) {
|
type != key_update) {
|
||||||
ret = HashInput(ssl, input + inIdx, size);
|
ret = HashInput(ssl, input + inIdx, size);
|
||||||
|
|
Loading…
Reference in New Issue