LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 12-03-2009, 04:36 AM   #1
kingkashif
Member
 
Registered: May 2009
Posts: 94

Rep: Reputation: 16
Arrow exim - helo_data and primary_hostname for different subdomains with different IPs


Hello Friends,

I've exim 4.69 as my mailserver.

I have dns info like following
Code:
domain.com 10.10.10.1

mail.domain.com 10.10.10.2

a.domain.com 10.10.10.10

b.domain.com 10.10.10.11

c.domain.com 10.10.10.12
    .
my system's hostname is
Code:
mail.domain.com
I've set these options

Code:
Send HELO based on the domain name in /etc/mailhelo
Send outgoing mail from the ip that matches the domain name in /etc/mailips
It works when I send a mail from user@c.domain.com
then c.domain.com's ip is used.

But the problem is that if anyone does a helo to
any of my subdomain e.g b.domain.com
then It shows
Code:
Trying 10.10.10.11...
Connected to b.domain.com.
Escape character is '^]'.
220-mail.domain.com ESMTP Exim 4.69 #1 Thu, 03 Dec 2009 09:31:46 +0100 
220-We do not authorize the use of this system to transport unsolicited, 
220 and/or bulk e-mail.
quit
221 mail.domain.com closing connection
Connection closed by foreign host.
This is a problem because no matter any subdomain you do a helo to,
you get mail.domain.com in response which is system's hostname.
What I want is if someone does a helo to for example a.domain.com then it should be shown

Quote:
220-a.domain.com ESMTP Exim 4.69 ...
not the system's hostname ...

Because now if you do helo to any of my subdomains or domains my mailserver shows system's hostname (mail.domain.com) as it's name.


In exim.conf if I set primary_hostname to for example xyz.domain.com then if you helo to any subdomains then my mailserver shows (xyz.domain.com) as it's name.

But I really want exim to dynamically show domain/subdomain which is being heloed.

e.g ... if I do "telnet c.domain.com 25"
then I should be shown
Code:
220 - c.domain.com ESMTP Exim 4.69 ...
quit
221 c.domain.com closing connection
Connection closed by foreign host.
and if I do "telnet b.domain.com 25"
then I should be shown
Code:
220 - b.domain.com ESMTP Exim 4.69 ...
quit
221 b.domain.com closing connection
Connection closed by foreign host.

The transport configuration in exim.conf if following
Code:
begin transports

remote_smtp:
  driver = smtp
  interface = ${if exists {/etc/mailips}{${lookup{$sender_address_domain}lsearch*{/etc/mailips}{$value}{}}}{}}
  helo_data = ${if exists {/etc/mailhelo}{${lookup{$sender_address_domain}lsearch*{/etc/mailhelo}{$value}{$primary_hostname}}}{$primary_hostname}}


dk_remote_smtp:
  driver = smtp
  interface = ${if exists {/etc/mailips}{${lookup{$sender_address_domain}lsearch*{/etc/mailips}{$value}{}}}{}}
  helo_data = ${if exists {/etc/mailhelo}{${lookup{$sender_address_domain}lsearch*{/etc/mailhelo}{$value}{$primary_hostname}}}{$primary_hostname}}
  dk_private_key = "/var/cpanel/domain_keys/private/${dk_domain}"
  dk_canon = nofws
  dk_selector = default
I hope you've got the picture and looking forward to your help.

Thanks

Last edited by kingkashif; 12-03-2009 at 04:49 AM.
 
Old 12-07-2009, 03:27 PM   #2
kingkashif
Member
 
Registered: May 2009
Posts: 94

Original Poster
Rep: Reputation: 16
anyone please ?
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Getting things straight: Apache, SSL, Multiple External IPs / Internal IPs robin.com.au Linux - Server 21 10-13-2007 11:39 PM
Etch + exim4 + sa-exim: sa-exim is not loading Thalagyrt Debian 0 04-18-2007 10:12 AM
how to define a specific range of IPs and/or multiple IPs in an iptables rule?... TheHellsMaster Linux - Security 9 09-20-2004 10:06 AM
exim is failed !!! error:package exim is not installed apache Linux - Software 0 06-24-2004 05:55 AM
Networking questions : Setting up domains/vhosts/subdomains/IPs etc. Belize Linux - Networking 1 09-16-2003 03:39 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 08:22 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration