ejabberd - Comments for "mod_shared_roster_ldap" https://www.ejabberd.im/node/5039 en Yes, if you enable level 5 https://www.ejabberd.im/node/5039#comment-58007 <p>Yes, if you enable level 5 logging, then you will see entries like</p> <div class="codeblock"><code>=INFO REPORT==== 4-Aug-2011::09:31:54 ===<br />D(&lt;0.286.0&gt;:eldap:675) : {searchRequest,<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; {&#039;SearchRequest&#039;,<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &quot;OU=SomeOU,DC=example,DC=com&quot;,<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; wholeSubtree,neverDerefAliases,0,0,false,<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; {equalityMatch,<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; {&#039;AttributeValueAssertion&#039;,&quot;sOMEAttributeNameHere&quot;,<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &quot;value&quot;}},<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; [&quot;sOMEAttributeNameHere&quot;]}}</code></div> <p>and zero or more</p> <div class="codeblock"><code>=INFO REPORT==== 4-Aug-2011::09:31:54 ===<br />D(&lt;0.286.0&gt;:eldap:746) : {searchResEntry,<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; {&#039;SearchResultEntry&#039;,<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &quot;CN=SomeCN,OU=SomeOU,DC=example,DC=com&quot;,<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; [{&#039;PartialAttributeList_SEQOF&#039;,<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &quot;sOMEAttributeNameHere&quot;,<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; [&quot;value&quot;]}]}}</code></div> <p>after which you will see</p> <div class="codeblock"><code>=INFO REPORT==== 4-Aug-2011::09:31:54 ===<br />D(&lt;0.286.0&gt;:eldap:746) : {searchResDone,<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; {&#039;LDAPResult&#039;,success,[],[],asn1_NOVALUE}}</code></div> <p>This is the representation of LDAP query with filter "(sOMEAttributeNameHere=value)" that is run against whole subtree of OU=SomeOU,DC=example,DC=com, and asking server to return attribute sOMEAttributeNameHere in returned objects.</p> <p>You may see complex filters as multiple "equalityMatch", "extensibleMatch", "approxMatch", and so on, or'ed or and'ed together.</p> <p>However, you will find out that you are unable to construct a config that shows you members of an AD group in a shared roster. This is a inherent limitation of the vanilla mod_shared_roster_ldap. You will need to group those users by some their common attribute, or use a modified version of this module that is available at <noindex><a href="https://support.process-one.net/browse/EJAB-1480" rel="nofollow" >EJAB-1480</a></noindex>. That modified version allows much greater flexibility and (I hope) much clearer configuration.</p> Tue, 08 Nov 2011 01:04:21 +0000 mikekaganski comment 58007 at https://www.ejabberd.im Ahh, your totally right, I've https://www.ejabberd.im/node/5039#comment-58004 <p>Ahh, your totally right, I've probably changed my config like a hundred times and just noticed this when leaving the rfilter out. So the problem really is my config, I've been reading the documentation and changing my config over and over and just can't get the roster to show correctly. Is there a way to see what queries the module is throwing at my AD servers? Again i set logging to 5 adn have paged through but don't see it listed anywhere.</p> <p>My config:<br /> {mod_shared_roster_ldap, [<br /> {ldap_base, "ou=chat,dc=domain,dc=com"},<br /> {ldap_rfilter, "(objectClass=group)"},<br /> {ldap_gfilter, "(objectClass=group)"},<br /> {ldap_groupdesc, "description"},<br /> {ldap_memberattr, "member"},<br /> {ldap_userdesc, "displayName"}<br /> ]}, %%mod_shared_roster_ldap</p> <p>in my chat OU I have a group with the members in it that I would like in that group. I must admit though the ufilter and mbmerattr_format are a bit confusing to me, it would be extremely helpful if i could see the queries.</p> Mon, 07 Nov 2011 14:19:39 +0000 bburress comment 58004 at https://www.ejabberd.im There already was a report of https://www.ejabberd.im/node/5039#comment-57993 <p>There already was a report of (supposedly) same problem: <a href="http://www.ejabberd.im/node/4243" title="http://www.ejabberd.im/node/4243">http://www.ejabberd.im/node/4243</a>. Unfortunately, then it was unanswered.</p> <p>I must admit it that I was overly confident. Everything relevant already was in your first post.<br /> The problem <strong>is</strong> caused by incorrect configuration. You didn't specify ldap_rfilter parameter in your config. Thus it had the value "undefined", and erlang just couldn't find a version of eldap_filter:parse (erlang calls it "function clause") that would accept this value.<br /> Unfortunately, the vanilla version of this module doesn't show a sensible error message in this case.</p> <p>So, if you will define it, you will bypass this problem, and after that you will need to fix other options to make it work. You may ask here if you will need help, but first be sure that you have read the <noindex><a href="http://www.process-one.net/docs/ejabberd/guide_en.html" rel="nofollow" >ejabberd Installation and Operation Guide</a></noindex>. The bundled version of mod_shared_roster_ldap is <noindex><a href="http://www.process-one.net/docs/ejabberd/guide_en.html#htoc62" rel="nofollow" >covered there</a></noindex> in full detail.</p> <p>Hope this helps.</p> Sat, 05 Nov 2011 13:11:11 +0000 mikekaganski comment 57993 at https://www.ejabberd.im OpenSuse 11.4 Ejabberd https://www.ejabberd.im/node/5039#comment-57992 <p>OpenSuse 11.4<br /> Ejabberd 2.1.9<br /> PostgreSQL 9.0.3<br /> Binary installer<br /> mod_shared_roster_ldap was packaged</p> <p>I've tried setting the log level to 5 and capturing more information that way, but nothing is present about the error when I do that.</p> Fri, 04 Nov 2011 12:26:03 +0000 bburress comment 57992 at https://www.ejabberd.im This error tells that erlang https://www.ejabberd.im/node/5039#comment-57991 <p>This error tells that erlang cannot find the function "eldap_filter:parse". This problem is reported when ejabberd tries to get subscription lists for this user, and when it needs to build this user's roster. Both times the problem is, as you correctly pointed out, in mod_shared_roster_ldap.</p> <p>What is your OS? What version of ejabberd do you use? How was it installed (binary installer or compiled from source)? How the faulty module was installed (was it the bundled version, or did you use some other source)? Why don't people seeking for help never pay attention to the common rules of reporting errors? This is impolite!</p> <p>By the way, your config isn't right, it won't work, but the problem you report isn't caused by your config.</p> Thu, 03 Nov 2011 23:37:20 +0000 mikekaganski comment 57991 at https://www.ejabberd.im