forked from wolfSSL/wolfssl
Fix for CRL serial number matching to also check length. Fix for testing the verify callback override ‘-j’ to not enable CRL since the CA’s are not loaded for this test.
This commit is contained in:
@ -1729,7 +1729,7 @@ THREAD_RETURN WOLFSSL_THREAD client_test(void* args)
|
|||||||
}
|
}
|
||||||
|
|
||||||
#ifdef HAVE_CRL
|
#ifdef HAVE_CRL
|
||||||
if (disableCRL == 0) {
|
if (disableCRL == 0 && !useVerifyCb) {
|
||||||
#ifdef HAVE_IO_TIMEOUT
|
#ifdef HAVE_IO_TIMEOUT
|
||||||
wolfIO_SetTimeout(DEFAULT_TIMEOUT_SEC);
|
wolfIO_SetTimeout(DEFAULT_TIMEOUT_SEC);
|
||||||
#endif
|
#endif
|
||||||
|
@ -318,7 +318,8 @@ static int CheckCertCRLList(WOLFSSL_CRL* crl, DecodedCert* cert, int *pFoundEntr
|
|||||||
RevokedCert* rc = crle->certs;
|
RevokedCert* rc = crle->certs;
|
||||||
|
|
||||||
while (rc) {
|
while (rc) {
|
||||||
if (XMEMCMP(rc->serialNumber, cert->serial, rc->serialSz) == 0) {
|
if (rc->serialSz == cert->serialSz &&
|
||||||
|
XMEMCMP(rc->serialNumber, cert->serial, rc->serialSz) == 0) {
|
||||||
WOLFSSL_MSG("Cert revoked");
|
WOLFSSL_MSG("Cert revoked");
|
||||||
ret = CRL_CERT_REVOKED;
|
ret = CRL_CERT_REVOKED;
|
||||||
break;
|
break;
|
||||||
|
Reference in New Issue
Block a user