Hi there,
i would like to provide xmpp services for two domains where the authentication method is the same.
verification is done against ldap - mail attribute which is the same for all domains.
i've configured ejabberd as follows:
{hosts, ["domain.tld1", "domain.tld2"]}.
{host_config, "domain.tld1", [
{auth_method, ldap},
{ldap_servers, ["x.y.z.c"]},
{ldap_base, "ou=users,dc=domain,dc=tld1"},
{ldap_uids, [{"mail", "%u@domain.tld1"}]},
{ldap_filters, "{memberOf=*)"}]}.
{host_config, "domain.tld2", [
{auth_method, ldap},
{ldap_servers, ["x.y.z.c"]},
{ldap_base, "ou=users,dc=domain,dc=tld1"},
{ldap_uids, [{"mail", "%u@domain.tld1"}]},
{ldap_filters, "{memberOf=*)"}]}.
authentication is successful for the domain.tld1: if i use JID in the form 'username@domain.tld1', i am logged in.
i would like to set up authentication in second domain like this:
1. if jid is username@domain.tld2, verify mail attribute username@domain.tld1. problem is that if i use JID in the form 'username@domain.tld2', authentication is failed.
ejabberd debug mode:
successful authentication for domain.tld1:
=INFO REPORT==== 2009-05-18 16:27:25 ===
D(<0.256.0>:eldap:593) : {searchRequest,
{'SearchRequest',"ou=users,dc=domain,dc=tld1",
wholeSubtree,neverDerefAliases,0,0,false,
{equalityMatch,
{'AttributeValueAssertion',"mail",
"username@domain.tld1"}},
[]}}
=INFO REPORT==== 2009-05-18 16:27:25 ===
D(<0.256.0>:eldap:654) : {searchResEntry,
{'SearchResultEntry',
"here is valid DN of record",
failed authentication for domain.tld2:
=INFO REPORT==== 2009-05-18 16:29:34 ===
D(<0.714.0>:eldap:593) : {searchRequest,
{'SearchRequest',"ou=users,dc=domain,dc=tld1",
wholeSubtree,neverDerefAliases,0,0,false,
{equalityMatch,
{'AttributeValueAssertion',"mail",
"username@domain.tld1"}},
[]}}
=INFO REPORT==== 2009-05-18 16:29:34 ===
D(<0.714.0>:eldap:654) : {searchResDone,
{'LDAPResult',operationsError,[],
.....
asn1_NOVALUE}}
Any idea how to solve it?
Thanks in advance.
Re: LDAP backend failed
In both snippets there are exactly the same requests but different responses. How it is possible?
Re: Re: LDAP backend failed
Exactly. Same requests but different responses.
That is the reason why it is not working.
I could provide more info from logs if it is required.
I have no idea how to solve it.
Re: LDAP backend failed
I could provide more info from logs if it is required.
It is not necessary. This is definitely not ejabberd problem: ejabberd doesn't reply on requests it sends.