Hi,

I'm trying to fetch attribute list with kamailio ldap_search:

ldap_search("ldap://agents/ou=Xxxxx,dc=xxxx,dc=yyyyyy,dc=zz?memberOf?sub?(sAMAccountName=$fU)");

ldap_result("memberOf/$avp(s:ldapmemberof1)");
xlog("L_INFO", "LDAP $fU memberOf = $avp(s:ldapmemberof1)");
if (ldap_result_next())
{
xlog("L_INFO", "if loop ldap_result");
           ldap_result("memberOf/$avp(s:ldapmemberof2)");
           xlog("L_INFO", "LDAP $fU memberOf = $avp(s:ldapmemberof2)");
}

There's must be seven returning attributes list of memberOf, but I can only retrieve only one of them (looks like last of seven). First xlog output log into my log file, but if loop didn't start. What I'm doing wrong?