OSEC

Neohapsis is currently accepting applications for employment. For more information, please visit our website www.neohapsis.com or email hr@neohapsis.com
 
Re: 2 ldap lookups instead of 1

From: John A. Kremlin (jonh.a.kremliniol.pt)
Date: Wed Dec 17 2003 - 11:02:15 CST


Hi again,

I'm still having this problem, but I activated ldap debug and got the unwanted ldap search:

(...)
Dec 17 16:38:36 postfix-machine postfix/smtpd[2623]: dict_ldap_debug: ldap_search
Dec 17 16:38:36 postfix-machine postfix/smtpd[2623]: dict_ldap_debug: put_filter: "(&(inactive=true)(mail=asdfasdfasdsomewhere.com))"
(...)
### Here is the unwanted ldap search, I didn't made this configuration...
Dec 17 16:38:36 postfix-machine postfix/smtpd[2623]: dict_ldap_debug: ldap_search
Dec 17 16:38:36 postfix-machine postfix/smtpd[2623]: dict_ldap_debug: put_filter: "(&(inactive=true)(mail=somewhere.com))"

It keeps searching the domain name... Any idea about this?

Thanks.

----- Mensagem Original -----
De: John A. Kremlin <jonh.a.kremliniol.pt>
Data: Quarta-Feira, 17 de Dezembro de 2003, 13:37
Assunto: 2 ldap lookups instead of 1

>
> Inside «main.cf» I defined the following:
> ###
> smtpd_sender_restrictions=check_sender_access,ldap:Ldapcfg,permit
> smtpd_recipient_restrictions=check_recipient_access,ldap:Ldapcfg,permit_mynetworks,reject_unauth_destination
>
> (...)
> Ldapcfg_query_filter = (&(inactive=true)(mail=%s))
> ###
>
>
> The problem exists in ldap lookups made by postfix...
>
> Lets imagine I use "somethingsomewhere.com" as «MAIL FROM» and
> "somethinganotherdomain.com" as «RCPT TO». Postfix looks up for:
> a) MAIL FROM:
> a.1) (&(inactive=true)(mail=somethingsomewhere.com))
> a.2) (&(inactive=true)(mail=somewhere.com))
>
> b)RCPT TO:
> b.1) (&(inactive=true)(mail=somethinganotherdomain.com))
> b.2) (&(inactive=true)(mail=anotherdomain.com))
>
> The a.2 and b.2 lookups weren't supose to happen. Can someone
> please explain why is this happening and how to avoid it?
>
> Thanks.
>
>
>