From: Timo Sirainen Date: Tue, 10 Feb 2009 00:37:17 +0000 (-0500) Subject: doveconf shouldn't check if it has access to ssl files. For example deliver doesn... X-Git-Tag: 2.0.alpha1~1037^2~2 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=1cbc0c6372d24168962698c5f4d3e15df8943ebf;p=thirdparty%2Fdovecot%2Fcore.git doveconf shouldn't check if it has access to ssl files. For example deliver doesn't need it. --HG-- branch : HEAD --- diff --git a/src/login-common/login-settings.c b/src/login-common/login-settings.c index 57d16988c2..61784bc132 100644 --- a/src/login-common/login-settings.c +++ b/src/login-common/login-settings.c @@ -107,14 +107,19 @@ static int ssl_settings_check(void *_set ATTR_UNUSED, const char **error_r) *error_r = "ssl_cert_file not set"; return FALSE; } - if (access(set->ssl_cert_file, R_OK) < 0) { - *error_r = t_strdup_printf("ssl_cert_file: access(%s) failed: %m", - set->ssl_cert_file); + if (*set->ssl_key_file == '\0') { + *error_r = "ssl_key_file not set"; + return FALSE; + } + if (set->ssl_verify_client_cert && *set->ssl_ca_file == '\0') { + *error_r = "ssl_verify_client_cert set, but ssl_ca_file not"; return FALSE; } - if (*set->ssl_key_file == '\0') { - *error_r = "ssl_key_file not set"; +#ifndef CONFIG_BINARY + if (access(set->ssl_cert_file, R_OK) < 0) { + *error_r = t_strdup_printf("ssl_cert_file: access(%s) failed: %m", + set->ssl_cert_file); return FALSE; } if (access(set->ssl_key_file, R_OK) < 0) { @@ -122,17 +127,12 @@ static int ssl_settings_check(void *_set ATTR_UNUSED, const char **error_r) set->ssl_key_file); return FALSE; } - if (*set->ssl_ca_file != '\0' && access(set->ssl_ca_file, R_OK) < 0) { *error_r = t_strdup_printf("ssl_ca_file: access(%s) failed: %m", set->ssl_ca_file); return FALSE; } - - if (set->ssl_verify_client_cert && *set->ssl_ca_file == '\0') { - *error_r = "ssl_verify_client_cert set, but ssl_ca_file not"; - return FALSE; - } +#endif return TRUE; #endif }