summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorJeremy Harris <jgh146exb@wizmail.org>2015-12-09 17:29:26 +0000
committerJeremy Harris <jgh146exb@wizmail.org>2015-12-09 18:34:40 +0000
commit8c5d388a6e12d1a8bd4aa565920238f8a921414a (patch)
treeae54f5d4724cccfe5a163a19bc675ce1d3be8d5a /src
parentfe59aa70558b0e9a10a7ef349f579a0c9d5bcb46 (diff)
I18N: Move EAI support from Experimental to mainlineexim-4_87_RC1
Diffstat (limited to 'src')
-rw-r--r--src/src/EDITME16
-rw-r--r--src/src/acl.c16
-rw-r--r--src/src/config.h.defaults3
-rw-r--r--src/src/deliver.c10
-rw-r--r--src/src/dns.c4
-rw-r--r--src/src/exim.c20
-rw-r--r--src/src/expand.c14
-rw-r--r--src/src/functions.h6
-rw-r--r--src/src/globals.c8
-rw-r--r--src/src/globals.h4
-rw-r--r--src/src/imap_utf7.c2
-rw-r--r--src/src/macros.h2
-rw-r--r--src/src/queue.c4
-rw-r--r--src/src/readconf.c2
-rw-r--r--src/src/receive.c4
-rw-r--r--src/src/routers/redirect.c4
-rw-r--r--src/src/smtp_in.c16
-rw-r--r--src/src/spool_in.c6
-rw-r--r--src/src/spool_out.c2
-rw-r--r--src/src/string.c8
-rw-r--r--src/src/structs.h4
-rw-r--r--src/src/tls-gnu.c2
-rw-r--r--src/src/tls-openssl.c2
-rw-r--r--src/src/transports/smtp.c20
-rw-r--r--src/src/utf8.c2
-rw-r--r--src/src/verify.c14
26 files changed, 100 insertions, 95 deletions
diff --git a/src/src/EDITME b/src/src/EDITME
index a67343b3a..de25abd5e 100644
--- a/src/src/EDITME
+++ b/src/src/EDITME
@@ -496,11 +496,6 @@ EXIM_MONITOR=eximon.bin
# Note: Enabling this unconditionally overrides DISABLE_DNSSEC
# EXPERIMENTAL_DANE=yes
-# Uncomment the following to add Internationalisation features. You need to
-# have the IDN library installed.
-# EXPERIMENTAL_INTERNATIONAL=yes
-# LDFLAGS += -lidn
-
###############################################################################
# THESE ARE THINGS YOU MIGHT WANT TO SPECIFY #
###############################################################################
@@ -931,6 +926,17 @@ ZCAT_COMMAND=/usr/bin/zcat
# SUPPORT_PROXY=yes
+#------------------------------------------------------------------------------
+# Internationalisation.
+#
+# Uncomment the following to include Internationalisation features. This is the
+# SMTPUTF8 ESMTP extension, and associated facilities for handling UTF8 domain
+# and localparts, per RFCs 5890, 6530 and 6533.
+# You need to have the IDN library installed.
+
+# SUPPORT_I18N=yes
+# LDFLAGS += -lidn
+
#------------------------------------------------------------------------------
# Support for authentication via Radius is also available. The Exim support,
diff --git a/src/src/acl.c b/src/src/acl.c
index 911ecfed2..f310a87d3 100644
--- a/src/src/acl.c
+++ b/src/src/acl.c
@@ -208,7 +208,7 @@ enum {
#endif
CONTROL_FAKEDEFER,
CONTROL_FAKEREJECT,
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
CONTROL_UTF8_DOWNCONVERT,
#endif
CONTROL_NO_MULTILINE,
@@ -251,7 +251,7 @@ static uschar *controls[] = {
#endif
US"fakedefer",
US"fakereject",
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
US"utf8_downconvert",
#endif
US"no_multiline_responses",
@@ -693,7 +693,7 @@ static unsigned int control_forbids[] = {
#endif
(1<<ACL_WHERE_MIME)),
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
0, /* utf8_downconvert */
#endif
@@ -750,7 +750,7 @@ static control_def controls_list[] = {
{ US"submission", CONTROL_SUBMISSION, TRUE },
{ US"suppress_local_fixups", CONTROL_SUPPRESS_LOCAL_FIXUPS, FALSE },
{ US"cutthrough_delivery", CONTROL_CUTTHROUGH_DELIVERY, FALSE },
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
{ US"utf8_downconvert", CONTROL_UTF8_DOWNCONVERT, TRUE }
#endif
};
@@ -2095,7 +2095,7 @@ else if (verify_sender_address != NULL)
uschar *save_address_data = deliver_address_data;
sender_vaddr = deliver_make_addr(verify_sender_address, TRUE);
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
if ((sender_vaddr->prop.utf8_msg = message_smtputf8))
{
sender_vaddr->prop.utf8_downcvt = message_utf8_downconvert == 1;
@@ -3402,7 +3402,7 @@ for (; cb != NULL; cb = cb->next)
}
return ERROR;
- #ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
case CONTROL_UTF8_DOWNCONVERT:
if (*p == '/')
{
@@ -3440,7 +3440,7 @@ for (; cb != NULL; cb = cb->next)
break;
}
return ERROR;
- #endif
+#endif
}
break;
@@ -4465,7 +4465,7 @@ if (where == ACL_WHERE_RCPT)
*log_msgptr = US"defer in percent_hack_domains check";
return DEFER;
}
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
if ((addr->prop.utf8_msg = message_smtputf8))
{
addr->prop.utf8_downcvt = message_utf8_downconvert == 1;
diff --git a/src/src/config.h.defaults b/src/src/config.h.defaults
index 6e2c22063..37f47dccf 100644
--- a/src/src/config.h.defaults
+++ b/src/src/config.h.defaults
@@ -131,8 +131,8 @@ it's a default value. */
#define SPOOL_MODE 0640
#define STRING_SPRINTF_BUFFER_SIZE (8192 * 4)
-#define SUPPORT_A6
#define SUPPORT_CRYPTEQ
+#define SUPPORT_I18N
#define SUPPORT_MAILDIR
#define SUPPORT_MAILSTORE
#define SUPPORT_MBX
@@ -177,7 +177,6 @@ it's a default value. */
#define EXPERIMENTAL_DSN_INFO
#define EXPERIMENTAL_DMARC
#define EXPERIMENTAL_EVENT
-#define EXPERIMENTAL_INTERNATIONAL
#define EXPERIMENTAL_REDIS
#define EXPERIMENTAL_SPF
#define EXPERIMENTAL_SRS
diff --git a/src/src/deliver.c b/src/src/deliver.c
index 53712b269..b816b1a77 100644
--- a/src/src/deliver.c
+++ b/src/src/deliver.c
@@ -872,7 +872,7 @@ else
if (LOGGING(sender_on_delivery) || msg)
s = string_append(s, &size, &ptr, 3, US" F=<",
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
testflag(addr, af_utf8_downcvt)
? string_address_utf8_to_alabel(sender_address, NULL)
:
@@ -5771,7 +5771,7 @@ if (process_recipients != RECIP_IGNORE)
recipient_item *r = recipients_list + i;
address_item *new = deliver_make_addr(r->address, FALSE);
new->prop.errors_address = r->errors_to;
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
if ((new->prop.utf8_msg = message_smtputf8))
{
new->prop.utf8_downcvt = message_utf8_downconvert == 1;
@@ -7327,7 +7327,7 @@ wording. */
}
/* output machine readable part */
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
if (message_smtputf8)
fprintf(f, "--%s\n"
"Content-type: message/global-delivery-status\n\n"
@@ -7428,7 +7428,7 @@ wording. */
}
}
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
if (message_smtputf8)
fputs(topt & topt_no_body ? "Content-type: message/global-headers\n\n"
: "Content-type: message/global\n\n",
@@ -8074,7 +8074,7 @@ if (!regex_PRDR) regex_PRDR =
regex_must_compile(US"\\n250[\\s\\-]PRDR(\\s|\\n|$)", FALSE, TRUE);
#endif
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
if (!regex_UTF8) regex_UTF8 =
regex_must_compile(US"\\n250[\\s\\-]SMTPUTF8(\\s|\\n|$)", FALSE, TRUE);
#endif
diff --git a/src/src/dns.c b/src/src/dns.c
index 9859e8365..02eef25a6 100644
--- a/src/src/dns.c
+++ b/src/src/dns.c
@@ -620,7 +620,7 @@ if (previous != NULL)
return previous->data.val;
}
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
/* Convert all names to a-label form before doing lookup */
{
uschar * alabel;
@@ -851,7 +851,7 @@ for (i = 0; i < 10; i++)
if ( rr_name
&& Ustrcmp(rr_name, *fully_qualified_name) != 0
&& rr_name[0] != '*'
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
&& ( !string_is_utf8(*fully_qualified_name)
|| Ustrcmp(rr_name,
string_domain_utf8_to_alabel(*fully_qualified_name, NULL)) != 0
diff --git a/src/src/exim.c b/src/src/exim.c
index 4e90ca8fd..0fd95dd0c 100644
--- a/src/src/exim.c
+++ b/src/src/exim.c
@@ -823,6 +823,9 @@ fprintf(f, "Support for:");
#ifndef DISABLE_DNSSEC
fprintf(f, " DNSSEC");
#endif
+#ifdef SUPPORT_I18N
+ fprintf(f, " I18N");
+#endif
#ifndef DISABLE_OCSP
fprintf(f, " OCSP");
#endif
@@ -856,9 +859,6 @@ fprintf(f, "Support for:");
#ifdef EXPERIMENTAL_DSN_INFO
fprintf(f, " Experimental_DSN_info");
#endif
-#ifdef EXPERIMENTAL_INTERNATIONAL
- fprintf(f, " Experimental_International");
-#endif
#ifdef EXPERIMENTAL_EVENT
fprintf(f, " Experimental_Event");
#endif
@@ -1031,7 +1031,7 @@ DEBUG(D_any) do {
#ifdef SUPPORT_TLS
tls_version_report(f);
#endif
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
utf8_version_report(f);
#endif
@@ -2561,12 +2561,12 @@ for (i = 1; i < argc; i++)
if (temp >= argrest && *temp == '.') f_end_dot = TRUE;
allow_domain_literals = TRUE;
strip_trailing_dot = TRUE;
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
allow_utf8_domains = TRUE;
#endif
sender_address = parse_extract_address(argrest, &errmess,
&dummy_start, &dummy_end, &sender_address_domain, TRUE);
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
message_smtputf8 = string_is_utf8(sender_address);
allow_utf8_domains = FALSE;
#endif
@@ -3736,7 +3736,7 @@ is equivalent to the ability to modify a setuid binary!
This needs to happen before we read the main configuration. */
init_lookup_list();
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
if (running_in_test_harness) smtputf8_advertise_hosts = NULL;
#endif
@@ -5121,7 +5121,7 @@ if (mua_wrapper)
deliver_drop_privilege = TRUE;
queue_smtp = FALSE;
queue_smtp_domains = NULL;
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
message_utf8_downconvert = -1; /* convert-if-needed */
#endif
}
@@ -5414,7 +5414,7 @@ while (more)
errors_sender_rc : EXIT_FAILURE;
}
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
{
BOOL b = allow_utf8_domains;
allow_utf8_domains = TRUE;
@@ -5422,7 +5422,7 @@ while (more)
recipient =
parse_extract_address(s, &errmess, &start, &end, &domain, FALSE);
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
if (string_is_utf8(recipient))
message_smtputf8 = TRUE;
else
diff --git a/src/src/expand.c b/src/src/expand.c
index a5f14364c..55b3d8c29 100644
--- a/src/src/expand.c
+++ b/src/src/expand.c
@@ -111,7 +111,7 @@ static uschar *item_table[] = {
US"hash",
US"hmac",
US"if",
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
US"imapfolder",
#endif
US"length",
@@ -141,7 +141,7 @@ enum {
EITEM_HASH,
EITEM_HMAC,
EITEM_IF,
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
EITEM_IMAPFOLDER,
#endif
EITEM_LENGTH,
@@ -173,7 +173,7 @@ static uschar *op_table_underscore[] = {
US"reverse_ip",
US"time_eval",
US"time_interval"
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
,US"utf8_domain_from_alabel",
US"utf8_domain_to_alabel",
US"utf8_localpart_from_alabel",
@@ -188,7 +188,7 @@ enum {
EOP_REVERSE_IP,
EOP_TIME_EVAL,
EOP_TIME_INTERVAL
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
,EOP_UTF8_DOMAIN_FROM_ALABEL,
EOP_UTF8_DOMAIN_TO_ALABEL,
EOP_UTF8_LOCALPART_FROM_ALABEL,
@@ -573,7 +573,7 @@ static var_entry var_table[] = {
{ "message_id", vtype_stringptr, &message_id },
{ "message_linecount", vtype_int, &message_linecount },
{ "message_size", vtype_int, &message_size },
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
{ "message_smtputf8", vtype_bool, &message_smtputf8 },
#endif
#ifdef WITH_CONTENT_SCAN
@@ -4095,7 +4095,7 @@ while (*s != 0)
continue;
}
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
case EITEM_IMAPFOLDER:
{ /* ${imapfolder {name}{sep]{specials}} */
uschar *sub_arg[3];
@@ -6757,7 +6757,7 @@ while (*s != 0)
continue;
}
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
case EOP_UTF8_DOMAIN_TO_ALABEL:
{
uschar * error = NULL;
diff --git a/src/src/functions.h b/src/src/functions.h
index e9f7ab658..edc72bc0d 100644
--- a/src/src/functions.h
+++ b/src/src/functions.h
@@ -424,7 +424,7 @@ extern BOOL string_format(uschar *, int, const char *, ...) ALMOST_PRINTF(3,4
extern uschar *string_format_size(int, uschar *);
extern int string_interpret_escape(const uschar **);
extern int string_is_ip_address(const uschar *, int *);
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
extern BOOL string_is_utf8(const uschar *);
#endif
extern uschar *string_log_address(address_item *, BOOL, BOOL);
@@ -433,7 +433,7 @@ extern uschar *string_open_failed(int, const char *, ...) PRINTF_FUNCTION(2,3);
extern const uschar *string_printing2(const uschar *, BOOL);
extern uschar *string_split_message(uschar *);
extern uschar *string_unprinting(uschar *);
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
extern uschar *string_address_utf8_to_alabel(const uschar *, uschar **);
extern uschar *string_domain_alabel_to_utf8(const uschar *, uschar **);
extern uschar *string_domain_utf8_to_alabel(const uschar *, uschar **);
@@ -474,7 +474,7 @@ extern void tree_walk(tree_node *, void (*)(uschar*, uschar*, void*), void *)
#ifdef WITH_CONTENT_SCAN
extern void unspool_mbox(void);
#endif
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
extern void utf8_version_report(FILE *);
#endif
diff --git a/src/src/globals.c b/src/src/globals.c
index 6bd33a1a5..9ecb59652 100644
--- a/src/src/globals.c
+++ b/src/src/globals.c
@@ -178,7 +178,7 @@ BOOL prdr_requested = FALSE;
const pcre *regex_PRDR = NULL;
#endif
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
const pcre *regex_UTF8 = NULL;
#endif
@@ -395,7 +395,7 @@ address_item address_defaults = {
#ifdef EXPERIMENTAL_SRS
NULL, /* srs_sender */
#endif
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
FALSE, /* utf8 */
#endif
}
@@ -943,7 +943,7 @@ int message_linecount = 0;
BOOL message_logs = TRUE;
int message_size = 0;
uschar *message_size_limit = US"50M";
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
BOOL message_smtputf8 = FALSE;
int message_utf8_downconvert = 0; /* -1 ifneeded; 0 never; 1 always */
#endif
@@ -1316,7 +1316,7 @@ int smtp_rlr_limit = 0;
int smtp_rlr_threshold = INT_MAX;
BOOL smtp_use_pipelining = FALSE;
BOOL smtp_use_size = FALSE;
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
uschar *smtputf8_advertise_hosts = US"*"; /* overridden under test-harness */
#endif
diff --git a/src/src/globals.h b/src/src/globals.h
index 899471116..c969214c8 100644
--- a/src/src/globals.h
+++ b/src/src/globals.h
@@ -576,7 +576,7 @@ extern int message_linecount; /* As it says */
extern BOOL message_logs; /* TRUE to write message logs */
extern int message_size; /* Size of message */
extern uschar *message_size_limit; /* As it says */
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
extern BOOL message_smtputf8; /* Internationalized mail handling */
extern int message_utf8_downconvert; /* convert from utf8 */
const extern pcre *regex_UTF8; /* For recognizing SMTPUTF8 settings */
@@ -836,7 +836,7 @@ extern int smtp_rlr_limit; /* Max delay */
extern int smtp_rlr_threshold; /* Threshold for RCPT rate limit */
extern BOOL smtp_use_pipelining; /* Global for passed connections */
extern BOOL smtp_use_size; /* Global for passed connections */
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
extern uschar *smtputf8_advertise_hosts; /* ingress control */
#endif
diff --git a/src/src/imap_utf7.c b/src/src/imap_utf7.c
index 739e47f41..dcccaeef8 100644
--- a/src/src/imap_utf7.c
+++ b/src/src/imap_utf7.c
@@ -1,6 +1,6 @@
#include "exim.h"
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
uschar *
imap_utf7_encode(uschar *string, const uschar *charset, uschar sep,
diff --git a/src/src/macros.h b/src/src/macros.h
index 1cec4abd5..66abffa37 100644
--- a/src/src/macros.h
+++ b/src/src/macros.h
@@ -533,7 +533,7 @@ to conflict with system errno values. */
#define ERRNO_PROXYFAIL (-47) /* Negotiation failed for proxy configured host */
#define ERRNO_AUTHPROB (-48) /* Authenticator "other" failure */
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
# define ERRNO_UTF8_FWD (-49) /* target not supporting SMTPUTF8 */
#endif
diff --git a/src/src/queue.c b/src/src/queue.c
index dc1c320c7..bf62aea88 100644
--- a/src/src/queue.c
+++ b/src/src/queue.c
@@ -1274,7 +1274,7 @@ switch(action)
{
if (action == MSG_ADD_RECIPIENT)
{
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
if (string_is_utf8(recipient)) allow_utf8_domains = message_smtputf8 = TRUE;
#endif
receive_add_recipient(recipient, -1);
@@ -1300,7 +1300,7 @@ switch(action)
}
else /* MSG_EDIT_SENDER */
{
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
if (string_is_utf8(recipient)) allow_utf8_domains = message_smtputf8 = TRUE;
#endif
sender_address = recipient;
diff --git a/src/src/readconf.c b/src/src/readconf.c
index 9b0b26e42..30ff757ac 100644
--- a/src/src/readconf.c
+++ b/src/src/readconf.c
@@ -413,7 +413,7 @@ static optionlist optionlist_config[] = {
{ "smtp_receive_timeout", opt_func, &fn_smtp_receive_timeout },
{ "smtp_reserve_hosts", opt_stringptr, &smtp_reserve_hosts },
{ "smtp_return_error_details",opt_bool, &smtp_return_error_details },
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
{ "smtputf8_advertise_hosts", opt_stringptr, &smtputf8_advertise_hosts },
#endif
#ifdef WITH_CONTENT_SCAN
diff --git a/src/src/receive.c b/src/src/receive.c
index dc228d921..585cb9025 100644
--- a/src/src/receive.c
+++ b/src/src/receive.c
@@ -2303,7 +2303,7 @@ if (extract_recip)
for (p = s; p < ss; p++) if (*p != '\n') *pp++ = *p;
*pp = 0;
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
{
BOOL b = allow_utf8_domains;
allow_utf8_domains = TRUE;
@@ -2311,7 +2311,7 @@ if (extract_recip)
recipient = parse_extract_address(recipient, &errmess, &start, &end,
&domain, FALSE);
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
if (string_is_utf8(recipient))
message_smtputf8 = TRUE;
else
diff --git a/src/src/routers/redirect.c b/src/src/routers/redirect.c
index 371377317..7bbaa82e4 100644
--- a/src/src/routers/redirect.c
+++ b/src/src/routers/redirect.c
@@ -451,7 +451,7 @@ while (generated != NULL)
}
}
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
next->prop.utf8_msg = string_is_utf8(next->address)
|| (sender_address && string_is_utf8(sender_address));
#endif
@@ -475,7 +475,7 @@ while (generated != NULL)
else
debug_printf("gid=unset ");
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
if (next->prop.utf8_msg) debug_printf("utf8 ");
#endif
diff --git a/src/src/smtp_in.c b/src/src/smtp_in.c
index 86b0d21cf..3fce125d3 100644
--- a/src/src/smtp_in.c
+++ b/src/src/smtp_in.c
@@ -135,7 +135,7 @@ static BOOL rcpt_smtp_response_same;
static BOOL rcpt_in_progress;
static int nonmail_command_count;
static BOOL smtp_exit_function_called = 0;
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
static BOOL smtputf8_advertised;
#endif
static int synprot_error_count;
@@ -239,7 +239,7 @@ enum {
ENV_MAIL_OPT_PRDR,
#endif
ENV_MAIL_OPT_RET, ENV_MAIL_OPT_ENVID,
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
ENV_MAIL_OPT_UTF8,
#endif
};
@@ -258,7 +258,7 @@ static env_mail_type_t env_mail_type_list[] = {
#endif
{ US"RET", ENV_MAIL_OPT_RET, TRUE },
{ US"ENVID", ENV_MAIL_OPT_ENVID, TRUE },
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
{ US"SMTPUTF8",ENV_MAIL_OPT_UTF8, FALSE }, /* rfc6531 */
#endif
/* keep this the last entry */
@@ -1544,7 +1544,7 @@ spf_received = NULL;
spf_result = NULL;
spf_smtp_comment = NULL;
#endif
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
message_smtputf8 = FALSE;
#endif
body_linecount = body_zerocount = 0;
@@ -1882,7 +1882,7 @@ tls_in.ocsp = OCSP_NOT_REQ;
tls_advertised = FALSE;
#endif
dsn_advertised = FALSE;
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
smtputf8_advertised = FALSE;
#endif
@@ -3577,7 +3577,7 @@ while (done <= 0)
tls_advertised = FALSE;
#endif
dsn_advertised = FALSE;
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
smtputf8_advertised = FALSE;
#endif
@@ -3771,7 +3771,7 @@ while (done <= 0)
}
#endif
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
if ( accept_8bitmime
&& verify_check_host(&smtputf8_advertise_hosts) != FAIL)
{
@@ -4054,7 +4054,7 @@ while (done <= 0)
break;
#endif
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
case ENV_MAIL_OPT_UTF8:
if (smtputf8_advertised)
{
diff --git a/src/src/spool_in.c b/src/src/spool_in.c
index a7095bbaa..59192ef30 100644
--- a/src/src/spool_in.c
+++ b/src/src/spool_in.c
@@ -303,7 +303,7 @@ spam_score = NULL;
spam_score_int = NULL;
#endif
-#if defined(EXPERIMENTAL_INTERNATIONAL) && !defined(COMPILE_UTILITY)
+#if defined(SUPPORT_I18N) && !defined(COMPILE_UTILITY)
message_smtputf8 = FALSE;
message_utf8_downconvert = 0;
#endif
@@ -582,7 +582,7 @@ for (;;)
else if (Ustrncmp(p, "pam_score_int ", 14) == 0)
spam_score_int = string_copy(big_buffer + 16);
#endif
-#if defined(EXPERIMENTAL_INTERNATIONAL) && !defined(COMPILE_UTILITY)
+#if defined(SUPPORT_I18N) && !defined(COMPILE_UTILITY)
else if (Ustrncmp(p, "mtputf8", 7) == 0)
message_smtputf8 = TRUE;
#endif
@@ -609,7 +609,7 @@ for (;;)
break;
#endif
-#if defined(EXPERIMENTAL_INTERNATIONAL) && !defined(COMPILE_UTILITY)
+#if defined(SUPPORT_I18N) && !defined(COMPILE_UTILITY)
case 'u':
if (Ustrncmp(p, "tf8_downcvt", 11) == 0)
message_utf8_downconvert = 1;
diff --git a/src/src/spool_out.c b/src/src/spool_out.c
index e7a6a6535..8d0ee7c71 100644
--- a/src/src/spool_out.c
+++ b/src/src/spool_out.c
@@ -247,7 +247,7 @@ if (tls_in.ourcert)
if (tls_in.ocsp) fprintf(f, "-tls_ocsp %d\n", tls_in.ocsp);
#endif
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
if (message_smtputf8)
{
fprintf(f, "-smtputf8\n");
diff --git a/src/src/string.c b/src/src/string.c
index b76b0abbc..d01383f65 100644
--- a/src/src/string.c
+++ b/src/src/string.c
@@ -1553,7 +1553,7 @@ uschar * s;
s = addr->prefix;
if (testflag(addr, af_include_affixes) && s)
{
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
if (testflag(addr, af_utf8_downcvt))
s = string_localpart_utf8_to_alabel(s, NULL);
#endif
@@ -1561,7 +1561,7 @@ if (testflag(addr, af_include_affixes) && s)
}
s = addr->local_part;
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
if (testflag(addr, af_utf8_downcvt))
s = string_localpart_utf8_to_alabel(s, NULL);
#endif
@@ -1570,7 +1570,7 @@ yield = string_cat(yield, sizeptr, ptrptr, s, Ustrlen(s));
s = addr->suffix;
if (testflag(addr, af_include_affixes) && s)
{
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
if (testflag(addr, af_utf8_downcvt))
s = string_localpart_utf8_to_alabel(s, NULL);
#endif
@@ -1641,7 +1641,7 @@ else
yield = string_get_localpart(addr, yield, &size, &ptr);
yield = string_cat(yield, &size, &ptr, US"@", 1);
s = addr->domain;
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
if (testflag(addr, af_utf8_downcvt))
s = string_localpart_utf8_to_alabel(s, NULL);
#endif
diff --git a/src/src/structs.h b/src/src/structs.h
index 713702ea5..5fe8551cd 100644
--- a/src/src/structs.h
+++ b/src/src/structs.h
@@ -467,7 +467,7 @@ typedef struct address_item_propagated {
#ifdef EXPERIMENTAL_SRS
uschar *srs_sender; /* Change return path when delivering */
#endif
- #ifdef EXPERIMENTAL_INTERNATIONAL
+ #ifdef SUPPORT_I18N
BOOL utf8_msg:1; /* requires SMTPUTF8 processing */
BOOL utf8_downcvt:1; /* mandatory downconvert on delivery */
BOOL utf8_downcvt_maybe:1; /* optional downconvert on delivery */
@@ -510,7 +510,7 @@ typedef struct address_item_propagated {
#ifdef EXPERIMENTAL_DANE
# define af_dane_verified 0x20000000 /* TLS cert verify done with DANE */
#endif
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
# define af_utf8_downcvt 0x40000000 /* downconvert was done for delivery */
#endif
diff --git a/src/src/tls-gnu.c b/src/src/tls-gnu.c
index c316d0a24..c2f073833 100644
--- a/src/src/tls-gnu.c
+++ b/src/src/tls-gnu.c
@@ -1834,7 +1834,7 @@ tls_client_setup_hostname_checks(host_item * host, exim_gnutls_state_st * state,
if (verify_check_given_host(&ob->tls_verify_cert_hostnames, host) == OK)
{
state->exp_tls_verify_cert_hostnames =
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
string_domain_utf8_to_alabel(host->name, NULL);
#else
host->name;
diff --git a/src/src/tls-openssl.c b/src/src/tls-openssl.c
index c68b25d83..704522b50 100644
--- a/src/src/tls-openssl.c
+++ b/src/src/tls-openssl.c
@@ -1860,7 +1860,7 @@ if ((rc = setup_certs(ctx, ob->tls_verify_certificates,
if (verify_check_given_host(&ob->tls_verify_cert_hostnames, host) == OK)
{
cbinfo->verify_cert_hostnames =
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
string_domain_utf8_to_alabel(host->name, NULL);
#else
host->name;
diff --git a/src/src/transports/smtp.c b/src/src/transports/smtp.c
index 30facda00..c53ae2386 100644
--- a/src/src/transports/smtp.c
+++ b/src/src/transports/smtp.c
@@ -596,7 +596,7 @@ if (*errno_value == ERRNO_WRITEINCOMPLETE)
return FALSE;
}
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
/* Handle lack of advertised SMTPUTF8, for international message */
if (*errno_value == ERRNO_UTF8_FWD)
{
@@ -1403,7 +1403,7 @@ BOOL pass_message = FALSE;
BOOL prdr_offered = FALSE;
BOOL prdr_active;
#endif
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
BOOL utf8_needed = FALSE;
BOOL utf8_offered = FALSE;
#endif
@@ -1535,7 +1535,7 @@ if (continue_hostname == NULL)
delayed till here so that $sending_interface and $sending_port are set. */
helo_data = expand_string(ob->helo_data);
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
if (helo_data)
{
uschar * errstr = NULL;
@@ -1709,7 +1709,7 @@ goto SEND_QUIT;
{DEBUG(D_transport) debug_printf("PRDR usable\n");}
#endif
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
if (addrlist->prop.utf8_msg)
{
utf8_needed = !addrlist->prop.utf8_downcvt
@@ -1950,7 +1950,7 @@ if (continue_hostname == NULL
{DEBUG(D_transport) debug_printf("PRDR usable\n");}
#endif
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
if (addrlist->prop.utf8_msg)
utf8_offered = esmtp
&& pcre_exec(regex_UTF8, NULL, CS buffer, Ustrlen(buffer), 0,
@@ -1983,7 +1983,7 @@ message-specific. */
setting_up = FALSE;
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
/* If this is an international message we need the host to speak SMTPUTF8 */
if (utf8_needed && !utf8_offered)
{
@@ -2068,7 +2068,7 @@ if (prdr_offered)
}
#endif
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
if (addrlist->prop.utf8_msg && !addrlist->prop.utf8_downcvt && utf8_offered)
sprintf(CS p, " SMTPUTF8"), p += 9;
#endif
@@ -2128,7 +2128,7 @@ pending_MAIL = TRUE; /* The block starts with MAIL */
{
uschar * s = return_path;
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
uschar * errstr = NULL;
/* If we must downconvert, do the from-address here. Remember we had to
@@ -2239,7 +2239,7 @@ for (addr = first_addr;
rcpt_addr = transport_rcpt_address(addr, tblock->rcpt_include_affixes);
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
{
uschar * dummy_errstr;
if ( testflag(addrlist, af_utf8_downcvt)
@@ -2679,7 +2679,7 @@ if (!ok)
switch(save_errno)
{
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
case ERRNO_UTF8_FWD:
code = '5';
/*FALLTHROUGH*/
diff --git a/src/src/utf8.c b/src/src/utf8.c
index 8a7cf38a3..84ad1dc18 100644
--- a/src/src/utf8.c
+++ b/src/src/utf8.c
@@ -8,7 +8,7 @@
#include "exim.h"
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
#include <idna.h>
#include <punycode.h>
diff --git a/src/src/verify.c b/src/src/verify.c
index 6c228abbf..17c99d174 100644
--- a/src/src/verify.c
+++ b/src/src/verify.c
@@ -174,7 +174,7 @@ dbdata_callout_cache new_domain_record;
dbdata_callout_cache_address new_address_record;
host_item *host;
time_t callout_start_time;
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
BOOL utf8_offered = FALSE;
#endif
@@ -924,7 +924,7 @@ can do it there for the non-rcpt-verify case. For this we keep an addresscount.
}
}
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
else if ( addr->prop.utf8_msg
&& !addr->prop.utf8_downcvt
&& !( esmtp
@@ -976,7 +976,7 @@ can do it there for the non-rcpt-verify case. For this we keep an addresscount.
/* Send the MAIL command */
(smtp_write_command(&outblock, FALSE,
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
addr->prop.utf8_msg && !addr->prop.utf8_downcvt
? "MAIL FROM:<%s>%s SMTPUTF8\r\n"
:
@@ -1022,7 +1022,7 @@ can do it there for the non-rcpt-verify case. For this we keep an addresscount.
{
const uschar * rcpt_domain = addr->domain;
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
uschar * errstr = NULL;
if ( testflag(addr, af_utf8_downcvt)
&& (rcpt_domain = string_domain_utf8_to_alabel(rcpt_domain,
@@ -1084,7 +1084,7 @@ can do it there for the non-rcpt-verify case. For this we keep an addresscount.
'2', callout) &&
smtp_write_command(&outblock, FALSE,
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
addr->prop.utf8_msg && !addr->prop.utf8_downcvt
? "MAIL FROM:<%s> SMTPUTF8\r\n"
:
@@ -1124,7 +1124,7 @@ can do it there for the non-rcpt-verify case. For this we keep an addresscount.
uschar * rcpt = transport_rcpt_address(addr,
addr->transport ? addr->transport->rcpt_include_affixes : FALSE);
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
/*XXX should the conversion be moved into transport_rcpt_address() ? */
uschar * dummy_errstr = NULL;
if ( testflag(addr, af_utf8_downcvt)
@@ -1229,7 +1229,7 @@ can do it there for the non-rcpt-verify case. For this we keep an addresscount.
HDEBUG(D_verify) debug_printf("SMTP timeout\n");
send_quit = FALSE;
}
-#ifdef EXPERIMENTAL_INTERNATIONAL
+#ifdef SUPPORT_I18N
else if (errno == ERRNO_UTF8_FWD)
{
extern int acl_where; /* src/acl.c */