diff options
author | Gilles Chehade <gilles@cvs.openbsd.org> | 2024-02-19 21:00:20 +0000 |
---|---|---|
committer | Gilles Chehade <gilles@cvs.openbsd.org> | 2024-02-19 21:00:20 +0000 |
commit | b10535ee69a61d962c4d62f2b0f3801141a90eb7 (patch) | |
tree | 44fe916f937f195817144a43d510ef34a70b3c8a /usr.sbin/smtpd | |
parent | f23c5bde43ffec3f8f2a14b5aa188fc8722b8105 (diff) |
no need to be as strict with table formats on various match constraints,
this prevents the reuse of T_HASH tables in T_LIST contexts when the key
column actually makes sense by itself.
diff from Philipp (philipp+openbsd [at] bureaucracy [dot] de)
Diffstat (limited to 'usr.sbin/smtpd')
-rw-r--r-- | usr.sbin/smtpd/parse.y | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/usr.sbin/smtpd/parse.y b/usr.sbin/smtpd/parse.y index a7c35364a26..b4cf1f21ddb 100644 --- a/usr.sbin/smtpd/parse.y +++ b/usr.sbin/smtpd/parse.y @@ -1,4 +1,4 @@ -/* $OpenBSD: parse.y,v 1.298 2024/02/03 15:50:00 op Exp $ */ +/* $OpenBSD: parse.y,v 1.299 2024/02/19 21:00:19 gilles Exp $ */ /* * Copyright (c) 2008 Gilles Chehade <gilles@poolp.org> @@ -778,7 +778,7 @@ HELO STRING { YYERROR; } - if (!table_check_use(t, T_DYNAMIC|T_LIST, K_SOURCE)) { + if (!table_check_use(t, T_DYNAMIC|T_LIST|T_HASH, K_SOURCE)) { yyerror("table \"%s\" may not be used for source lookups", t->t_name); YYERROR; @@ -1102,7 +1102,7 @@ negation TAG REGEX tables { YYERROR; } - if (!table_check_use(t, T_DYNAMIC|T_LIST, K_STRING|K_CREDENTIALS)) { + if (!table_check_use(t, T_DYNAMIC|T_LIST|T_HASH, K_STRING|K_CREDENTIALS)) { yyerror("table \"%s\" may not be used for auth lookups", t->t_name); YYERROR; @@ -1137,7 +1137,7 @@ negation TAG REGEX tables { YYERROR; } - if (!table_check_use(t, T_DYNAMIC|T_LIST, K_MAILADDR)) { + if (!table_check_use(t, T_DYNAMIC|T_LIST|T_HASH, K_MAILADDR)) { yyerror("table \"%s\" may not be used for mail-from lookups", t->t_name); YYERROR; @@ -1172,7 +1172,7 @@ negation TAG REGEX tables { YYERROR; } - if (!table_check_use(t, T_DYNAMIC|T_LIST, K_MAILADDR)) { + if (!table_check_use(t, T_DYNAMIC|T_LIST|T_HASH, K_MAILADDR)) { yyerror("table \"%s\" may not be used for rcpt-to lookups", t->t_name); YYERROR; @@ -1330,7 +1330,7 @@ negation TAG REGEX tables { YYERROR; } - if (!table_check_use(t, T_DYNAMIC|T_LIST, K_STRING|K_CREDENTIALS)) { + if (!table_check_use(t, T_DYNAMIC|T_LIST, K_STRING|K_CREDENTIALS)) { yyerror("table \"%s\" may not be used for from lookups", t->t_name); YYERROR; @@ -1372,7 +1372,7 @@ negation TAG REGEX tables { YYERROR; } - if (!table_check_use(t, T_DYNAMIC|T_LIST, K_MAILADDR)) { + if (!table_check_use(t, T_DYNAMIC|T_LIST|T_HASH, K_MAILADDR)) { yyerror("table \"%s\" may not be used for from lookups", t->t_name); YYERROR; @@ -1469,7 +1469,7 @@ negation TAG REGEX tables { YYERROR; } - if (!table_check_use(t, T_DYNAMIC|T_LIST, K_MAILADDR)) { + if (!table_check_use(t, T_DYNAMIC|T_LIST|T_HASH, K_MAILADDR)) { yyerror("table \"%s\" may not be used for for lookups", t->t_name); YYERROR; |