Uploaded image for project: 'ejabberd development'
  1. ejabberd development
  2. EJAB-1557

Extending mod_vcard_ldap to cell (mobile) attribute

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Major
    • Resolution: Won't Fix
    • Affects Version/s: ejabberd 2.1.10
    • Fix Version/s: None
    • Component/s: Config, LDAP, Shared rosters, vCard
    • Environment:
      CentOS GNU/Linux 6.2 x86_64 vs Windows Server Std 2008r2 AD

      Description

      Extending mod_vcard_ldap to parse LDAP:mobile attribute into <TEL><HOME><CELL><NUMBER>
      Just added new sections into mod_vcard_ldap.erl:
      -define(VCARD_MAP,
      ...

      {"CELL", "%s", ["mobile"]},
      ...
      -define(SEARCH_REPORTED,
      ...
      {"Telephone Soft", "TEL"},
      {"Telephone Mobile", "CELL"},
      ...
      ldap_attribute_to_vcard(vCard, {"cell", Value}) ->
      {xmlelement,"TEL",[],[{xmlelement,"HOME",[],[]},
      {xmlelement,"CELL",[],[]},
      {xmlelement,"NUMBER",[],[{xmlcdata,Value}]}]};

      , recompiled it.
      Added new conf variable:

      {mod_vcard_ldap,[
      {host, "users.@HOST@"},
      {ldap_vcard_map,[
      ...

      {"TEL", "%s", ["telephoneNumber"]},
      {"CELL", "%s", ["mobile"]}

      ...
      here an example: http://mitroko.com/media/src/erl/mod_vcard_ldap.erl

        Activity

        Hide
        d.k.brazz Denis Kurochkin added a comment -

        New attributes in mod_vcard_ldap

        CELL - work cell
        HOMETEL, HOMECELL - home numbers
        NOTE - additional text note
        PHOTOEXT - external link to photo:

        <PHOTO>
            <EXTVAL>http://me.stpeter.im/images/stpeter_oscon.jpg</EXTVAL>
        </PHOTO>
        Show
        d.k.brazz Denis Kurochkin added a comment - New attributes in mod_vcard_ldap CELL - work cell HOMETEL, HOMECELL - home numbers NOTE - additional text note PHOTOEXT - external link to photo: <PHOTO> <EXTVAL> http://me.stpeter.im/images/stpeter_oscon.jpg </EXTVAL> </PHOTO>
        Hide
        neustradamus Neustradamus added a comment -

        +1 for add this in 2.1.12 and master.

        Show
        neustradamus Neustradamus added a comment - +1 for add this in 2.1.12 and master.

          People

          • Votes:
            2 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:
              Start Date:

              Development