stop recipient address rewriting

Discuss the Scalix Server software

Moderators: ScalixSupport, admin

Maex

stop recipient address rewriting

Postby Maex » Fri Sep 28, 2007 2:01 pm

Hi!

I am currently migrating a cyrus installation with a lot of public folders and sieve scripting.
There is a role account "public" which gets a lot of emails and via sieve they are sorted in the public folders.

I have already learned that in scalix a user cannot put messages to public folders via rules. So I have created the folder structure and "dummy" addresses like public.foldera.subfolderb@example.com and mapped them to the public folders Public>FolderA>FolderB with omaddent. This works rather nicely.

Up to now the mapping was done quick and dirty in /etc/aliases (using postfix as gateway) with entries like
info: public.info@example.com
sales: public.sales@example.com

Now I want to move even the aliases to scalix rulehandling, so I have created alias-addresses for the account "public" for info and sales.

I have added a ruleset for the account public
DL Name = S%info@example.com% REDIRECT public.info@example.com

If now I send a email from extern to info@example.com all works perfect.
However if I send a email from "within" scalix (webmail, outlook) the recipient (info@example.com) seems to become rewritten to public@example.com and so the ruleset does not match and the mail is delivered to the INBOX of user public.

However this only seems to happen if the address is "info" instead von "info@example.com" (i.e. without the domain portion), as the second address is routed to postfix and reinjected to scalix, despite the fact that the alias is "info@example.com".

Is there away to prevent this "rewriting"?

Second question:
Is there a way to tell scalix that example.com and example.net and intranet.example.com are to be treated identically? Adding them in sxadmin -> Admistration -> Local Domains does not have the desired effect.

Any help is greatly appreciated.

\Maex

chris
Scalix Star
Scalix Star
Posts: 321
Joined: Mon May 09, 2005 2:56 pm
Location: Freiburg, Germany

Postby chris » Sun Sep 30, 2007 3:29 pm

HI Maex,

unfortunately there is not a way at present to prevent addresses being rewritten to the primary address of the mailbox.

I'm sure we can find a solution to suit your needs, but I'm not clear as to the exact problem. What are you trying to do with the public-user that you couldn't do addressing email to public folders?

As to the domains question, if what you mean is that testuser@company.com should also get email addressed to testuser@company.net and testuser@intranet.company.com, you can do that with internet address mappings as follows. You add a second mapping, then use the -A switch to ommodu to have it automatically regenerate internet addresses.

[root@mailserver ~]# omshowiam -s all
1 scalix.demo "C" <G.S>
[root@mailserver ~]#
[root@mailserver ~]# omsearch -e cn=* -m cn/internet-addr
CN=sxadmin/INTERNET-ADDR=sxadmin-mailserver@scalix.demo
CN=Bart Simpson/INTERNET-ADDR="Bart Simpson" <Bart.Simpson@scalix.demo>
CN=Homer Simpson/INTERNET-ADDR="Homer Simpson" <Homer.Simpson@scalix.demo>
CN=Krusty The Clown/INTERNET-ADDR="Herschel Pinkus Krustofski" <krusty@scalix.demo>
CN=Moe Szyslak/INTERNET-ADDR="Moe Szyslak" <Moe.Szyslak@scalix.demo>
CN=ScalixAdmins/INTERNET-ADDR=ScalixAdmins@mailserver.scalix.demo
CN=ScalixUserAdmins/INTERNET-ADDR=ScalixUserAdmins@mailserver.scalix.demo
CN=Springfield/INTERNET-ADDR="Springfield" <Springfield@scalix.demo>
CN=sxqueryadmin/INTERNET-ADDR=sxqueryadmin-mailserver@scalix.demo
CN=ScalixGroupAdmins/INTERNET-ADDR=ScalixGroupAdmins@mailserver.scalix.demo
CN=ScalixUserAttributesAdmins/INTERNET-ADDR=ScalixUserAttributesAdmins@mailserver.scalix.demo
[root@mailserver ~]#
[root@mailserver ~]# omaddiam -s 2 -D scalix.local -N '"C" <G.S>'
omaddiam : Orn to Internet Address Mapping successfully added.
[root@mailserver ~]# omshowiam -s all
1 scalix.demo "C" <G.S>
2 scalix.local "C" <G.S>
[root@mailserver ~]#
[root@mailserver ~]# omshowu -m all|while read line; do ommodu -n "$line" -A; done
ommodu: The user was modified successfully
ommodu: The user was modified successfully
ommodu: The user was modified successfully
ommodu: The user was modified successfully
ommodu: The user was modified successfully
[root@mailserver ~]#
[root@mailserver ~]# omsearch -e cn=* -m cn/internet-addr
CN=sxadmin/INTERNET-ADDR="sxadmin" <sxadmin@scalix.demo>="sxadmin" <sxadmin@scalix.local>
CN=Bart Simpson/INTERNET-ADDR="Bart Simpson" <Bart.Simpson@scalix.demo>="Bart Simpson" <Bart.Simpson@scalix.local>
CN=Homer Simpson/INTERNET-ADDR="Homer Simpson" <Homer.Simpson@scalix.demo>="Homer Simpson" <Homer.Simpson@scalix.local>
CN=Krusty The Clown/INTERNET-ADDR="Herschel Pinkus Krustofski" <krusty@scalix.demo>
CN=Moe Szyslak/INTERNET-ADDR="Moe Szyslak" <Moe.Szyslak@scalix.demo>="Moe Szyslak" <Moe.Szyslak@scalix.local>
CN=ScalixAdmins/INTERNET-ADDR=ScalixAdmins@mailserver.scalix.demo
CN=ScalixUserAdmins/INTERNET-ADDR=ScalixUserAdmins@mailserver.scalix.demo
CN=Springfield/INTERNET-ADDR="Springfield" <Springfield@scalix.demo>
CN=sxqueryadmin/INTERNET-ADDR="sxqueryadmin" <sxqueryadmin@scalix.demo>="sxqueryadmin" <sxqueryadmin@scalix.local>
CN=ScalixGroupAdmins/INTERNET-ADDR=ScalixGroupAdmins@mailserver.scalix.demo
CN=ScalixUserAttributesAdmins/INTERNET-ADDR=ScalixUserAttributesAdmins@mailserver.scalix.demo

Is that something like what you were looking for?

Chris

Maex

Postby Maex » Sun Sep 30, 2007 4:06 pm

Hi chris,

thanks a lot for the answer!

chris wrote:HI Maex,
unfortunately there is not a way at present to prevent addresses being rewritten to the primary address of the mailbox.


Ok

chris wrote:I'm sure we can find a solution to suit your needs, but I'm not clear as to the exact problem. What are you trying to do with the public-user that you couldn't do addressing email to public folders?


Ah ok.
The public user is a kind of a catchall user. It is a central management point for a few dozen email addresses that are used for roles (think of "webmaster", "info", support", ...).
These all are aliases for "public" and there is a ruleset that checks if the mail was for "webmaster" and forwards it to public.webmaster which is associated with a a public folder "webmaster". Same for the other roles.
The public folders are also used as communication archives and a kind of tracking mechanism.

Now if one of the persons that are "webmaster" replies to a mail in the public folder usually all is fine, as it takes an external hop.
However if he initiates a "fresh" mail to an external address and e.g. Cc:s webmaster (without domain) it doesn't get delivered to the public folder (but the reply of the external user does) and so the original mail ist "lost" or (as I have configured it now) is delivered to a catchall public folder where one has to move it to the correct public folder per hand (which is really painful as there is no way to stop rule matching, so every mail currently goes also to the catchall folder).
This handwork is what I wanted to eliminate by stopping the auto rewriting.

I hope it is clearer now.

\Maex

chris
Scalix Star
Scalix Star
Posts: 321
Joined: Mon May 09, 2005 2:56 pm
Location: Freiburg, Germany

Postby chris » Sun Sep 30, 2007 4:25 pm

But couldn't you do the same just by making webmaster the actual email address of the public folder, eliminating the catchall completely?

Chris


Return to “Scalix Server”



Who is online

Users browsing this forum: No registered users and 2 guests

cron