aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorShauren <shauren.trinity@gmail.com>2015-10-10 20:19:41 +0200
committerShauren <shauren.trinity@gmail.com>2015-10-10 20:19:41 +0200
commitee2b43e368433f0451d8d3e49a4ba43d83c490ff (patch)
tree67c59f83ac4fea9727979072ddabffd1675a39ab /src
parent2e894d0f18773f862148f0c188f78a45b36f159f (diff)
Core/Battle.net: Updated packet enums and added new build data
Diffstat (limited to 'src')
-rw-r--r--src/server/bnetserver/Authentication/AuthCodes.cpp3
-rw-r--r--src/server/bnetserver/Packets/ChatPackets.h11
-rw-r--r--src/server/bnetserver/Packets/FriendsPackets.cpp32
-rw-r--r--src/server/bnetserver/Packets/FriendsPackets.h25
-rw-r--r--src/server/bnetserver/Packets/PacketManager.cpp23
-rw-r--r--src/server/bnetserver/Packets/SupportPackets.h4
6 files changed, 44 insertions, 54 deletions
diff --git a/src/server/bnetserver/Authentication/AuthCodes.cpp b/src/server/bnetserver/Authentication/AuthCodes.cpp
index a717263786e..e7ca768e637 100644
--- a/src/server/bnetserver/Authentication/AuthCodes.cpp
+++ b/src/server/bnetserver/Authentication/AuthCodes.cpp
@@ -24,6 +24,7 @@ namespace AuthHelper
// List of client builds for verbose version info in realmlist packet
static std::vector<RealmBuildInfo> const ClientBuilds =
{
+ { 20574, 6, 2, 2, 'a' },
{ 20490, 6, 2, 2, 'a' },
{ 15595, 4, 3, 4, ' ' },
{ 14545, 4, 2, 2, ' ' },
@@ -43,7 +44,7 @@ namespace AuthHelper
RealmBuildInfo const* GetBuildInfo(int build)
{
- for (int32 i = 0; ClientBuilds.size(); ++i)
+ for (int32 i = 0; i < ClientBuilds.size(); ++i)
if (ClientBuilds[i].Build == build)
return &ClientBuilds[i];
diff --git a/src/server/bnetserver/Packets/ChatPackets.h b/src/server/bnetserver/Packets/ChatPackets.h
index 333a07245ed..533fd1a6fc0 100644
--- a/src/server/bnetserver/Packets/ChatPackets.h
+++ b/src/server/bnetserver/Packets/ChatPackets.h
@@ -37,7 +37,7 @@ namespace Battlenet
CMSG_ENUM_CATEGORY_DESCRIPTIONS = 0x15, // Not implemented
CMSG_ENUM_CONFERENCE_DESCRIPTIONS = 0x17, // Not implemented
CMSG_ENUM_CONFERENCE_MEMBER_COUNTS = 0x19, // Not implemented
- CMSG_MODIFY_CHANNEL_LIST_REQUEST = 0x1B, // Not implemented
+ CMSG_MODIFY_CHANNEL_LIST_REQUEST = 0x1B, // Deprecated in client
CMSG_GET_MEMBER_COUNT_REQUEST = 0x1F, // Not implemented
CMSG_MODIFY_CHANNEL_LIST_REQUEST_2 = 0x20, // Not implemented
CMSG_GAME_DATA_SEND_REQUEST = 0x22, // Not implemented
@@ -57,8 +57,13 @@ namespace Battlenet
SMSG_CONFERENCE_DESCRIPTIONS = 0x18, // Not implemented
SMSG_CONFERENCE_MEMBER_COUNTS = 0x1A, // Not implemented
SMSG_JOIN_NOTIFY_2 = 0x1B, // Not implemented
- SMSG_MODIFY_CHANNEL_LIST_RESPONSE = 0x1C, // Not implemented
- SMSG_CONFIG_CHANGED = 0x1D // Not implemented
+ SMSG_MODIFY_CHANNEL_LIST_RESPONSE = 0x1C, // Deprecated in client
+ SMSG_CONFIG_CHANGED = 0x1D, // Not implemented
+ SMSG_WHISPER_ECHO_RECV = 0x1E, // Not implemented
+ SMSG_GET_MEMBER_COUNT_RESPONSE = 0x1F, // Not implemented
+ SMSG_MODIFY_CHANNEL_LIST_RESPONSE_2 = 0x21, // Not implemented
+ SMSG_GAME_DATA_SEND_RESPONSE = 0x23, // Not implemented
+ SMSG_GAME_DATA_RECV = 0x24 // Not implemented
};
}
}
diff --git a/src/server/bnetserver/Packets/FriendsPackets.cpp b/src/server/bnetserver/Packets/FriendsPackets.cpp
index 0f39241ebbf..631147d90f2 100644
--- a/src/server/bnetserver/Packets/FriendsPackets.cpp
+++ b/src/server/bnetserver/Packets/FriendsPackets.cpp
@@ -15,40 +15,8 @@
* with this program. If not, see <http://www.gnu.org/licenses/>.
*/
-#include "Session.h"
#include "FriendsPackets.h"
-std::string Battlenet::Friends::FriendInviteResult::ToString() const
-{
- return "Battlenet::Friends::RealIdFriendInviteResult";
-}
-
-void Battlenet::Friends::FriendInviteResult::Write()
-{
- bool hasNames = false;
- _stream.Write(hasNames, 1);
- if (hasNames)
- {
- _stream.WriteString("Testing1", 8);
- _stream.WriteString("Testing2", 8);
- }
- _stream.Write(5, 32);
-
- _stream.Write(0, 0xC); // Ignored
-
- _stream.Write(1, 16);
-
- bool moreInfo = true;
- _stream.Write(moreInfo, 1);
- if (moreInfo)
- {
- _stream.Write(0, 8);
- _stream.Write(4, 32);
- _stream.Write(3, 32);
- _stream.WriteString("Testing3", 7, 2);
- }
-}
-
void Battlenet::Friends::SendInvitationRequest::Read()
{
Token = _stream.Read<uint32>(32);
diff --git a/src/server/bnetserver/Packets/FriendsPackets.h b/src/server/bnetserver/Packets/FriendsPackets.h
index 463863d3063..4b3f3e600a6 100644
--- a/src/server/bnetserver/Packets/FriendsPackets.h
+++ b/src/server/bnetserver/Packets/FriendsPackets.h
@@ -44,15 +44,23 @@ namespace Battlenet
SMSG_FRIEND_INVITE_NOTIFY = 0x01, // Not implemented
SMSG_FRIEND_INVITE_RESULT = 0x03, // Not implemented
SMSG_TOONS_OF_FRIEND_NOTIFY = 0x06, // Not implemented
- SMSG_BLOCK_INVITE_NOTIFY = 0x07, // Not implemented
+ SMSG_BLOCK_INVITE_NOTIFY = 0x07, // Deprecated in client
SMSG_BLOCK_ADD_FAILURE = 0x09, // Not implemented
- SMSG_FRIENDS_OF_FRIEND = 0x0C, // Not implemented
+ SMSG_FRIENDS_OF_FRIEND = 0x0C, // Deprecated in client
SMSG_SOCIAL_NETWORK_FRIENDS = 0x0E, // Deprecated in client
SMSG_SOCIAL_NETWORK_CONNECT_RESULT = 0x10, // Deprecated in client
SMSG_SOCIAL_NETWORK_DISCONNECT_RESULT = 0x12, // Deprecated in client
SMSG_SOCIAL_NETWORK_CHECK_CONNECTED_RESULT = 0x14, // Deprecated in client
SMSG_MAX_FRIENDS_NOTIFY = 0x15, // Not implemented
- SMSG_FRIENDS_LIST_NOTIFY_3 = 0x18 // Not implemented
+ SMSG_FRIENDS_LIST_NOTIFY_3 = 0x18, // Deprecated in client
+ SMSG_SEND_INVITATION_RESULT = 0x1B, // Not implemented
+ SMSG_FRIEND_INVITATION_ADDED_NOTIFY = 0x1C, // Not implemented
+ SMSG_FRIEND_INVITATION_REMOVED_NOTIFY = 0x1D, // Not implemented
+ SMSG_FRIENDS_LIST_NOTIFY_5 = 0x1E, // Not implemented
+ SMSG_ACCOUNT_BLOCK_ADDED_NOTIFY = 0x1F, // Not implemented
+ SMSG_ACCOUNT_BLOCK_REMOVED_NOTIFY = 0x20, // Not implemented
+ SMSG_TOON_BLOCK_NOTIFY = 0x21, // Not implemented
+ SMSG_FRIENDS_OF_FRIEND_RESULT = 0x22 // Not implemented
};
class SendInvitationRequest final : public ClientPacket
@@ -76,17 +84,6 @@ namespace Battlenet
std::string Source;
uint32 Role;
};
-
- class FriendInviteResult final : public ServerPacket
- {
- public:
- FriendInviteResult() : ServerPacket(PacketHeader(SMSG_FRIEND_INVITE_RESULT, FRIENDS))
- {
- }
-
- void Write() override;
- std::string ToString() const override;
- };
}
}
diff --git a/src/server/bnetserver/Packets/PacketManager.cpp b/src/server/bnetserver/Packets/PacketManager.cpp
index 7fa5978a3b8..22ba372e600 100644
--- a/src/server/bnetserver/Packets/PacketManager.cpp
+++ b/src/server/bnetserver/Packets/PacketManager.cpp
@@ -82,13 +82,16 @@ void Battlenet::PacketManager::RegisterAuthenticationPackets()
REGISTER_CLIENT_PACKET_NAME(PacketHeader(Authentication::CMSG_LOGON_REQUEST, AUTHENTICATION), "Authentication::LogonRequest");
REGISTER_CLIENT_PACKET(PacketHeader(Authentication::CMSG_RESUME_REQUEST, AUTHENTICATION), Authentication::ResumeRequest);
REGISTER_CLIENT_PACKET(PacketHeader(Authentication::CMSG_PROOF_RESPONSE, AUTHENTICATION), Authentication::ProofResponse);
+ REGISTER_CLIENT_PACKET_NAME(PacketHeader(Authentication::CMSG_GENERATE_SINGLE_SIGN_ON_TOKEN_REQUEST_2, AUTHENTICATION), "Authentication::GenerateSingleSignOnTokenRequest2");
REGISTER_CLIENT_PACKET(PacketHeader(Authentication::CMSG_LOGON_REQUEST_3, AUTHENTICATION), Authentication::LogonRequest3);
+ REGISTER_CLIENT_PACKET_NAME(PacketHeader(Authentication::CMSG_SINGLE_SIGN_ON_REQUEST_3, AUTHENTICATION), "Authentication::SingleSignOnRequest3");
REGISTER_SERVER_PACKET(PacketHeader(Authentication::SMSG_LOGON_RESPONSE, AUTHENTICATION), Authentication::LogonResponse);
REGISTER_SERVER_PACKET(PacketHeader(Authentication::SMSG_RESUME_RESPONSE, AUTHENTICATION), Authentication::ResumeResponse);
REGISTER_SERVER_PACKET(PacketHeader(Authentication::SMSG_PROOF_REQUEST, AUTHENTICATION), Authentication::ProofRequest);
REGISTER_SERVER_PACKET_NAME(PacketHeader(Authentication::SMSG_PATCH, AUTHENTICATION), "Authentication::Patch");
REGISTER_SERVER_PACKET_NAME(PacketHeader(Authentication::SMSG_AUTHORIZED_LICENSES, AUTHENTICATION), "Authentication::AuthorizedLicenses");
+ REGISTER_SERVER_PACKET_NAME(PacketHeader(Authentication::SMSG_GENERATE_SINGLE_SIGN_ON_TOKEN_RESPONSE_2, AUTHENTICATION), "Authentication::GenerateSingleSignOnTokenResponse2");
}
void Battlenet::PacketManager::RegisterConnectionPackets()
@@ -135,12 +138,11 @@ void Battlenet::PacketManager::RegisterFriendsPackets()
REGISTER_CLIENT_PACKET_NAME(PacketHeader(Friends::CMSG_SOCIAL_NETWORK_CONNECT, FRIENDS), "Friends::SocialNetworkConnect");
REGISTER_CLIENT_PACKET_NAME(PacketHeader(Friends::CMSG_SOCIAL_NETWORK_DISCONNECT, FRIENDS), "Friends::SocialNetworkDisconnect");
REGISTER_CLIENT_PACKET_NAME(PacketHeader(Friends::CMSG_SOCIAL_NETWORK_CHECK_CONNECTED, FRIENDS), "Friends::SocialNetworkCheckConnected");
- REGISTER_CLIENT_PACKET_NAME(PacketHeader(Friends::CMSG_GET_FRIENDS_OF_FRIEND, FRIENDS), "Friends::GetFriendsOfFriend");
REGISTER_CLIENT_PACKET_NAME(PacketHeader(Friends::CMSG_REALID_FRIEND_INVITE, FRIENDS), "Friends::RealIdFriendInvite");
REGISTER_CLIENT_PACKET(PacketHeader(Friends::CMSG_SEND_INVITATION_REQUEST, FRIENDS), Friends::SendInvitationRequest);
REGISTER_SERVER_PACKET_NAME(PacketHeader(Friends::SMSG_FRIEND_INVITE_NOTIFY, FRIENDS), "Friends::FriendInviteNotify");
- REGISTER_SERVER_PACKET(PacketHeader(Friends::SMSG_FRIEND_INVITE_RESULT, FRIENDS), Friends::FriendInviteResult);
+ REGISTER_SERVER_PACKET_NAME(PacketHeader(Friends::SMSG_FRIEND_INVITE_RESULT, FRIENDS), "Friends::FriendInviteResult");
REGISTER_SERVER_PACKET_NAME(PacketHeader(Friends::SMSG_TOONS_OF_FRIEND_NOTIFY, FRIENDS), "Friends::ToonsOfFriendNotify");
REGISTER_SERVER_PACKET_NAME(PacketHeader(Friends::SMSG_BLOCK_INVITE_NOTIFY, FRIENDS), "Friends::BlockInviteNotify");
REGISTER_SERVER_PACKET_NAME(PacketHeader(Friends::SMSG_BLOCK_ADD_FAILURE, FRIENDS), "Friends::BlockAddFailure");
@@ -151,6 +153,14 @@ void Battlenet::PacketManager::RegisterFriendsPackets()
REGISTER_SERVER_PACKET_NAME(PacketHeader(Friends::SMSG_SOCIAL_NETWORK_CHECK_CONNECTED_RESULT, FRIENDS), "Friends::SocialNetworkCheckConnectedResult");
REGISTER_SERVER_PACKET_NAME(PacketHeader(Friends::SMSG_MAX_FRIENDS_NOTIFY, FRIENDS), "Friends::MaxFriendsNotify");
REGISTER_SERVER_PACKET_NAME(PacketHeader(Friends::SMSG_FRIENDS_LIST_NOTIFY_3, FRIENDS), "Friends::FriendsListNotify3");
+ REGISTER_SERVER_PACKET_NAME(PacketHeader(Friends::SMSG_SEND_INVITATION_RESULT, FRIENDS), "SendInvitationResult");
+ REGISTER_SERVER_PACKET_NAME(PacketHeader(Friends::SMSG_FRIEND_INVITATION_ADDED_NOTIFY, FRIENDS), "Friends::FriendInvitationAddedNotify");
+ REGISTER_SERVER_PACKET_NAME(PacketHeader(Friends::SMSG_FRIEND_INVITATION_REMOVED_NOTIFY, FRIENDS), "Friends::FriendInvitationRemovedNotify");
+ REGISTER_SERVER_PACKET_NAME(PacketHeader(Friends::SMSG_FRIENDS_LIST_NOTIFY_5, FRIENDS), "Friends::FriendsListNotify5");
+ REGISTER_SERVER_PACKET_NAME(PacketHeader(Friends::SMSG_ACCOUNT_BLOCK_ADDED_NOTIFY, FRIENDS), "Friends::AccountBlockAddedNotify");
+ REGISTER_SERVER_PACKET_NAME(PacketHeader(Friends::SMSG_ACCOUNT_BLOCK_REMOVED_NOTIFY, FRIENDS), "Friends::AccountBlockRemovedNotify");
+ REGISTER_SERVER_PACKET_NAME(PacketHeader(Friends::SMSG_TOON_BLOCK_NOTIFY, FRIENDS), "Friends::ToonBlockNotify");
+ REGISTER_SERVER_PACKET_NAME(PacketHeader(Friends::SMSG_FRIENDS_OF_FRIEND_RESULT, FRIENDS), "Friends::FriendsOfFriendResult");
}
void Battlenet::PacketManager::RegisterPresencePackets()
@@ -177,6 +187,9 @@ void Battlenet::PacketManager::RegisterChatPackets()
REGISTER_CLIENT_PACKET_NAME(PacketHeader(Chat::CMSG_ENUM_CONFERENCE_DESCRIPTIONS, CHAT), "Chat::EnumConferenceDescriptions");
REGISTER_CLIENT_PACKET_NAME(PacketHeader(Chat::CMSG_ENUM_CONFERENCE_MEMBER_COUNTS, CHAT), "Chat::EnumConferenceMemberCounts");
REGISTER_CLIENT_PACKET_NAME(PacketHeader(Chat::CMSG_MODIFY_CHANNEL_LIST_REQUEST, CHAT), "Chat::ModifyChannelListRequest");
+ REGISTER_CLIENT_PACKET_NAME(PacketHeader(Chat::CMSG_GET_MEMBER_COUNT_REQUEST, CHAT), "Chat::GetMemberCountRequest");
+ REGISTER_CLIENT_PACKET_NAME(PacketHeader(Chat::CMSG_MODIFY_CHANNEL_LIST_REQUEST_2, CHAT), "Chat::ModifyChannelListRequest2");
+ REGISTER_CLIENT_PACKET_NAME(PacketHeader(Chat::CMSG_GAME_DATA_SEND_REQUEST, CHAT), "Chat::GameDataSendRequest");
REGISTER_SERVER_PACKET_NAME(PacketHeader(Chat::SMSG_MEMBERSHIP_CHANGE_NOTIFY, CHAT), "Chat::MembershipChangeNotify");
REGISTER_SERVER_PACKET_NAME(PacketHeader(Chat::SMSG_INVITE_NOTIFY, CHAT), "Chat::InviteNotify");
@@ -195,11 +208,17 @@ void Battlenet::PacketManager::RegisterChatPackets()
REGISTER_SERVER_PACKET_NAME(PacketHeader(Chat::SMSG_JOIN_NOTIFY_2, CHAT), "Chat::JoinNotify2");
REGISTER_SERVER_PACKET_NAME(PacketHeader(Chat::SMSG_MODIFY_CHANNEL_LIST_RESPONSE, CHAT), "Chat::ModifyChannelListResponse");
REGISTER_SERVER_PACKET_NAME(PacketHeader(Chat::SMSG_CONFIG_CHANGED, CHAT), "Chat::ConfigChanged");
+ REGISTER_SERVER_PACKET_NAME(PacketHeader(Chat::SMSG_WHISPER_ECHO_RECV, CHAT), "Chat::WhisperEchoRecv");
+ REGISTER_SERVER_PACKET_NAME(PacketHeader(Chat::SMSG_GET_MEMBER_COUNT_RESPONSE, CHAT), "Chat::GetMemberCountResponse");
+ REGISTER_SERVER_PACKET_NAME(PacketHeader(Chat::SMSG_MODIFY_CHANNEL_LIST_RESPONSE_2, CHAT), "Chat::ModifyChannelListResponse2");
+ REGISTER_SERVER_PACKET_NAME(PacketHeader(Chat::SMSG_GAME_DATA_SEND_RESPONSE, CHAT), "Chat::GameDataSendResponse");
+ REGISTER_SERVER_PACKET_NAME(PacketHeader(Chat::SMSG_GAME_DATA_RECV, CHAT), "Chat::GameDataRecv");
}
void Battlenet::PacketManager::RegisterSupportPackets()
{
REGISTER_CLIENT_PACKET_NAME(PacketHeader(Support::CMSG_COMPLAINT_REQUEST, SUPPORT), "Support::ComplaintRequest");
+ REGISTER_CLIENT_PACKET_NAME(PacketHeader(Support::CMSG_COMPLAINT_REQUEST_2, SUPPORT), "Support::ComplaintRequest2");
}
void Battlenet::PacketManager::RegisterAchievementPackets()
diff --git a/src/server/bnetserver/Packets/SupportPackets.h b/src/server/bnetserver/Packets/SupportPackets.h
index 03bd53e4bf6..d3447b93fe9 100644
--- a/src/server/bnetserver/Packets/SupportPackets.h
+++ b/src/server/bnetserver/Packets/SupportPackets.h
@@ -26,8 +26,8 @@ namespace Battlenet
{
enum Opcode
{
- CMSG_COMPLAINT_REQUEST = 0x0, // Deprecated in client
- CMSG_COMPLAINT_REQUEST2 = 0x1 // Not implemented
+ CMSG_COMPLAINT_REQUEST = 0x0, // Deprecated in client
+ CMSG_COMPLAINT_REQUEST_2 = 0x1 // Not implemented
};
}
}