diff options
| author | Shauren <shauren.trinity@gmail.com> | 2014-06-08 15:34:24 +0200 |
|---|---|---|
| committer | Shauren <shauren.trinity@gmail.com> | 2014-06-08 15:34:24 +0200 |
| commit | 9f69eda67f7fad50553f8d569851a5005437e677 (patch) | |
| tree | b918ef48a31a1970aad165808be344cf4744ef26 /src/server/authserver/Server | |
| parent | 05c0524bf3d97ba29496fa13e93acd3b8d7d37a4 (diff) | |
Core/Battle.net: Additional checks
* Force grunt login for versions < 15595
* Force bn login if supported and game account is linked to bn account
Diffstat (limited to 'src/server/authserver/Server')
| -rw-r--r-- | src/server/authserver/Server/AuthSocket.cpp | 4 | ||||
| -rw-r--r-- | src/server/authserver/Server/BattlenetSocket.cpp | 8 |
2 files changed, 9 insertions, 3 deletions
diff --git a/src/server/authserver/Server/AuthSocket.cpp b/src/server/authserver/Server/AuthSocket.cpp index 32140f76ba4..7ca49b03b56 100644 --- a/src/server/authserver/Server/AuthSocket.cpp +++ b/src/server/authserver/Server/AuthSocket.cpp @@ -480,7 +480,9 @@ bool AuthSocket::_HandleLogonChallenge() unk3.SetRand(16 * 8); // Fill the response packet with the result - if (AuthHelper::IsAcceptedClientBuild(_build)) + if (fields[9].GetUInt32() && AuthHelper::IsBuildSupportingBattlenet(_build)) + pkt << uint8(WOW_FAIL_USE_BATTLENET); + else if (AuthHelper::IsAcceptedClientBuild(_build)) pkt << uint8(WOW_SUCCESS); else pkt << uint8(WOW_FAIL_VERSION_INVALID); diff --git a/src/server/authserver/Server/BattlenetSocket.cpp b/src/server/authserver/Server/BattlenetSocket.cpp index eb8dc1158f0..4ee3c8e9b3d 100644 --- a/src/server/authserver/Server/BattlenetSocket.cpp +++ b/src/server/authserver/Server/BattlenetSocket.cpp @@ -107,7 +107,6 @@ void Battlenet::Socket::_SetVSFields(std::string const& pstr) bool Battlenet::Socket::HandleAuthChallenge(PacketHeader& header, BitStream& packet) { - // Verify that this IP is not in the ip_banned table LoginDatabase.Execute(LoginDatabase.GetPreparedStatement(LOGIN_DEL_EXPIRED_IP_BANS)); @@ -160,7 +159,12 @@ bool Battlenet::Socket::HandleAuthChallenge(PacketHeader& header, BitStream& pac else if (!sBattlenetMgr->HasPlatform(component.Platform)) complete.SetAuthResult(AUTH_INVALID_OS); else - complete.SetAuthResult(AUTH_REGION_BAD_VERSION); + { + if (component.Program != "WoW" || AuthHelper::IsBuildSupportingBattlenet(component.Build)) + complete.SetAuthResult(AUTH_REGION_BAD_VERSION); + else + complete.SetAuthResult(AUTH_USE_GRUNT_LOGON); + } Send(complete); return true; |
