diff --git a/src/auth.c b/src/auth.c index 5a6c351..31167aa 100644 --- a/src/auth.c +++ b/src/auth.c @@ -238,8 +238,9 @@ char* certificate_auth() return NULL; } - if (strcmp(get_config_string("//idpc:ocspCheck"), "true") == 0 && - ocsp_check(getenv("SSL_CLIENT_CERT")) != 0) { + if (get_config_string("//idpc:ocspCheck") && + strcmp(get_config_string("//idpc:ocspCheck"), "true") == 0 && + ocsp_check(getenv("SSL_CLIENT_CERT")) != 0) { fprintf(stderr, "ocsp check failed\n"); return NULL; }