0

Catch-All Email

Pamela 9 years ago updated by Quinn 8 years ago 6
I am trying to configure a catch-all email account; however, after I configure it and try emailing it, I get
550 Unrouteable address

For the email address, I am using *@domain.com. Normal email addresses like example@domain.com work just fine. It is only the catch-all email address that is not working.

Any ideas?

Thanks.
+2
you should try Custom routers on mail section >> advanced tab
just use this for custom routers
catchall_pub: 
debug_print = "R: catch_all for $local_part@$domain" 
driver = redirect 
domains = MYDOMAIN.com 
data = EMAIL@MYOTHERDOMAIN.com
http://www.torrycrass.com/2011/05/26/debian-6-squeeze-exim4-and-catch-all/
http://positon.org/catch-all-mail-with-exim
http://www.exim.org/exim-html-current/doc/html/spec_html/ch-the_default_configuration_file.html#SECID55
Thanks a lot, Amirhossein! I spent several hours trying to figure this out, but couldn't.

Your solution works perfectly.
+1
its my honor, your welcome

Hey Amirhossein your code helped me out a lot! Thanks!


Could you just help me a little further ?


I'm hosting multiple domains and would like to redirect emails for different domains to different email addresses.

eg:

1) Invalid-email@x.com --> valid-email@x.com

2) Invalid-email@y.com --> valid-email@y.com


How can I do this ?

Thanks, works great, but is it possible to enter exceptions to the catch-all? Say I want to block anything coming to noreply@domain.com

Should have looked a bit better before posting, and appear to be unable to edit/delete my previous post.

The solution is quite easy: add

local_parts = !/etc/exim4/domain.com.blacklist

to the custom router, then create the file /exc/exim4/domain.com.blacklist and add the to blacklist addresses there, each one on a new line. e.g.

# cat /etc/exim4/domain.com.blacklist

noreply

spam

bar


Ajenti's built in text editor with a bookmark to the file makes adding blacklists items convenient.