diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/account-server/accounthandler.cpp | 5 | ||||
-rw-r--r-- | src/common/manaserv_protocol.h | 2 |
2 files changed, 5 insertions, 2 deletions
diff --git a/src/account-server/accounthandler.cpp b/src/account-server/accounthandler.cpp index a59e1aa1..2e4e5c04 100644 --- a/src/account-server/accounthandler.cpp +++ b/src/account-server/accounthandler.cpp @@ -134,6 +134,7 @@ private: std::string mUpdateHost; std::string mDataUrl; + std::string mStellarLoginUrl; using IPsToTime = std::map<int, time_t>; IPsToTime mLastLoginAttemptForIP; @@ -154,7 +155,8 @@ AccountHandler::AccountHandler(const std::string &attributesFile): mMaxCharacters(Configuration::getValue("account_maxCharacters", 3)), mRegistrationAllowed(Configuration::getBoolValue("account_allowRegister", true)), mUpdateHost(Configuration::getValue("net_defaultUpdateHost", std::string())), - mDataUrl(Configuration::getValue("net_clientDataUrl", std::string())) + mDataUrl(Configuration::getValue("net_clientDataUrl", std::string())), + mStellarLoginUrl(Configuration::getValue("net_stellarLoginUrl", std::string())) { XML::Document doc(attributesFile); xmlNodePtr node = doc.rootNode(); @@ -392,6 +394,7 @@ void AccountHandler::handleStellarLoginMessage(AccountClient &client, MessageIn reply.writeInt8(ERRMSG_OK); reply.writeString(client.stellarToken); + reply.writeString(mStellarLoginUrl + "?token=" + client.stellarToken); client.send(reply); } diff --git a/src/common/manaserv_protocol.h b/src/common/manaserv_protocol.h index 77b8e5ac..7d5c694f 100644 --- a/src/common/manaserv_protocol.h +++ b/src/common/manaserv_protocol.h @@ -80,7 +80,7 @@ enum { PAMSG_LOGIN_RNDTRGR = 0x0015, // S username APMSG_LOGIN_RNDTRGR_RESPONSE = 0x0016, // S random seed PAMSG_STELLAR_LOGIN = 0x0017, // D version - APMSG_STELLAR_LOGIN_RESPONSE = 0x0018, // B error, S token + APMSG_STELLAR_LOGIN_RESPONSE = 0x0018, // B error, S token, S url PAMSG_CHAR_CREATE = 0x0020, // S name, B hair style, B hair color, B gender, B slot, {W stats}* APMSG_CHAR_CREATE_RESPONSE = 0x0021, // B error, on success: B slot, S name, B gender, B hair style, B hair color, // W character points, W correction points, B amount of items equipped, |