Uploaded image for project: 'James Server'
  1. James Server
  2. JAMES-1703

Can't receive email with Ldap UserRepository

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Blocker
    • Resolution: Not A Bug
    • Affects Version/s: 3.0.0-beta5
    • Fix Version/s: None
    • Labels:
      None
    • Environment:
      Windows server 2008 R2, Java version 1.7.0_75, Microsoft Windows Server AD-LDS
    • Flags:
      Important

      Description

      When using an Ldap user repository, James Server fail to validate email as a local user and throw the email to "adress-error" folder.

      First, I guess LDAP is correctly configured since I can successfully authenticate to the mailbox in pop3 with my AD account.
      Moreover, it works fine when I'm using jpa user repository.

      Here are some parts of my configs :

      userrepository.xml
      <repository name="LocalUsers" principal="CN=james_user,CN=Applications,CN=Annuaire,DC=MYORG,DC=COM" credentials="secret" class="org.apache.james.user.ldap.ReadOnlyUsersLDAPRepository" ldapHost="LDAP://myldapserver:389" userBase="CN=Annuaire,DC=MYORG,DC=COM" userIdAttribute="uid" userObjectClass="user" >
      <UsersDomain>mydomain.com</UsersDomain>
      <restriction memberAttribute="member">
      <group>CN=Users,CN=Roles,CN=Annuaire,DC=MYORG,DC=COM</group>
      </restriction>
      </repository>


      smtpserver.xml:

      • authRequired = true
      • verifyIdentity = false (if true, smtp connection is refused)

      I have 2 users on my LDAP, with email in uid and email LDAP attributes :

      • user1@mydomain.com
      • user2@mydomain.com

      I try to send an email from user1@mydomain.com to user2@mydomain.com

      My issue : James server don't find the user.
      Stacktrace :

      INFO 17:57:58,339 | james.smtpserver | Id='32422052' User='' Connection established from 10.1.2.249
      INFO 17:57:59,356 | james.smtpserver | Id='32422052' User='' Successfully spooled mail Mail1457456279340-e62611b4-ee36-4ec8-bd30-347a8e0e79bb from user1@mydomain.com on swl-stedev-bts4/10.1.1.1 for [user2@mydomain.com]
      [...]
      INFO 17:58:12,994 | james.mailetcontext | Storing mail Mail1457456279340-e62611b4-ee36-4ec8-bd30-347a8e0e79bb in file://var/mail/address-error/

      James also try to find a DSN from postmaster to user1 : this email also fail into address-error.

      Moreover, I have two James server that communicates together. If I send an email from my second server (that is configured with JPA userrepository), I can receive the DSN failure with this message :

      We were unable to deliver the attached message because of an error in the mail server.

      Error message below:
      550 - Requested action not taken: no such user here

      Is it a configuration problem or is there a real problem with LDAP connector ?

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              henrick.pupin@gmail.com Henrick PUPIN
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: