Hello,

I have some users with some convoluted cyclical forwarding.

I get this debug line: mysql_alias router skipped: previously routed user@domain

The issue is that there is a catchall router below, which assumes that all 
valid addresses were already routed. This case violates this assumption. If the 
condition is met (catchall behavior is enabled for the domain), the catchall 
recipient is generated, which isn't intended.

The solution I came up with so far is to add this below the mysql_alias router:

mysql_alias_loop:
  debug_print = "R: mysql_alias_loop for $local_part@$domain"
  driver = redirect
  domains = +virtual_domains
  condition = ${lookup mysql{SELECT 1 FROM alias WHERE 
localpart='${quote_mysql:$local_part}' AND domain='${quote_mysql:$domain}' AND 
active}}
  data = :blackhole:

If the recipient is an alias, and the mysql_alias router was skipped, this 
kicks in. This seems to work.

Has anyone handled something like this? I wonder if there is a better way to do 
this.



-- 
## subscription configuration (requires account):
##   https://lists.exim.org/mailman3/postorius/lists/exim-users.lists.exim.org/
## unsubscribe (doesn't require an account):
##   [email protected]
## Exim details at http://www.exim.org/
## Please use the Wiki with this list - http://wiki.exim.org/

Reply via email to