Scalix sending email through internet domain smtp

Discuss the Scalix Server software

Moderators: ScalixSupport, admin

lei
Posts: 30
Joined: Mon Feb 26, 2007 11:35 am

Scalix sending email through internet domain smtp

Postby lei » Tue Mar 27, 2007 6:16 am

Hi,

i have a fresh install of Scalix and i wonder what steps have to be taken to achieve that
all mails sent from my scalix server (mastermind.consolex.int) will actually be sent
by (mail.mywebserver.com).

e.g:
If scalix user Sepp.Maier@mastermind.consolex.int sends a mail the recipient shall read
Sepp.Maier@mywebserver.com as FROM Name.

Also if Sepp.Maier@mastermind.consolex.int receives mail, that mail shall be popped from mail.mywebserver.com.


I think this is the most common scenario, cause most companies < 10 User may have a pop mailserver on their internetdomain which should be used to receive and send mail.
Scalix Server is an intranet server not being able to act as a mailserver, not being on registered top level domain but behind a dyndns service.


Im looking for a list of steps to take.


Thanks for helping me


Greetings lei

Shredder

Postby Shredder » Tue Mar 27, 2007 10:56 am

I think you want to set up a smarthost. This causes all your outbound email to go through another SMTP server. The following HowTo explains how to set up a smarthost.

http://www.scalix.com/wiki/index.php?ti ... ntegration

Thanks,
Shredder

lei
Posts: 30
Joined: Mon Feb 26, 2007 11:35 am

Postby lei » Tue Mar 27, 2007 1:17 pm

Ok, lets expect i have set the smarthost. Which i havent done yet. :(

How does the FROM Header get the correct name.

I want Sepp.Maier@consolex.de to be the correct sender to be able to reply to, not
Sepp.Maier@mastermind.consolex.int.

Thanks for taking me one step further.

Step 1: Set Smart_Host in sendmail.mc (linux.mc in suse) + smtp authentication
Step 2: ?

KevinAnderson

Postby KevinAnderson » Tue Mar 27, 2007 1:33 pm

Scalix will send email with the from address set to the top email address listed for the employee in SAC. If that's not the case, then sendmail is rewriting your headers.

I think what you want to do is port forward port 110, 80, 25, and 143 from your webserver to the Scalix server. The port breakdown is as follows.

Port 80 Webmail.
Port 110 POP
Port 143 IMAP
Port 25 SMTP.

I suspect the addresses showing in SAC are wrong. Correcting them should resolve your sending problem, and forwarding the ports will resolve the issue of recieving mail from outside the company.

Note that I would recommend against dyndns, and tell you that you should have a static IP.

Kev.

lei
Posts: 30
Joined: Mon Feb 26, 2007 11:35 am

Postby lei » Tue Mar 27, 2007 3:33 pm

The Scalix Server is thought to be an Intranet Server.

I want to use it for its Groupware functionality. All i want to do is to send/fetch mail via/from my webdomain (extranet/www) smtp/pop server which is

220 xxx.hosteurope.de ESMTP Exim 4.43 Tue, 27 Mar 2007 21:08:34 +0200


Why open any ports and forward. If i wanted users from www to enter my intranet id use openvpn or something?

I think i´m getting the point but im not quite sure yet.

1. Scalix uses sendmail (localhost) to send mail :) which has to be configured with SMART_HOST parameter and everything in the MTA Wiki. If everything is correct then mail is sent with the FROM adress put to what has been entered in the SAC for the user.

2. Mail has to be received via fetchmail and cronjob for fetching the mails every x minutes??

poll mail.mydomain.com with proto POP3
user ''#mailboxname#" there
with password "#password#" is #USER# here warnings 3600


Can #USER# be altered to internal mailbox name for example Sepp.Maier@mastermind.consolex.int
or how does the mail get to the local imap folder via the Linux User?
I think im lacking linux mail processing knowledge, or im just to stupid :(


Isnt there a better/ another way to receive the mail from www pop server and get it into the local imap folders (intranet)


Many words, many thx


greetings lei

Shredder

Postby Shredder » Tue Mar 27, 2007 5:51 pm

I think I misunderstood how your site is configured.

I think this is how it works currently:
1) All your incoming mail is delivered to a mail server that you do not house.
2) Each of your users currently POP the mail off and store them locally.
3) Each user sends mail through the mail server that you do not house.

The new way with the Scalix server:
1) Create the scalix server with your correct domain name (The last part of users email address)
2) Create your users so they have valid email addresses.
3) Configure your Scalix box to use the Smart Host for sending out.
4) Set up fetchmail to get the mail from the server your mail is actually delivered to.
5) Reconfigure your clients to either use the Outlook Connector pointing to the Scalix Server or using POP/IMAP pointing at your Scalix Server

This will cause a delay for messages to be delivered from outside email addresses as you need to wait for the fetchmail script to run to get the mail.

In the fetchmail line you do change the #USER# to be your user's email address on the scalix server.

Your Scalix Server does not need to be out on the internet. All it needs is to be able to get to port 25 on your outgoing mail server. Put it behind your firewall with a local IP address. I think you said you did not want outside webmail access to the server, so this will accomplish that too.

Hopefully that makes sense.

Shredder

lei
Posts: 30
Joined: Mon Feb 26, 2007 11:35 am

Postby lei » Tue Mar 27, 2007 8:18 pm

first of all, thx for helping me :)

Lets say the domain of the server i do not host is xxx.com

You mean i have to set the hostname of my intranet server to xxx.com?

How would SMART_HOST option know what server im trying to use as relay, locahost oder webserver (www) ?

I thought if intranet email is mastermind.consolex.int the FROM gets set to -> quote

Scalix will send email with the from address set to the top email address listed for the employee in SAC

jaime.pinto
Scalix Star
Scalix Star
Posts: 709
Joined: Fri Feb 23, 2007 6:50 pm
Location: Toronto - Canada

Postby jaime.pinto » Tue Mar 27, 2007 9:48 pm

Hi Lei

Let's go back to your initial question and try to understand the difference between what can be accomplished with the use of smarthost or SMTP server, and something else missing in your question.
all mails sent from my scalix server (mastermind.consolex.int) will actually be sent by (mail.mywebserver.com).
e.g:
If scalix user Sepp.Maier@mastermind.consolex.int sends a mail the recipient shall read
Sepp.Maier@mywebserver.com as FROM Name.

That can done with the smarthost setup to mywebserver.com in the sendmail.mc of your scalix server, and since it's a completely difference domain you don't have to bother at all with scalix (at least for emails going "out" of the scalix server). It so happens that the smarthost is the SMTP server.

Also if Sepp.Maier@mastermind.consolex.int receives mail, that mail shall be popped from mail.mywebserver.com.

This is a different issue, just as independent of scalix. Lets be carefull with the term "popped", as it has a very clear and well understood meaning, and probably not how you intended to use it. You can accomplish what you want by *forwarding* all incoming emails from mail.mywebserver.com to mastermind.consolex.int, but only for those users that have an account on the scalix server.

I started the thread below for a different purpose, but it lists all you need to do what you want. You may just need to *read through* it.

viewtopic.php?t=6330&highlight

lei
Posts: 30
Joined: Mon Feb 26, 2007 11:35 am

Postby lei » Tue Mar 27, 2007 11:40 pm

After having sendmail configured this is what happens when i try sending a mail via e.g webmailer. Im not quite sure but i think the problem is on the SMART_HOST side.

Bounced mail:
Original-Envelope-Id: 12624208.521174966283788.JavaMail.root@ ... nsolex.int
Reporting-MTA: dns; mastermind.consolex.int
Received-From-MTA: dns; localhost
Arrival-Date: Tue, 27 Mar 2007 05:31:25 +0200

Final-Recipient: rfc822; test@mydomain.de
X-Actual-Recipient: RFC822; test@consolex.de
Action: failed
Status: 5.1.1
Remote-MTA: DNS; mail.mydomain.de
Diagnostic-Code: SMTP; 550 relay not permitted
Last-Attempt-Date: Tue, 27 Mar 2007 05:31:27 +0200


this is /var/log/mail.warn

Mar 27 05:31:27 mastermind sendmail[6422]: AUTH=client, relay=mail.mydomain.de [80.237.132.17], authinfo failed


auth-info file for sendmail is good i think... i need more detail about the error. How to get that information.


Thx, lei

jaime.pinto
Scalix Star
Scalix Star
Posts: 709
Joined: Fri Feb 23, 2007 6:50 pm
Location: Toronto - Canada

Postby jaime.pinto » Wed Mar 28, 2007 4:51 am

3 details/notes:

1) the mail.mywebserver.com server needs to authorize mastermind.consolex.int to relay messages through it. That seems to be the reason for this error. This is a safety feature to prevent spam via your SMTP server. If mail.mywebserver.com is using sendmail as well, that would require an entry in the /etc/acess of the form:
mail.mywebserver.com RELAY
or
IP_ADDRESS_OF_mail.mywebserver.com RELAY

2) If mastermind.consolex.int is not behind the firewall or being prevented from sending emails out directly, you may consider *NOT* using smarthost, and send emails out directly from the scalix server mastermind.consolex.int. But many servers out there do background check to confirm the email is indeed coming from where it claims to be (ie. mywebserver.com) against MX entries, domainkeys and so on, so this may not work that well for you, since you could get lots of rejected emails. So, the best practice/policy is always to send the emails from the server whose domain you're masquerading the address with (see note 3)

3) Sorry but I made a mistake on my previous post. The way to replace Sepp.Maier@mastermind.consolex.int with Sepp.Maier@mywebserver.com is via the MASQUERADE envelope with mywebserver.com in the sendmail.mc on the scalix server. This *MUST* be configured whether or not you use smarthost.

Again, all the smarthost/masquerade considerations seem to be well described in the post below: Also note that none of what you're trying to do is dependent in anyway on the scalix setup itself.
viewtopic.php?t=6330&highlight

lei
Posts: 30
Joined: Mon Feb 26, 2007 11:35 am

Postby lei » Wed Mar 28, 2007 7:02 am

dont you think this is just a problem of entering the right authentication method
in auth-info


Im not quite sure what auth method hosteurope.de is using.
I have entered none in the auth-info e.g M:PLAIN i think is how to tell sendmail,
to be more precise the M: Flag, maybe M: SASL, i dont have a clue


AuthInfo: mail.domain.de U: user I: mailadress P: Password M:PLAIN

Here some info about the webdomain SMART_HOST


Connected to mail.consolex.de.
Escape character is '^]'.
220 wp010.webpack.hosteurope.de ESMTP Exim 4.43 Wed, 28 Mar 2007 14:29:35 +0200
EHLO foo
250-wp010.webpack.hosteurope.de Hello m843e.m.pppool.de [89.49.132.62]
250-SIZE 26214400
250-PIPELINING
250-AUTH PLAIN LOGIN
250-STARTTLS
250 HELP


mastermind:/etc/mail # sendmail -bv admin@consolex.de
admin@consolex.de... deliverable: mailer scalix_mime, host mastermind, user admin@consolex.de
mastermind:/etc/mail #

jaime.pinto
Scalix Star
Scalix Star
Posts: 709
Joined: Fri Feb 23, 2007 6:50 pm
Location: Toronto - Canada

Postby jaime.pinto » Wed Mar 28, 2007 8:54 am

The authentication can be done in 2 ways:

1) Every individual user has to provide name/password directly to the SMTP server (not the scalix server) at the time of the send

2) The whole scalix server is authorized by the SMTP server with the /etc/access entry there.

The first option is not practical.That seems what your ISP is expecting you to do. My impression is that your SMTP server belongs to your ISP, and it's something you have no control over.

Well. I'd try to talk to them and explain the situation, and ask them to work on option 2)

Otherwise consider dropping the external SMTP services all together and and move all your users to the scalix server with *your company's* domain on the email, and use the scalix server to do the true job it's designed to do: be a self-contained fully featured mail server. This is a call only you and your company can make, and I can understand the difficulty related to branding and stationary already in place with the old emails, etc.

So, please try to talk with your ISP first.

Jaime

lei
Posts: 30
Joined: Mon Feb 26, 2007 11:35 am

Postby lei » Wed Mar 28, 2007 6:31 pm

i solved the problem, thx to everybody for helping, but i have to admit the wiki HowTo MTA
was totally right.


I just missed some quotation marks in the auth-info file
so wrong auth-info.db

I feel like a piece of shit now, but at least its working :)


Return to “Scalix Server”



Who is online

Users browsing this forum: No registered users and 12 guests

cron