Problems with debian linux + exim4 + MS Outlook 2003


 
Thread Tools Search this Thread
Top Forums UNIX for Advanced & Expert Users Problems with debian linux + exim4 + MS Outlook 2003
# 1  
Old 10-09-2009
Problems with debian linux + exim4 + MS Outlook 2003

This seems to be a rather constant question that pops up on a lot of forums but as of yet I have not found a complete solutions on any of the forums so I'm asking everyone who might know about this in an attempt to find a complete solution for this:

I have bought 3 domain names and they all point to one Debian Linux (lenny) machine (which is in fact a VPS server with a hosting company). The 3 domains are pretty much "aliases" for one another and there are a few reasons why I bought 3 domains for my company rather than just one but I'm not going to go through them here as that's outside the scope of this discussion. The bottom line is that in terms of emails the 3 domains are equivalent -- so if someone sends an email to liv@domain1.com it should be the same as sending an email to liv@domain2.com or liv@domain3.com. Ultimately, all of these 3 domains deliver their mail locally to user liv in the above example.
I have configured therefor exim4 to accept emails for these 3 domains and I have managed at the end of it to read emails from any of these 3 domains using Microsoft Outlook 2003 with POP3+SSL. (The certificate used by the server currently is a self-signed one, however, once I finish configuring exim I will buy a proper certificate.) The problem however arrived when I tried to SEND an email using the same MS Outlook and the same exim4 server -- as I have configured exim to only allow relaying for authenticated users -- all the other emails will be rejected unless of course the email is intended for one of the domains hosted on this server. I have tested the exim4 configuration using the likes of thunderbird (well icedove in debian) and managed to send and receive emails successfully from another linux machine I have at home -- so I know that SMTP auth over SSL works because it worked with Thunderbird and I could send emails. However, when connecting MS Outlook 2k3 to the exim server I end up with one of the 2 cases: either outlook doesn't authenticate, in which case the email gets rejected, or there is a protocol error and outlook ends up reporting that my server doesn't support SSL connections.
I have looked on the net and this seems to be a problem with Outlook's TLS/SSL implementation however even using some authenticators given on other sites doesn't seem to fix the problem.
Here are the configuration files for exim4 (I use split configuration):

/etc/exim4/update-exim4.conf.conf

dc_eximconfig_configtype='internet'
dc_other_hostnames='domain1.com;domain2.com;domain3.com'
dc_local_interfaces='127.0.0.1;213.175.212.100'
dc_readhost=''
dc_relay_domains=''
dc_minimaldns='false'
dc_relay_nets='mail.domain1.com;mail.domain2.com;mail.domain3.com'
dc_smarthost=''
CFILEMODE='644'
dc_use_split_config='true'
dc_hide_mailname=''
dc_mailname_in_oh='true'
dc_localdelivery='maildir_home'


/etc/exim4/conf.d/main/000_localmacros:

daemon_smtp_ports = 25 : 465
tls_on_connect_ports = 465
AUTH_CLIENT_ALLOW_NOTLS_PASSWORDS = 1
smtp_enforce_sync = false
MAIN_TLS_ENABLE = true

/etc/exim4/conf.d/auth/30_exim4-config_examples:

plain_login:
driver = plaintext
public_name = PLAIN_LIV
server_prompts = :
server_condition = ${lookup {$auth2} lsearch {/etc/exim/auth} {${if eq {$value}{$auth3} {yes}{no}}}{no}}
server_set_id = $auth2

fixed_login:
driver = plaintext
public_name = LOGIN
server_prompts = Username:: : Password::
server_condition = ${lookup {$auth1} lsearch {/etc/exim/auth} {${if eq {$value}{$auth2} {yes}{no}}}{no}}
server_set_id = $auth1

plain_server:
driver = plaintext
public_name = PLAIN
server_condition = "${if crypteq{$auth3}{${extract{1}{:}{${lookup{$auth2}lsearch{CONFDIR/passwd}{$value}{*:*}}}}}{1}{0}}"
server_set_id = $auth2
server_prompts = :
.ifndef AUTH_SERVER_ALLOW_NOTLS_PASSWORDS
server_advertise_condition = ${if eq{$tls_cipher}{}{}{*}}
.endif

support_broken_outlook_express_4_server:
driver = plaintext
public_name = "\r\n250-AUTH=PLAIN LOGIN"
server_prompts = User Name : Password
server_condition = no
.ifndef AUTH_SERVER_ALLOW_NOTLS_PASSWORDS
server_advertise_condition = ${if eq{$tls_cipher}{}{}{*}}
.endif
cram_md5:
driver = cram_md5
public_name = CRAM-MD5
client_name = ${extract{1}{:}{${lookup{$host}nwildlsearch{CONFDIR/passwd.client}{$value}fail}}}
client_secret = ${extract{2}{:}{${lookup{$host}nwildlsearch{CONFDIR/passwd.client}{$value}fail}}}

# this returns the matching line from passwd.client and doubles all ^
PASSWDLINE=${sg{\
${lookup{$host}nwildlsearch{CONFDIR/passwd.client}{$value}fail}\
}\
{\\N[\\^]\\N}\
{^^}\
}

plain:
driver = plaintext
public_name = PLAIN
.ifndef AUTH_CLIENT_ALLOW_NOTLS_PASSWORDS
client_send = "<; ${if !eq{$tls_cipher}{}\
{^${extract{1}{:}{PASSWDLINE}}\
^${sg{PASSWDLINE}{\\N([^:]+Smilie(.*)\\N}{\\$2}}\
}fail}"
.else
client_send = "<; ^${extract{1}{:}{PASSWDLINE}}\
^${sg{PASSWDLINE}{\\N([^:]+Smilie(.*)\\N}{\\$2}}"
.endif

login:
driver = plaintext
public_name = LOGIN
.ifndef AUTH_CLIENT_ALLOW_NOTLS_PASSWORDS
# Return empty string if not non-TLS AND looking up $host in passwd-file
# yields a non-empty string; fail otherwise.
client_send = "<; ${if and{\
{!eq{$tls_cipher}{}}\
{!eq{PASSWDLINE}{}}\
}\
{}fail}\
; ${extract{1}{::}{PASSWDLINE}}\
; ${sg{PASSWDLINE}{\\N([^:]+Smilie(.*)\\N}{\\$2}}"
.else
# Return empty string if looking up $host in passwd-file yields a
# non-empty string; fail otherwise.
client_send = "<; ${if !eq{PASSWDLINE}{}\
{}fail}\
; ${extract{1}{::}{PASSWDLINE}}\
; ${sg{PASSWDLINE}{\\N([^:]+Smilie(.*)\\N}{\\$2}}"
.endif


(note that the above is a mixture of default exim config and other items I have found on the web as recommended (however, they didn't work!).

/etc/exim4/conf.d/router/350_exim4-config_vdom_aliases:

vdom_aliases:
driver = redirect
allow_defer
allow_fail
domains = dsearch;/etc/exim4/virtual
data = ${expand:${lookup{$local_part}lsearch*@{/etc/exim4/virtual/$domain}}}
retry_use_local_part
pipe_transport = address_pipe
file_transport = address_file
no_more

and finally, the vhosts stuff:
/etc/exim4/virtual/ contains 3 files, each file named after the domain name -- so domain1.com, domain2.com and domain3.com and each file is identical to the other, so i'll give you just the contents of domain1.com

webmaster : local_user@localhost
office : local_user@localhost
administrator: local_user@localhost

(the idea being as i said that all the emails on these 3 domains arrive in one local mailbox).
Now, taking this into account, any idea on how to configure outlook to authenticate against exim4 using a secure connection TLS/SSL so mails can be sent from MS Outlook? Bear in mind I'm using Outlook 2003, part of the MS Office suite, not outlook express!
Thanks!
Login or Register to Ask a Question

Previous Thread | Next Thread

5 More Discussions You Might Find Interesting

1. Debian

Debian exim4 security patch

I have just had to fix a debian5 system which suddenly started rejecting correctly addressed emails as '550 relay not permitted.' It turned out that rogue exim4 config files had been injected into the system at /etc/exim4/exim4.conf and /etc/exim4/exim.conf and these were messing up mail routing. ... (0 Replies)
Discussion started by: KevinGB
0 Replies

2. Debian

Sending mail from outlook to virtual debian

Hello to all! I have a problem and i would really need your help. I have virtual debian on my VMware player with already set postfix and dovecot programs so I can send mail from user to user. Next step is to set outlook express on my physical computer (win xp) to send mail to virtual debian.... (0 Replies)
Discussion started by: Red_Lion
0 Replies

3. UNIX for Dummies Questions & Answers

EXim4 on Debian - setting up multiple mailboxes

I have exim4 smtp server running on Debian. I tend to use only one user account to login. The machine is running multiple websites and I have assigned unique email addresses for each of the websites. Emails sent to these addresses do not seem to get delivered. Emails sent to the alias that I... (0 Replies)
Discussion started by: shikarishambu
0 Replies

4. UNIX for Dummies Questions & Answers

UNIX mail to Outlook 2003

I'm trying to move a users multiple folders (archieved email) from a Solaris UNIX system to Outlook 2003. The user accesses the mail via ELM and folder are kept on his home drive, not under /var/mail. I was told I can use either IMAP and/or POP3 to connect to the UNIX server from outlook and just... (1 Reply)
Discussion started by: rpennell
1 Replies

5. Linux

How to Unite Redhat 9 Linux with Windows 2003 Active Directory authentication

Dear All, How to configure a Redhat 9 client to windows 2003 server. I have windows 2003 server which act has domain controller in my office. I have been asked to use redhat 9 has client. how to configure so that redhat 9 can authenticate with windows 2003 server .I have username created in... (0 Replies)
Discussion started by: solaris8in
0 Replies
Login or Register to Ask a Question