From 2f858c2cfb64bd71c4a50005b46c752c4e7ddfcb Mon Sep 17 00:00:00 2001 From: "Alan T. DeKok" Date: Sat, 2 Jul 2022 08:20:47 -0400 Subject: [PATCH] fix parsing of &Outer-Realm-Name, with terminating characters It should not be &Outer - Realm-Name even if "-" is a terminating character. The correct answer is "don't have ambiguous grammars", but it's very difficult to fix that now --- src/lib/server/tmpl_tokenize.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/lib/server/tmpl_tokenize.c b/src/lib/server/tmpl_tokenize.c index 9fc6fec9dcd..9e9156d3de1 100644 --- a/src/lib/server/tmpl_tokenize.c +++ b/src/lib/server/tmpl_tokenize.c @@ -630,7 +630,7 @@ static fr_slen_t tmpl_request_ref_list_from_substr(TALLOC_CTX *ctx, tmpl_attr_er * We don't want to misidentify the list * as being part of an attribute. */ - if (!fr_sbuff_is_char(&our_in, '.') && !tmpl_substr_terminal_check(&our_in, p_rules)) { + if (!fr_sbuff_is_char(&our_in, '.') && (fr_sbuff_is_in_charset(&our_in, fr_dict_attr_allowed_chars) || !tmpl_substr_terminal_check(&our_in, p_rules))) { goto default_ref; } -- 2.47.3