ejabberd LDAP shared roster not displaying full user names

37 Views Asked by At

I'm trying to configure ejabberd server with LDAP authentication and use shared roster with users and groups from LDAP. My config is like this:

auth_method: [ldap]
ldap_servers: [my.dc.address]
ldap_base: "OU=Departments,OU=Accounts,DC=my.dc,DC=address"
ldap_rootdn: "CN=user,OU=Service,OU=Accounts,DC=my.dc,DC=address"
ldap_password: "pass"
ldap_uids: [sAMAccountName]
ldap_filter: "(objectClass=user)"

...

  mod_roster:
    versioning: false
    store_current_id: false
  mod_shared_roster_ldap:
    ldap_rfilter: "(objectClass=user)"
    ldap_groupattr: department
    ldap_memberattr: cn
    ldap_userdesc: displayName
    ldap_auth_check : false
  mod_vcard:
    db_type: ldap
    ldap_vcard_map:
      NICKNAME: {"%s": [displayName]}
      EMAIL: {"%s": [mail]}
      TEL: {"%s": [telephoneNumber]}
      ORGUNIT: {"%s": [department]}
    ldap_search_fields:
      User: "%u"
      Name: displayName
      Email: mail
      Department: department
      Role: title
      Description: description
      Phone: telephoneNumber
    ldap_search_reported:
      Nickname: displayName
      Email: EMAIL

With that config, what I have now? Using Pidgin as client, I get properly formatted list of users, grouped by department as they should be. Each user is named as "first name patronymic last name", just like they should be. But, when I delete department group, roster recreates it like:

Right name of department

  • list of user JIDs, instead of "first name patronymic last name"

The only way to force rename them is to clear "roster" database from web admin and reconnect client. After that, client gets properly named records for this group. Is there any better way to automate or fix this?

0

There are 0 best solutions below