Uploaded image for project: 'PUBLIC - Liferay Portal Community Edition'
  1. PUBLIC - Liferay Portal Community Edition
  2. LPS-60644

If last name or emailAddress is not required, we shouldn't ask mapping these fields in LDAP setting



      1. Set up LDAP server and add a user in it with

      dn: cn=test1,ou=Users,dc=liferay,dc=com
      cn: test1
      givenName: test1
      objectClass: person
      objectClass: inetOrgPerson
      objectClass: organizationalPerson
      objectClass: top
      sn: test1
      userPassword:: e1NTSEF9dVplNG13WkV2ZVNVT3RrZlh0aW5iK0cyM0g0RjZib0EzNDNOVWc9PQ==

      (This is just a sample, we don't set mail)

      2. in portal-ext.properties, set


      in /liferay-portal/portal-impl/src/content/Language.propertiesLanguage.properties, set


      then run "ant build-lang" and "ant deploy" in /portal-impl. We want to set last name not required.

      3. Start portal. Go to control panel -> Configuration -> Portal Settings -> Authentication -> LDAP, check "Enable", "Enable Import".
      4. Go to control panel -> Configuration -> Portal Settings -> Authentication -> General -> "How do users authenticate?", select "By Screen Name"

      Please notice: as customer doesn't map for email address, so portal shouldn't use email address as users authenticate method. Because when do importing users, portal would do search for user with authenticate method as a searching condition. So please go to Control panel -> Configuration -> Portal Settings -> Authentication, "How do users authenticate?", change "By Email Address" to "By Screen Name". This is essential. If not doing this, portal would throw NPE because of no user is found.

      5. Add LDAP server, click Reset Values. Then click "Test LDAP Users". The user should be fetched.
      6. Remove Email Address or Last Name mapping.
      7. Then click "Test LDAP Users".

      Actual: It shows"Please map each of the user properties Screen Name, Password, Email Address, First Name, and Last Name to an LDAP attribute."
      Expect: The user should be fetched since email address and last name are not required.


          Issue Links



              • Assignee:
                beck.liu Beck Liu
                bejond.shao Bejond Shao (Inactive)
                Participants of an Issue:
                Recent user:
                Esther Sanz
              • Votes:
                0 Vote for this issue
                1 Start watching this issue


                • Created:
                  Days since last comment:
                  4 years, 12 weeks ago


                  Version Package
                  7.0.0 Alpha 4