summaryrefslogtreecommitdiff
path: root/modules/extra/m_ldap_authentication.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'modules/extra/m_ldap_authentication.cpp')
-rw-r--r--modules/extra/m_ldap_authentication.cpp8
1 files changed, 6 insertions, 2 deletions
diff --git a/modules/extra/m_ldap_authentication.cpp b/modules/extra/m_ldap_authentication.cpp
index 9f2550e69..1b8b36fb4 100644
--- a/modules/extra/m_ldap_authentication.cpp
+++ b/modules/extra/m_ldap_authentication.cpp
@@ -105,7 +105,7 @@ class IdentifyInterface : public LDAPInterface
{
na = new NickServ::Nick(ii->req->GetAccount(), new NickServ::Account(ii->req->GetAccount()));
na->last_realname = ii->user ? ii->user->realname : ii->req->GetAccount();
- NickServ::Event::OnNickRegister(&NickServ::Event::NickRegister::OnNickRegister, ii->user, na);
+ NickServ::Event::OnNickRegister(&NickServ::Event::NickRegister::OnNickRegister, ii->user, na, ii->req->GetPassword());;
BotInfo *NickServ = Config->GetClient("NickServ");
if (ii->user && NickServ)
ii->user->SendMessage(NickServ, _("Your account \002%s\002 has been successfully created."), na->nick.c_str());
@@ -311,7 +311,11 @@ class NSIdentifyLDAP : public Module
}
}
+<<<<<<< HEAD
void OnNickRegister(User *, NickServ::Nick *na) override
+=======
+ void OnNickRegister(User *, NickAlias *na, const Anope::string &pass) anope_override
+>>>>>>> 2.0
{
if (!this->disable_register_reason.empty() || !this->ldap)
return;
@@ -337,7 +341,7 @@ class NSIdentifyLDAP : public Module
}
attributes[3].name = this->password_attribute;
- attributes[3].values.push_back(na->nc->pass);
+ attributes[3].values.push_back(pass);
Anope::string new_dn = username_attribute + "=" + na->nick + "," + basedn;
this->ldap->Add(&this->orinterface, new_dn, attributes);