Dear collegues,
we moved some internal domains from "olddomain.org" to "newdomain.org"
we have internal routing for the new and old domain
Now we want to get rid of the routing for "olddomain.org"
and I want to rewrite "olddomain.org" to "newdomain.org"
so "foo@sub.olddomain.org" should become "foo@sub.newdomain.org"
In my rewrite section of exim I use
^(.*)@(.*)\.olddomain\.org $1@$2.newdomain.org TS
which seems to run fine:
# exim -brw foo@sub.olddomain.org
2022-08-09 16:18:28 "foo@sub.olddomain.org" from smtp sender rewritten as "foo@sub.newdomain.org" by rule 1
SMTP: foo@sub.newdomain.org
sender: foo@sub.olddomain.org
from: foo@sub.olddomain.org
to: foo@sub.olddomain.org
cc: foo@sub.olddomain.org
bcc: foo@sub.olddomain.org
reply-to: foo@sub.olddomain.org
env-from: foo@sub.olddomain.org
2022-08-09 16:18:28 "foo@sub.olddomain.org" from env-to rewritten as "foo@sub.newdomain.org" by rule 1
env-to: foo@sub.newdomain.org
However, when I activate this, I see the following in my logs:
2022-08-09 15:59:22 Rewrite of <foo@sub.olddomain.org> yielded unparseable address: '>' missing at end of address in address <foo@sub.newdomain.org
and my routing fails since I have removed the routing for "olddomain.org"
So I modified my rewriting rule to
^(.*)@(.*)\.olddomain\.org $1@$2.newdomain.org> TS
(note the '>') Now it works as expected !?
Anyway with this, I'll get
# exim -brw foo@sub.olddomain.org
2022-08-09 16:24:33 Rewrite of foo@sub.olddomain.org yielded unparseable address: malformed address: > may not follow foo@sub.newdomain.org in address foo@sub.newdomain.org>
sender: foo@sub.olddomain.org
from: foo@sub.olddomain.org
to: foo@sub.olddomain.org
cc: foo@sub.olddomain.org
bcc: foo@sub.olddomain.org
reply-to: foo@sub.olddomain.org
env-from: foo@sub.olddomain.org
2022-08-09 16:24:33 Rewrite of foo@sub.olddomain.org yielded unparseable address: malformed address: > may not follow foo@sub.newdomain.org in address foo@sub.newdomain.org>
env-to: foo@sub.olddomain.org
What is going wrong here ?
Exim version 4.94.2 under Debian 11 (Bullseye)
Regards, Olaf
--
Karlsruher Institut für Technologie (KIT)
Steinbuch Centre for Computing (SCC)
Dipl.-Geophys. Olaf Hopp
Zirkel 2
Gebäude 20.21, Raum 316
76131 Karlsruhe
Telefon: +49 721 608-48009
E-Mail: Olaf.Hopp@kit.edu
Web: www.scc.kit.edu
Sitz der Körperschaft:
Kaiserstraße 12, 76131 Karlsruhe
KIT - Die Forschungsuniversität in der Helmholtz-Gemeinschaft
we moved some internal domains from "olddomain.org" to "newdomain.org"
we have internal routing for the new and old domain
Now we want to get rid of the routing for "olddomain.org"
and I want to rewrite "olddomain.org" to "newdomain.org"
so "foo@sub.olddomain.org" should become "foo@sub.newdomain.org"
In my rewrite section of exim I use
^(.*)@(.*)\.olddomain\.org $1@$2.newdomain.org TS
which seems to run fine:
# exim -brw foo@sub.olddomain.org
2022-08-09 16:18:28 "foo@sub.olddomain.org" from smtp sender rewritten as "foo@sub.newdomain.org" by rule 1
SMTP: foo@sub.newdomain.org
sender: foo@sub.olddomain.org
from: foo@sub.olddomain.org
to: foo@sub.olddomain.org
cc: foo@sub.olddomain.org
bcc: foo@sub.olddomain.org
reply-to: foo@sub.olddomain.org
env-from: foo@sub.olddomain.org
2022-08-09 16:18:28 "foo@sub.olddomain.org" from env-to rewritten as "foo@sub.newdomain.org" by rule 1
env-to: foo@sub.newdomain.org
However, when I activate this, I see the following in my logs:
2022-08-09 15:59:22 Rewrite of <foo@sub.olddomain.org> yielded unparseable address: '>' missing at end of address in address <foo@sub.newdomain.org
and my routing fails since I have removed the routing for "olddomain.org"
So I modified my rewriting rule to
^(.*)@(.*)\.olddomain\.org $1@$2.newdomain.org> TS
(note the '>') Now it works as expected !?
Anyway with this, I'll get
# exim -brw foo@sub.olddomain.org
2022-08-09 16:24:33 Rewrite of foo@sub.olddomain.org yielded unparseable address: malformed address: > may not follow foo@sub.newdomain.org in address foo@sub.newdomain.org>
sender: foo@sub.olddomain.org
from: foo@sub.olddomain.org
to: foo@sub.olddomain.org
cc: foo@sub.olddomain.org
bcc: foo@sub.olddomain.org
reply-to: foo@sub.olddomain.org
env-from: foo@sub.olddomain.org
2022-08-09 16:24:33 Rewrite of foo@sub.olddomain.org yielded unparseable address: malformed address: > may not follow foo@sub.newdomain.org in address foo@sub.newdomain.org>
env-to: foo@sub.olddomain.org
What is going wrong here ?
Exim version 4.94.2 under Debian 11 (Bullseye)
Regards, Olaf
--
Karlsruher Institut für Technologie (KIT)
Steinbuch Centre for Computing (SCC)
Dipl.-Geophys. Olaf Hopp
Zirkel 2
Gebäude 20.21, Raum 316
76131 Karlsruhe
Telefon: +49 721 608-48009
E-Mail: Olaf.Hopp@kit.edu
Web: www.scc.kit.edu
Sitz der Körperschaft:
Kaiserstraße 12, 76131 Karlsruhe
KIT - Die Forschungsuniversität in der Helmholtz-Gemeinschaft