forked from wolfSSL/wolfssl
add wolfSSL and wolfSSL_CTX LoadCRLBuffer()
This commit is contained in:
25
src/ssl.c
25
src/ssl.c
@ -4002,6 +4002,31 @@ int wolfSSL_CertManagerLoadCRLBuffer(WOLFSSL_CERT_MANAGER* cm,
|
||||
return BufferLoadCRL(cm->crl, buff, sz, type);
|
||||
}
|
||||
|
||||
|
||||
int wolfSSL_CTX_LoadCRLBuffer(WOLFSSL_CTX* ctx, const unsigned char* buff,
|
||||
long sz, int type)
|
||||
{
|
||||
WOLFSSL_ENTER("wolfSSL_CTX_LoadCRLBuffer");
|
||||
|
||||
if (ctx == NULL)
|
||||
return BAD_FUNC_ARG;
|
||||
|
||||
return wolfSSL_CertManagerLoadCRLBuffer(ctx->cm, buff, sz, type);
|
||||
}
|
||||
|
||||
|
||||
int wolfSSL_LoadCRLBuffer(WOLFSSL* ssl, const unsigned char* buff,
|
||||
long sz, int type)
|
||||
{
|
||||
WOLFSSL_ENTER("wolfSSL_LoadCRLBuffer");
|
||||
|
||||
if (ssl == NULL || ssl->ctx == NULL)
|
||||
return BAD_FUNC_ARG;
|
||||
|
||||
return wolfSSL_CertManagerLoadCRLBuffer(ssl->ctx->cm, buff, sz, type);
|
||||
}
|
||||
|
||||
|
||||
#endif /* HAVE_CRL */
|
||||
|
||||
/* turn on CRL if off and compiled in, set options */
|
||||
|
@ -1326,6 +1326,8 @@ WOLFSSL_API void* wolfSSL_GetRsaDecCtx(WOLFSSL* ssl);
|
||||
WOLFSSL_API int wolfSSL_EnableCRL(WOLFSSL* ssl, int options);
|
||||
WOLFSSL_API int wolfSSL_DisableCRL(WOLFSSL* ssl);
|
||||
WOLFSSL_API int wolfSSL_LoadCRL(WOLFSSL*, const char*, int, int);
|
||||
WOLFSSL_API int wolfSSL_LoadCRLBuffer(WOLFSSL*,
|
||||
const unsigned char*, long sz, int);
|
||||
WOLFSSL_API int wolfSSL_SetCRL_Cb(WOLFSSL*, CbMissingCRL);
|
||||
WOLFSSL_API int wolfSSL_EnableOCSP(WOLFSSL*, int options);
|
||||
WOLFSSL_API int wolfSSL_DisableOCSP(WOLFSSL*);
|
||||
@ -1335,6 +1337,8 @@ WOLFSSL_API void* wolfSSL_GetRsaDecCtx(WOLFSSL* ssl);
|
||||
WOLFSSL_API int wolfSSL_CTX_EnableCRL(WOLFSSL_CTX* ctx, int options);
|
||||
WOLFSSL_API int wolfSSL_CTX_DisableCRL(WOLFSSL_CTX* ctx);
|
||||
WOLFSSL_API int wolfSSL_CTX_LoadCRL(WOLFSSL_CTX*, const char*, int, int);
|
||||
WOLFSSL_API int wolfSSL_CTX_LoadCRLBuffer(WOLFSSL_CTX*,
|
||||
const unsigned char*, long sz, int);
|
||||
WOLFSSL_API int wolfSSL_CTX_SetCRL_Cb(WOLFSSL_CTX*, CbMissingCRL);
|
||||
WOLFSSL_API int wolfSSL_CTX_EnableOCSP(WOLFSSL_CTX*, int options);
|
||||
WOLFSSL_API int wolfSSL_CTX_DisableOCSP(WOLFSSL_CTX*);
|
||||
|
Reference in New Issue
Block a user