I've configured my new exim4 setup to allow local users to accept email
sent to aliases that contain their username followed by an underscore and
then any suffix they'd like. Setting this up was easy with a simple
redirect router.
I'd like the Envelope-to: header to match whatever was given with 'rcpt
to', but I always end up with just the username in the Envelope-To field.
I'm at a little bit of a loss as to why it's different & would appreciate
any suggestions as to how to make them match.
I only have one rewrite rule:
root@??? "root@??? (root@$primary_hostname)" hFwq
A simple test smtp session looks like this:
$ telnet alpha.geneseo.edu 25
Trying 137.238.1.190...
Connected to <exim_server>.
Escape character is '^]'.
220 alpha.geneseo.edu ESMTP Exim 4.34 Tue, 06 Jul 2004 09:10:35 -0500
helo valites.net
250 alpha.geneseo.edu Hello valites.net [137.238.1.100]
mail from: valites@???
250 OK
rcpt to: valites_thing@???
250 Accepted
data
354 Enter message, ending with "." on a line by itself
From: valites@???
To: valites_thing@???
And the headers from the email it generated look like this:
Envelope-to: valites@???
Delivery-date: Tue, 06 Jul 2004 09:11:19 -0500
Received: from exim by alpha.geneseo.edu with spam-scanned (Exim 4.34)
id 1BhqfG-0001NN-Ri
for valites@???; Tue, 06 Jul 2004 09:11:19 -0500
Received: from [137.238.1.100] (helo=valites.net)
by alpha.geneseo.edu with smtp (Exim 4.34)
id 1Bhqer-0001Kr-HV
for valites_thing@???; Tue, 06 Jul 2004 09:11:18 -0500
My routers:
list_aliases:
debug_print = "R: list aliases for $local_part@$domain"
driver = redirect
check_local_user
domains = +local_domains
require_files = $home/.extensions
local_part_suffix = _*
data = $local_part
rewrite = false # this setting makes no difference
local_user:
debug_print = "R: local_user for $local_part@$domain"
driver = accept
domains = +local_domains
check_local_user
local_parts = ! root
transport = maildir_home
Matching Transport:
maildir_home:
debug_print = "T: maildir_home for $local_part@$domain"
driver = appendfile
directory = $home/Maildir
create_directory
delivery_date_add
envelope_to_add
return_path_add
maildir_format
maildir_tag = ,S=$message_size
mode = 0600
mode_fail_narrower = false
--
Mark T. Valites
Unix Systems Analyst
Computing & Information Technology
SUNY Geneseo
>--))> >--))>