Multiple Addresses, Single Account, Filter to Folder - How?

Discuss the Scalix Server software

Moderators: ScalixSupport, admin

Flish
Posts: 45
Joined: Sat Mar 18, 2006 11:18 am
Location: UK - North East, Teesside
Contact:

Multiple Addresses, Single Account, Filter to Folder - How?

Postby Flish » Sat Mar 18, 2006 11:34 am

This seems to be a simple request, but can't for the life of me work it out. Our setup (versio 10 on Suse 10 OSS btw) has a user created with the default email address of enquiries@ however it also has additional addresses such as support@ accounts@ fax@ etc.

The idea is that delivery of all these addresses is to a single IMAP box that a number of people have access to and can deal with the mail. The mail is filtered on the To address so that it automatically drops into the right folder hierarchy. Except, that the the to address is being re-written, all the email gets to the right account, yet it always appears as to enquiries@ as that happens to be the primary address.

So, how am I supposed to filter, only means I can see is on the headers looking for the phrase "for <accounts@mydomain.com>" or similar. In fact, why is there the option to filter on the To address, is you know full well that the To address is always the same?!?

On same note, I understand that it's deliberate 'feature' that we can't change the from address? Is this really true? As again in above scenario if we are replying to an email sent to accounts@ then we want to reply as from accounts@, so that when they reply it gets filtered to the correct place (Which ironically doesn't work).

Now, I know we *could* use multiple accounts, but in this case means somewhere in the region of 10 accounts for the different prefixes, which is unmanageable, we don't that many people!, so appreciate it if someone could through some ideas into the hat as to how to work round this as it's been driving me nuts.

TIA

mephisto

Postby mephisto » Sat Mar 18, 2006 1:25 pm

I don't see the "To" line being rewritten on my server. My mailbox accepts mail for several adresses and they all show up in the mails' headers. I also have an external adress that forwards mail to my local scalix account and the To-address remains unchanged in the headers, too. Same thing with mails coming from external mailing lists.

Flish
Posts: 45
Joined: Sat Mar 18, 2006 11:18 am
Location: UK - North East, Teesside
Contact:

Postby Flish » Sat Mar 18, 2006 2:32 pm

I don't see the "To" line being rewritten on my server. My mailbox accepts mail for several adresses and they all show up in the mails' headers. I also have an external adress that forwards mail to my local scalix account and the To-address remains unchanged in the headers, too. Same thing with mails coming from external mailing lists.


Well, I don't think I've actively turned on / off any features that would do this,b ut below is header from one test example. As you can see it was sent to accounts@ and was directed to the correct user account, but the To: field has been re-written to enquiries@ which is the defaul, ie first, email address for that user account.

[i]Return-Path: <andy@mydomain.com>
Received: from caladan.mydomain.com (localhost [127.0.0.1])
by caladan.mydomain.com (8.13.4/8.13.4/SuSE Linux 0.7) with ESMTP id k2IFihuv015163
for <accounts@mydomain.com>; Sat, 18 Mar 2006 15:44:46 GMT
Received: from caladan.mydomain.com (root@localhost)
by caladan.mydomain.com (8.13.4/8.13.4/Submit) with ESMTP id k2IFihJg015162
for <accounts@mydomain.com>; Sat, 18 Mar 2006 15:44:43 GMT
Received: from [192.168.42.17] (muadib.mydomain.com 192.168.42.17)
by caladan.mydomain.com (Scalix SMTP Relay 10.0.0.175)
via ESMTP; Sat, 18 Mar 2006 15:44:43 +0000 (GMT)
Date: Sat, 18 Mar 2006 15:38:41 +0000
From: "Andy Flisher" <andy@mydomain.com>
To: "Enquiries" <enquiries@mydomain.com>
Message-ID: <441C2981.7060809@mydomain.com>
In-Reply-To: <441C28EB.3040609@mydomain.com>
References: <441C28EB.3040609@mydomain.com>
Subject: Re: test
User-Agent: Mozilla Thunderbird 1.0.7 (Windows/20050923)
X-Accept-Language: en-us, en
X-Spam-Status: No, score=-2.4 required=5.0 tests=ALL_TRUSTED autolearn=failed
version=3.0.4
X-Spam-Checker-Version: SpamAssassin 3.0.4 (2005-06-05) on caladan.mydomain.com
MIME-Version: 1.0
Content-Type: text/plain;
charset="ISO-8859-1"
Content-Disposition: inline[/]i

mephisto

Postby mephisto » Sat Mar 18, 2006 2:34 pm

Is muadib.mydomain.com (192.168.42.17) your local client or another server?

Flish
Posts: 45
Joined: Sat Mar 18, 2006 11:18 am
Location: UK - North East, Teesside
Contact:

Postby Flish » Sat Mar 18, 2006 4:04 pm

Is muadib.mydomain.com (192.168.42.17) your local client or another server?


It's the client PC which sent the mail, caladan is the scalix server, there are other boxes on the lan but none *should* be involved.

florian
Scalix
Scalix
Posts: 3852
Joined: Fri Dec 24, 2004 8:16 am
Location: Frankfurt, Germany
Contact:

Postby florian » Sat Mar 18, 2006 6:23 pm

mephisto,

which version of scalix are you using for this test and in which header do you see the original recipient address?

thx,
Florian.
Florian von Kurnatowski, Die Harder!

mephisto

Postby mephisto » Sat Mar 18, 2006 6:28 pm

I'm using Scalix 10, and I'm seeing the recipient address under "To:" like this:

Code: Select all

To: root@mydomain.com

or this:

Code: Select all

To: mylastname@mydomain.com

florian
Scalix
Scalix
Posts: 3852
Joined: Fri Dec 24, 2004 8:16 am
Location: Frankfurt, Germany
Contact:

Postby florian » Sat Mar 18, 2006 6:30 pm

Flish,

I just tried to send to one of my non-primary aliases from a gmail account and i could actually see the address it was sent to in the header.

Obviously, the content of the header also depends on what client you're using; I assume you're sending within your domain - is this SWA or another pop/imap client you're sending from or is it Outlook/MAPI?

Thx,
Florian.
Florian von Kurnatowski, Die Harder!

Flish
Posts: 45
Joined: Sat Mar 18, 2006 11:18 am
Location: UK - North East, Teesside
Contact:

Postby Flish » Sat Mar 18, 2006 7:23 pm

florian wrote:Flish,

I just tried to send to one of my non-primary aliases from a gmail account and i could actually see the address it was sent to in the header.

Obviously, the content of the header also depends on what client you're using; I assume you're sending within your domain - is this SWA or another pop/imap client you're sending from or is it Outlook/MAPI?
.


Yes to sending within domain, all these tests are just circulating locally within Scalix and not from outside.

This particlular account is just accessed using Thunderbird over IMAP. Sending Client has been tested from Thunderbird via Imap and Outlook over MAPI and I get the same results, always showing a To: address that is the primary alias. The only difference is that when sent from a MAPI client there are a lot less headers, in fact there's no 'via' headers at all, and no reference to the 'real' address it was sent to at all (so my filtering hack using the 'for' header fails.

This is a cliean install of all components, and only hacking about has been related to Spamassassin (working) and Clam AV (not working so disabled), so pretty sure I haven't accidentally buggered this up, but really wanting to be proved wrong and corrected!

Flish
Posts: 45
Joined: Sat Mar 18, 2006 11:18 am
Location: UK - North East, Teesside
Contact:

Postby Flish » Sat Mar 18, 2006 7:30 pm

As an addition just tested via SWA, and same result, To: field is always the primary alias, and header wise much the same as the example posted from an IMAP client, show's the via routes and show's the 'for' header.

Only other cmd line hacks I have are a few catch all aliases in the smtpd.cfg, but can't see hoe they could be to blame?

florian
Scalix
Scalix
Posts: 3852
Joined: Fri Dec 24, 2004 8:16 am
Location: Frankfurt, Germany
Contact:

Postby florian » Sat Mar 18, 2006 7:30 pm

Flish,

for Outlook/MAPI, the behaviour is by design and I believe we cannot change it.

Outlook will try to resolve every address you give it through the system directory. This will then only refer to a mailbox object and no longer to a specific address of such an object. By default, the Scalix X.400 address of the mailbox will be used. In addition, MAPI has no concept of MIME headers (as the message format isn't MIME), so the only headers you will see on such a message, when rendered into MIME, will be the ones that have representatives in MAPI properties as well.

I'm surprised on the IMAP part. Can you do the following?

1) In /var/opt/scalix/sys/smtpd.cfg, add a line reading DEBUG_LOG=TRUE
2) restart the smtp relay using "omoff -d 0 -w smtpd; omon -w smtpd"
3) resend the message
4) remove the line added in (1) and repeat step (2)

You will then have a capture of the raw SMTP conversation in /var/opt/scalix/tmp/smtpd.log. Please post this log information. We should have a look at the headers as they come from the client.

Thx,
Florian.
Florian von Kurnatowski, Die Harder!

Flish
Posts: 45
Joined: Sat Mar 18, 2006 11:18 am
Location: UK - North East, Teesside
Contact:

Postby Flish » Sun Mar 19, 2006 8:11 am

Ok, log as below, this time unmasked, some lines may have wrapped, which I think I corrected, but otherwise raw.

FYI dotuk.net is the public domain name, dotuk.local is the dummy internal domain name which is used purely for naming (we have a Windows PDC on the lan for other things)

caladan.dotuk.local is the scalix server (all services on single box, dingle mailnode) muadib.dotuk.local is client PC, again using Thunderbird over IMAP.

My viewing tells me that sendmail and the client are doing everything correctly, all the rcpt to: lines arec correct, the to: header is correct, so something is hapening after sendmail hands the mail over, the local delivery side. Am trying to locate these logs now, but any pointers welcome

SMTP Relay 10.0.0.175 started (25370): Sun, 19 Mar 2006 12:02:47 +0000 (GMT)
Accepted client 1 from (muadib.dotuk.local)
Cli 25370/1 sent : 220 caladan.dotuk.local ESMTP Scalix SMTP Relay
10.0.0.175; Sun, 19 Mar 2006 12:03:14 +0000 (GMT)

Cli 25370/1 rcvd: 'EHLO [192.168.42.17]'
Cli 25370/1 sent : 250-caladan.dotuk.local Hello muadib.dotuk.local
[192.168.42.17], pleased to meet you
250-AUTH CRAM-MD5 DIGEST-MD5 LOGIN PLAIN GSSAPI
250-AUTH=LOGIN
250-DSN
250 8BITMIME

Cli 25370/1 rcvd: 'MAIL FROM:<andy@dotuk.net>'
Cli 25370/1 sent : 250 andy@dotuk.net... Sender ok

Cli 25370/1 rcvd: 'RCPT TO:<accounts@dotuk.net>'
... new process 25374
25370: Allocate new sendmail process 25374
Cli 25370/1 rcvd S: '220 caladan.dotuk.local ESMTP Sendmail
8.13.4/8.13.4/Submit; Sun, 19 Mar 2006 12:03:19 GMT'
Cli 25370/1 rcvd S: '250 2.1.0 <andy@dotuk.net>... Sender ok'
Cli 25370/1 sent S: rcpt to: <accounts@dotuk.net>

Cli 25370/1 rcvd S: '250 2.1.5 <accounts@dotuk.net>... Recipient ok'
Cli 25370/1 sent : 250 2.1.5 <accounts@dotuk.net>... Recipient ok

Cli 25370/1 rcvd: 'DATA'
Cli 25370/1 sent : 354 Enter mail, end with "." on a line by itself
(relay)

Cli 25370/1 sent S: data

Cli 25370/1 rcvd S: '354 Enter mail, end with "." on a line by itself'
Cli 25370/1 got .
Cli 25370/1 sent S: Received: from [192.168.42.17] (muadib.dotuk.local
192.168.42.17)
by caladan.dotuk.local (Scalix SMTP Relay 10.0.0.175)
via ESMTP; Sun, 19 Mar 2006 12:03:19 +0000 (GMT)
Message-ID: <441D4718.8040203@dotuk.net>
Date: Sun, 19 Mar 2006 11:57:12 +0000
From: Andy Flisher - dotUK <andy@dotuk.net>
Organization: dotUK - www.dotuk.net
User-Agent: Mozilla Thunderbird 1.0.7 (Windows/20050923)
X-Accept-Language: en-us, en
MIME-Version: 1.0
To: accounts@dotuk.net
Subject: test3
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit

test3
.

Cli 25370/1 rcvd S: '250 2.0.0 k2JC3JfA025374 Message accepted for delivery'
Cli 25370/1: Submitted message ': <441D4718.8040203@dotuk.net>' to sendmail. response: '250 2.0.0 k2JC3JfA025374 Message accepted for delivery'
Cli 25370/1 Finished submitting msg : <441D4718.8040203@dotuk.net>
Cli 25370/1 sent : 250 2.0.0 k2JC3JfA025374 Message accepted for delivery

Cli 25370/1 rcvd: 'QUIT'
Cli 25370/1 sent : 221 caladan.dotuk.local closing connection

Flish
Posts: 45
Joined: Sat Mar 18, 2006 11:18 am
Location: UK - North East, Teesside
Contact:

Postby Flish » Sun Mar 19, 2006 8:22 am

If it's any further help I got these logs from a view more tests, (ignore times logs where from different messages so there's not a time delay!), but all tells me is the user the message was delivered to, which is correct, but something is munging, or assuming the To: header

Service Router
REPORT Service Router(Service Router) 03.19.06 12:22:27
[OM 7803] Started routing of message
REPORT Service Router(Service Router) 03.19.06 12:22:27
[OM 7805] Current message Id
441D4B90.6030400(a)dotuk.net
REPORT Service Router(Service Router) 03.19.06 12:22:27
[OM 7815] Creator of message
Andy Flisher/caladan,dotuk
REPORT Service Router(Service Router) 03.19.06 12:22:27
[OM 7807] Started routing of recipient
Enquiries/caladan,dotuk
REPORT Service Router(Service Router) 03.19.06 12:22:27
[OM 7810] Recipient will be routed to service queue LOCAL if not deferred
REPORT Service Router(Service Router) 03.19.06 12:22:27
[OM 7808] Finished routing of recipient
Enquiries/caladan,dotuk


Local Delivery
REPORT Local Delivery(Local Delivery) 03.19.06 12:25:07
[OM 7603] Started delivery of message
Last Msg Id: 1142856151.7732.1.c
Last Msg DirectRef: 00010475463d5665
REPORT Local Delivery(Local Delivery) 03.19.06 12:25:07
[OM 7605] Current message Id
441D4C31.1040901(a)dotuk.net
Last Msg Id: 1142856151.7732.1.c
Last Msg DirectRef: 00010475463d5665
REPORT Local Delivery(Local Delivery) 03.19.06 12:25:07
[OM 7618] Creator of message
Andy Flisher/caladan,dotuk
Last Msg Id: 1142856151.7732.1.c
Last Msg DirectRef: 00010475463d5665
REPORT Local Delivery(Local Delivery) 03.19.06 12:25:07
[OM 7607] Started delivery to recipient
Enquiries/caladan,dotuk
Last Msg Id: 1142856151.7732.1.c
Last Msg DirectRef: 00010475463d5665
REPORT Local Delivery(Local Delivery) 03.19.06 12:25:07
[OM 7610] Delivering message to user's In Tray
Last Msg Id: 1142856151.7732.1.c
Last Msg DirectRef: 00010475463d5665
REPORT Local Delivery(Local Delivery) 03.19.06 12:25:07
[OM 7608] Finished delivery to recipient
Enquiries/caladan,dotuk
Last Msg Id: 1142856151.7732.1.c
Last Msg DirectRef: 00010475463d5665
REPORT Local Delivery(Local Delivery) 03.19.06 12:25:07
[OM 7604] Finished delivery of message
Last Msg Id: 1142856151.7732.1.c
Last Msg DirectRef: 00010475463d5665
REPORT Service Router(Service Router) 03.19.06 12:22:27
[OM 7812] Putting message on service queue LOCAL
REPORT Service Router(Service Router) 03.19.06 12:22:27
[OM 7804] Finished routing of message

florian
Scalix
Scalix
Posts: 3852
Joined: Fri Dec 24, 2004 8:16 am
Location: Frankfurt, Germany
Contact:

Postby florian » Sun Mar 19, 2006 8:27 am

Which client do you use on the recipient side to look at the To: header?

Thx,
Florian.
Florian von Kurnatowski, Die Harder!

florian
Scalix
Scalix
Posts: 3852
Joined: Fri Dec 24, 2004 8:16 am
Location: Frankfurt, Germany
Contact:

Postby florian » Sun Mar 19, 2006 8:36 am

OK, I start to understand what's going on; when you look at your mail headers through OutlookMAPI you will see the To: field with its original value. If you use an IMAP client such as SWA or Thunderbird, you will only see the "normalized" recipient.

I will need to find out what goes on in the backend.

However, I believe there is a workaround.

For all additional addresses, create a Group/Distribution list that has the Address and only one member, your intended recipients. Groups do not require licenses. Remove the Address from the actual user before.

Then you will be able to see the recipient and filter based on it.

Hope this helps,
Florian.
Florian von Kurnatowski, Die Harder!


Return to “Scalix Server”



Who is online

Users browsing this forum: No registered users and 13 guests