Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ocsp: propagate ocsp cb return error #8055

Merged
merged 1 commit into from
Oct 15, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions src/ocsp.c
Original file line number Diff line number Diff line change
Expand Up @@ -536,6 +536,9 @@ int CheckOcspRequest(WOLFSSL_OCSP* ocsp, OcspRequest* ocspRequest,
if (responseSz == WC_NO_ERR_TRACE(WOLFSSL_CBIO_ERR_WANT_READ)) {
ret = OCSP_WANT_READ;
}
else if (responseSz == WC_NO_ERR_TRACE(WOLFSSL_CBIO_ERR_TIMEOUT)){
ret = HTTP_TIMEOUT;
}

XFREE(request, ocsp->cm->heap, DYNAMIC_TYPE_OCSP);

Expand Down
4 changes: 2 additions & 2 deletions tests/api.c
Original file line number Diff line number Diff line change
Expand Up @@ -92179,7 +92179,7 @@ static int test_override_alt_cert_chain_ocsp_cb(void* ioCtx, const char* url,
(void)request;
(void)requestSz;
(void)response;
return -1;
return WOLFSSL_CBIO_ERR_GENERAL;
}

static int test_override_alt_cert_chain_client_ctx_ready(WOLFSSL_CTX* ctx)
Expand Down Expand Up @@ -96685,7 +96685,7 @@ static int test_ocsp_callback_fails_cb(void* ctx, const char* url, int urlSz,
(void)ocspReqBuf;
(void)ocspReqSz;
(void)ocspRespBuf;
return -1;
return WOLFSSL_CBIO_ERR_GENERAL;
}
static int test_ocsp_callback_fails(void)
{
Expand Down
Loading