issues with domains with wildcard MX

classic Classic list List threaded Threaded
8 messages Options
Reply | Threaded
Open this post in threaded view
|

issues with domains with wildcard MX

Saurabh Bathe
Hi,

I am looking for a config option for Postfix that is similar to Sendmail
  option HasWildcardMX.

What HasWildcardMX does in sendmail?
It tells sendmail that we have a wildcard MX. So, use res_query()*
instead of res_search() to resolve the MX.

I tried looking at Postfix source and see no mention for res_query at
all. So, is there a way to configure Postfix so that it knows the
original domain does not resolve and it should just bounce/reject the
email ?

* man resolver

TIA
Saurabh

PS: Sorry for putting a sendmail/postfix comparison kind of question.
But there is no way for to put this question in other words for someone
who has grown up on sendmail and is just getting used to postfix elegance.
Reply | Threaded
Open this post in threaded view
|

Re: issues with domains with wildcard MX

Ralf Hildebrandt
* Saurabh Bathe <[hidden email]>:
> Hi,
>
> I am looking for a config option for Postfix that is similar to Sendmail  
> option HasWildcardMX.

http://www.arschkrebs.de/postfix/postfix_wildcard_mx.shtml

--
Ralf Hildebrandt ([hidden email])          [hidden email]
Postfix - Einrichtung, Betrieb und Wartung       Tel. +49 (0)30-450 570-155
http://www.arschkrebs.de
When the government outlaws cryptography, bayl pevzvanyf jvyy unir
cevinpl.
Reply | Threaded
Open this post in threaded view
|

Re: issues with domains with wildcard MX

Victor Duchovni
In reply to this post by Saurabh Bathe
On Fri, Jun 06, 2008 at 06:10:49PM +0530, Saurabh Bathe wrote:

> I am looking for a config option for Postfix that is similar to Sendmail
>  option HasWildcardMX.

No such option is necessary in Postfix. Postfix address rewriting will
behave correctly even when wildcard MX records are present. Postfix
MX host selection will behave correctly even when wildcard MX records
are present.

--
        Viktor.

Disclaimer: off-list followups get on-list replies or get ignored.
Please do not ignore the "Reply-To" header.

To unsubscribe from the postfix-users list, visit
http://www.postfix.org/lists.html or click the link below:
<mailto:[hidden email]?body=unsubscribe%20postfix-users>

If my response solves your problem, the best way to thank me is to not
send an "it worked, thanks" follow-up. If you must respond, please put
"It worked, thanks" in the "Subject" so I can delete these quickly.
Reply | Threaded
Open this post in threaded view
|

Re: issues with domains with wildcard MX

Saurabh Bathe
In reply to this post by Ralf Hildebrandt
Ralf Hildebrandt wrote:
> * Saurabh Bathe <[hidden email]>:
>> Hi,
>>
>> I am looking for a config option for Postfix that is similar to Sendmail  
>> option HasWildcardMX.
>
> http://www.arschkrebs.de/postfix/postfix_wildcard_mx.shtml
>

Thank you for the suggestion.
Will check that out.

--Saurabh

Reply | Threaded
Open this post in threaded view
|

Re: issues with domains with wildcard MX

Saurabh Bathe
In reply to this post by Ralf Hildebrandt
Ralf Hildebrandt wrote:
> * Saurabh Bathe <[hidden email]>:
>> Hi,
>>
>> I am looking for a config option for Postfix that is similar to Sendmail  
>> option HasWildcardMX.
>
> http://www.arschkrebs.de/postfix/postfix_wildcard_mx.shtml
>
OK, this looks like it is for something that bases recipient checks on
sender address. This is not what I wanted. Let me try to put my
requirements in different words.

One of my clients has a wild card MX (as always, its a complicated
setup, and I would not really not like to write an assay describing that
unless absolutely required). Now whenever I try to send an email to lets
say [hidden email], postfix does a MX query for the domain,
fails, does a query for unresolvable.domain.my.domain. This succeeds. I
do not want that to happen. I dont want postfix to even do a MX query
for unresolvable.domain.my.domain. Is that in some way possible?

Thanks,
Saurabh


Reply | Threaded
Open this post in threaded view
|

Re: issues with domains with wildcard MX

Wietse Venema
Saurabh Bathe:
[ Charset UTF-8 unsupported, converting... ]

> Ralf Hildebrandt wrote:
> > * Saurabh Bathe <[hidden email]>:
> >> Hi,
> >>
> >> I am looking for a config option for Postfix that is similar to Sendmail  
> >> option HasWildcardMX.
> >
> > http://www.arschkrebs.de/postfix/postfix_wildcard_mx.shtml
> >
> OK, this looks like it is for something that bases recipient checks on
> sender address. This is not what I wanted. Let me try to put my
> requirements in different words.
>
> One of my clients has a wild card MX (as always, its a complicated
> setup, and I would not really not like to write an assay describing that
> unless absolutely required). Now whenever I try to send an email to lets
> say [hidden email], postfix does a MX query for the domain,
> fails, does a query for unresolvable.domain.my.domain. This succeeds. I
> do not want that to happen. I dont want postfix to even do a MX query
> for unresolvable.domain.my.domain. Is that in some way possible?

Postfix actually turns off RES_DNSRCH (and RES_DEFNAMES) on MX
lookups, but perhaps some helpful Linux maintainer has "improved"
Postfix.

        Wietse
Reply | Threaded
Open this post in threaded view
|

Re: issues with domains with wildcard MX

Wietse Venema
Wietse Venema:

> Saurabh Bathe:
> [ Charset UTF-8 unsupported, converting... ]
> > Ralf Hildebrandt wrote:
> > > * Saurabh Bathe <[hidden email]>:
> > >> Hi,
> > >>
> > >> I am looking for a config option for Postfix that is similar to Sendmail  
> > >> option HasWildcardMX.
> > >
> > > http://www.arschkrebs.de/postfix/postfix_wildcard_mx.shtml
> > >
> > OK, this looks like it is for something that bases recipient checks on
> > sender address. This is not what I wanted. Let me try to put my
> > requirements in different words.
> >
> > One of my clients has a wild card MX (as always, its a complicated
> > setup, and I would not really not like to write an assay describing that
> > unless absolutely required). Now whenever I try to send an email to lets
> > say [hidden email], postfix does a MX query for the domain,
> > fails, does a query for unresolvable.domain.my.domain. This succeeds. I
> > do not want that to happen. I dont want postfix to even do a MX query
> > for unresolvable.domain.my.domain. Is that in some way possible?
>
> Postfix actually turns off RES_DNSRCH (and RES_DEFNAMES) on MX
> lookups, but perhaps some helpful Linux maintainer has "improved"
> Postfix.

Bogus hostnames may also be found when the "smtp_host_lookup"
parameter settting includes "native".

        Wietse
Reply | Threaded
Open this post in threaded view
|

Re: issues with domains with wildcard MX

Wietse Venema
In reply to this post by Saurabh Bathe
Saurabh Bathe:

> > > lookups, but perhaps some helpful Linux maintainer has "improved"
> > > Postfix.
> >
> > Bogus hostnames may also be found when the "smtp_host_lookup"
> > parameter settting includes "native".
>
> Well, that still might not change anything for me.
> In postfix-2.5.1/src/dns/dns_lookup.c, I do not see postfix making a call
> for res_query ever (only res_search), so I think you are right, someone did
> improve Postfix :)

Postfix from postfix.org invokes res_search() but it temporarily
removes RES_DEFNAMES etc. from the resolver flags. But someone may
have added it back. In that case, you should be able to see this
in either dns_lookup.c, or in the Postfix SMTP client code.

> Do you people think a feature request (or a bugfix) would be in place?
> Maybe an addition of an option to toggle between res_query and res_search?

If someone "improves" Postfix, it would be nice if they informed
the upstream release. If people really need RES_DEFNAMES behavior
then it should be made configurable instead of hard-coded.

        Wietse