Le 18/02/2011 02:51, Hugo Monteiro a écrit :
On 02/17/2011 09:21 PM, tux45 wrote:
Hi,

We are using ldap to check if mailbox exists and to authenticate users on dspam 
webfronted.
A lot of users have two or three differents mail addresses (alternate address) 
always with the same domain!!

The problem is dspam always takes the second mail address intead of the first 
one to register in Quarantine.

Example :
Fist mail address : t...@domain.com
and the alternate : t...@domain.com
Dspam use the second one to register (t...@domain.com) in the database (mysql) 
and never use the first (t...@domain.com).

In our ldap server, the mail addresses are ordered very well.

Does anyone have any idea ??

Bests regards from France.

Vincent

DSPAM version : 3.9.1
DEDIAN SQUEEZE 6.0

Here the extlookup.conf file :

ExtLookup               on                              # Turns on/off external 
lookup
ExtLookupMode           strict                          # available modes are 
'verify', 'map' and 'strict'.
                                                           # 'strict' enforces 
both verify and map
ExtLookupDriver         ldap                            # Currently only ldap 
and program are supported.
                                                           # There are plans to 
support both MySQL and Postgres.
ExtLookupServer         directory.cire.fr                       # Can either be 
a database hostname or the full path to
                                                           # an executable 
lookup program and its arguments.
ExtLookupPort           389                             # Desired port when 
connecting to the lookup database.
ExtLookupDB             "ou=users,dc=cire.fr,dc=local"  # Can either be an LDAP 
search base or a database name (TODO).
ExtLookupQuery          "(&(objectClass=*)(|(mail=%u)(mailAlias=%u)))"  # Can 
either be an LDAP search filter or an SQL query (TODO)
ExtLookupLDAPAttribute  "mail"                          # Attribute to be used 
when ExtLookupDriver is 'ldap'
                                                           # and ExtLookupMode 
'map' or 'strict'
ExtLookupLDAPScope      base                            # Can be set to 'base', 
'sub' or 'one'. Only used when ExtLookupDriver is 'ldap'.
#ExtLookupLDAPVersion   3                               # Sets the LDAP 
protocol version (1, 2 or 3)
#ExtLookupLogin         "cn=admin,dc=domain,dc=com"     # Login to be used when 
connecting to any direct database backend.
#ExtLookupPassword      itsasecret                      # Password to use with 
ExtLookupLogin.
#ExtLookupCrypto        tls                             # Sets the use of TLS 
on backend communication (only compatible with LDAPv3)



You need to define the right attribute in the ExtlookupLDAPAttribute
directive. It must be a single valued attribute, and not necessarily an
attribute containing an email address.
In my case i use a custom attribute which holds a numeric code. My
suggestion would be to use the user login attribute.

Regards,

Hugo Monteiro.

Hi Hugo,

It's exactly that i would like to have !!! I changed ExtlookupLDAPAttribute :

ExtLookupLDAPAttribute  "*uid*"

And it works !!

Thank you very much Hugo !!!!!!!!!!

Regards,

Vincent
------------------------------------------------------------------------------
The ultimate all-in-one performance toolkit: Intel(R) Parallel Studio XE:
Pinpoint memory and threading errors before they happen.
Find and fix more than 250 security defects in the development cycle.
Locate bottlenecks in serial and parallel code that limit performance.
http://p.sf.net/sfu/intel-dev2devfeb
_______________________________________________
Dspam-user mailing list
Dspam-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/dspam-user

Reply via email to