git://git.exim.org
/
exim.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Add the NOTQUIT ACL.
[exim.git]
/
src
/
src
/
readconf.c
diff --git
a/src/src/readconf.c
b/src/src/readconf.c
index fd04ab328917cfc90929d3e7f79edbd5b88564a7..2ac260d8b9e4d1d74dac4e0cf18de134af96c479 100644
(file)
--- a/
src/src/readconf.c
+++ b/
src/src/readconf.c
@@
-1,10
+1,10
@@
-/* $Cambridge: exim/src/src/readconf.c,v 1.
24 2006/09/19 11:28:45
ph10 Exp $ */
+/* $Cambridge: exim/src/src/readconf.c,v 1.
32 2007/08/22 10:10:23
ph10 Exp $ */
/*************************************************
* Exim - an Internet mail transport agent *
*************************************************/
/*************************************************
* Exim - an Internet mail transport agent *
*************************************************/
-/* Copyright (c) University of Cambridge 1995 - 200
6
*/
+/* Copyright (c) University of Cambridge 1995 - 200
7
*/
/* See the file NOTICE for conditions of use and distribution. */
/* Functions for reading the configuration file, and for displaying
/* See the file NOTICE for conditions of use and distribution. */
/* Functions for reading the configuration file, and for displaying
@@
-150,6
+150,7
@@
static optionlist optionlist_config[] = {
#ifdef WITH_CONTENT_SCAN
{ "acl_smtp_mime", opt_stringptr, &acl_smtp_mime },
#endif
#ifdef WITH_CONTENT_SCAN
{ "acl_smtp_mime", opt_stringptr, &acl_smtp_mime },
#endif
+ { "acl_smtp_notquit", opt_stringptr, &acl_smtp_notquit },
{ "acl_smtp_predata", opt_stringptr, &acl_smtp_predata },
{ "acl_smtp_quit", opt_stringptr, &acl_smtp_quit },
{ "acl_smtp_rcpt", opt_stringptr, &acl_smtp_rcpt },
{ "acl_smtp_predata", opt_stringptr, &acl_smtp_predata },
{ "acl_smtp_quit", opt_stringptr, &acl_smtp_quit },
{ "acl_smtp_rcpt", opt_stringptr, &acl_smtp_rcpt },
@@
-195,6
+196,9
@@
static optionlist optionlist_config[] = {
{ "deliver_drop_privilege", opt_bool, &deliver_drop_privilege },
{ "deliver_queue_load_max", opt_fixed, &deliver_queue_load_max },
{ "delivery_date_remove", opt_bool, &delivery_date_remove },
{ "deliver_drop_privilege", opt_bool, &deliver_drop_privilege },
{ "deliver_queue_load_max", opt_fixed, &deliver_queue_load_max },
{ "delivery_date_remove", opt_bool, &delivery_date_remove },
+#ifdef ENABLE_DISABLE_FSYNC
+ { "disable_fsync", opt_bool, &disable_fsync },
+#endif
{ "disable_ipv6", opt_bool, &disable_ipv6 },
{ "dns_again_means_nonexist", opt_stringptr, &dns_again_means_nonexist },
{ "dns_check_names_pattern", opt_stringptr, &check_dns_names_pattern },
{ "disable_ipv6", opt_bool, &disable_ipv6 },
{ "dns_again_means_nonexist", opt_stringptr, &dns_again_means_nonexist },
{ "dns_check_names_pattern", opt_stringptr, &check_dns_names_pattern },
@@
-206,6
+210,7
@@
static optionlist optionlist_config[] = {
/* This option is now a no-op, retained for compability */
{ "drop_cr", opt_bool, &drop_cr },
/*********************************************************/
/* This option is now a no-op, retained for compability */
{ "drop_cr", opt_bool, &drop_cr },
/*********************************************************/
+ { "dsn_from", opt_stringptr, &dsn_from },
{ "envelope_to_remove", opt_bool, &envelope_to_remove },
{ "errors_copy", opt_stringptr, &errors_copy },
{ "errors_reply_to", opt_stringptr, &errors_reply_to },
{ "envelope_to_remove", opt_bool, &envelope_to_remove },
{ "errors_copy", opt_stringptr, &errors_copy },
{ "errors_reply_to", opt_stringptr, &errors_reply_to },
@@
-218,6
+223,11
@@
static optionlist optionlist_config[] = {
{ "freeze_tell", opt_stringptr, &freeze_tell },
{ "gecos_name", opt_stringptr, &gecos_name },
{ "gecos_pattern", opt_stringptr, &gecos_pattern },
{ "freeze_tell", opt_stringptr, &freeze_tell },
{ "gecos_name", opt_stringptr, &gecos_name },
{ "gecos_pattern", opt_stringptr, &gecos_pattern },
+#ifdef SUPPORT_TLS
+ { "gnutls_require_kx", opt_stringptr, &gnutls_require_kx },
+ { "gnutls_require_mac", opt_stringptr, &gnutls_require_mac },
+ { "gnutls_require_protocols", opt_stringptr, &gnutls_require_proto },
+#endif
{ "header_line_maxsize", opt_int, &header_line_maxsize },
{ "header_maxsize", opt_int, &header_maxsize },
{ "headers_charset", opt_stringptr, &headers_charset },
{ "header_line_maxsize", opt_int, &header_line_maxsize },
{ "header_maxsize", opt_int, &header_maxsize },
{ "headers_charset", opt_stringptr, &headers_charset },
@@
-293,6
+303,7
@@
static optionlist optionlist_config[] = {
{ "queue_only", opt_bool, &queue_only },
{ "queue_only_file", opt_stringptr, &queue_only_file },
{ "queue_only_load", opt_fixed, &queue_only_load },
{ "queue_only", opt_bool, &queue_only },
{ "queue_only_file", opt_stringptr, &queue_only_file },
{ "queue_only_load", opt_fixed, &queue_only_load },
+ { "queue_only_load_latch", opt_bool, &queue_only_load_latch },
{ "queue_only_override", opt_bool, &queue_only_override },
{ "queue_run_in_order", opt_bool, &queue_run_in_order },
{ "queue_run_max", opt_int, &queue_run_max },
{ "queue_only_override", opt_bool, &queue_only_override },
{ "queue_run_in_order", opt_bool, &queue_run_in_order },
{ "queue_run_max", opt_int, &queue_run_max },
@@
-1820,8
+1831,10
@@
switch (type)
case opt_int:
{
uschar *endptr;
case opt_int:
{
uschar *endptr;
+ long int lvalue;
+
errno = 0;
errno = 0;
- value = strtol(CS s, CSS &endptr, intbase);
+
l
value = strtol(CS s, CSS &endptr, intbase);
if (endptr == s)
log_write(0, LOG_PANIC_DIE|LOG_CONFIG_IN, "%sinteger expected for %s",
if (endptr == s)
log_write(0, LOG_PANIC_DIE|LOG_CONFIG_IN, "%sinteger expected for %s",
@@
-1831,25
+1844,28
@@
switch (type)
{
if (tolower(*endptr) == 'k')
{
{
if (tolower(*endptr) == 'k')
{
- if (
value > INT_MAX/1024 ||
value < INT_MIN/1024) errno = ERANGE;
- else value *= 1024;
+ if (
lvalue > INT_MAX/1024 || l
value < INT_MIN/1024) errno = ERANGE;
+ else
l
value *= 1024;
endptr++;
}
else if (tolower(*endptr) == 'm')
{
endptr++;
}
else if (tolower(*endptr) == 'm')
{
- if (
value > INT_MAX/(1024*1024) ||
value < INT_MIN/(1024*1024))
+ if (
lvalue > INT_MAX/(1024*1024) || l
value < INT_MIN/(1024*1024))
errno = ERANGE;
errno = ERANGE;
- else value *= 1024*1024;
+ else
l
value *= 1024*1024;
endptr++;
}
}
endptr++;
}
}
- if (errno == ERANGE) log_write(0, LOG_PANIC_DIE|LOG_CONFIG_IN,
- "absolute value of integer \"%s\" is too large (overflow)", s);
+ if (errno == ERANGE || lvalue > INT_MAX || lvalue < INT_MIN)
+ log_write(0, LOG_PANIC_DIE|LOG_CONFIG_IN,
+ "absolute value of integer \"%s\" is too large (overflow)", s);
while (isspace(*endptr)) endptr++;
if (*endptr != 0)
extra_chars_error(endptr, inttype, US"integer value for ", name);
while (isspace(*endptr)) endptr++;
if (*endptr != 0)
extra_chars_error(endptr, inttype, US"integer value for ", name);
+
+ value = (int)lvalue;
}
if (data_block == NULL)
}
if (data_block == NULL)
@@
-3455,10
+3471,10
@@
else if (len == 4 && strncmpic(pp, US"auth", len) == 0 &&
strncmpic(q+1, US"failed", p-q-1) == 0)
*basic_errno = ERRNO_AUTHFAIL;
strncmpic(q+1, US"failed", p-q-1) == 0)
*basic_errno = ERRNO_AUTHFAIL;
-else if (str
cmpic(pp, US"lost_connection"
) == 0)
+else if (str
ncmpic(pp, US"lost_connection", p - pp
) == 0)
*basic_errno = ERRNO_SMTPCLOSED;
*basic_errno = ERRNO_SMTPCLOSED;
-else if (str
cmpic(pp, US"tls_required"
) == 0)
+else if (str
ncmpic(pp, US"tls_required", p - pp
) == 0)
*basic_errno = ERRNO_TLSREQUIRED;
else if (len != 1 || Ustrncmp(pp, "*", 1) != 0)
*basic_errno = ERRNO_TLSREQUIRED;
else if (len != 1 || Ustrncmp(pp, "*", 1) != 0)