From 276a46811555b0b2f8a12eab27aa28597b6f3f44 Mon Sep 17 00:00:00 2001 From: Timo Sirainen Date: Tue, 4 Mar 2025 16:36:26 +0200 Subject: [PATCH] config: Fail if local_name contains spaces It's no longer a supported way to configure multiple matches. --- src/config/config-parser.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/config/config-parser.c b/src/config/config-parser.c index c83ef89d57..e1d3d13798 100644 --- a/src/config/config-parser.c +++ b/src/config/config-parser.c @@ -1233,7 +1233,9 @@ int config_filter_parse(struct config_filter *filter, pool_t pool, else filter->local_host = p_strdup(pool, value); } else if (strcmp(key, "local_name") == 0) { - if (parent->remote_bits > 0) + if (strchr(value, ' ') != NULL) + *error_r = "Multiple names no longer supported in local_name value"; + else if (parent->remote_bits > 0) *error_r = "remote { local_name { .. } } not allowed (use local_name { remote { .. } } instead)"; else if (parent->protocol != NULL) *error_r = "protocol { local_name { .. } } not allowed (use local_name { protocol { .. } } instead)"; -- 2.47.3