Core/NetworkIO: Adjust more packet throttling values

Adjust more packet throttling values and add Player name to log to help investigate false positives.
This commit is contained in:
jackpoz
2014-05-29 19:43:09 +02:00
parent f312b86941
commit 1b47f3270e

View File

@@ -1252,8 +1252,9 @@ bool WorldSession::DosProtection::EvaluateOpcode(WorldPacket& p, time_t time) co
if (++packetCounter.amountCounter > maxPacketCounterAllowed)
{
dosTriggered = true;
TC_LOG_WARN("network", "AntiDOS: Account %u, IP: %s, flooding packet (opc: %s (0x%X), count: %u)",
Session->GetAccountId(), Session->GetRemoteAddress().c_str(), opcodeTable[p.GetOpcode()].name, p.GetOpcode(), packetCounter.amountCounter);
TC_LOG_WARN("network", "AntiDOS: Account %u, IP: %s, Character: %s, flooding packet (opc: %s (0x%X), count: %u)",
Session->GetAccountId(), Session->GetRemoteAddress().c_str(), Session->GetPlayerName().c_str(),
opcodeTable[p.GetOpcode()].name, p.GetOpcode(), packetCounter.amountCounter);
}
// Then check if player is sending packets not allowed
@@ -1313,6 +1314,7 @@ uint32 WorldSession::DosProtection::GetMaxPacketCounterAllowed(uint16 opcode) co
case CMSG_PET_NAME_QUERY:
case CMSG_CREATURE_QUERY:
case CMSG_NPC_TEXT_QUERY:
case CMSG_QUESTGIVER_STATUS_QUERY:
{
maxPacketCounterAllowed = 5000;
break;
@@ -1363,6 +1365,8 @@ uint32 WorldSession::DosProtection::GetMaxPacketCounterAllowed(uint16 opcode) co
case CMSG_GAMEOBJ_REPORT_USE:
case MSG_RAID_TARGET_UPDATE:
case CMSG_QUESTGIVER_COMPLETE_QUEST:
case CMSG_PLAYER_VEHICLE_ENTER:
case CMSG_PETITION_SIGN:
{
maxPacketCounterAllowed = 20;
break;
@@ -1410,7 +1414,6 @@ uint32 WorldSession::DosProtection::GetMaxPacketCounterAllowed(uint16 opcode) co
case CMSG_REQUEST_VEHICLE_EXIT:
case CMSG_LEARN_PREVIEW_TALENTS:
case CMSG_LEARN_PREVIEW_TALENTS_PET:
case CMSG_PLAYER_VEHICLE_ENTER:
case CMSG_CONTROLLER_EJECT_PASSENGER:
case CMSG_EQUIPMENT_SET_SAVE:
case CMSG_DELETEEQUIPMENT_SET:
@@ -1425,7 +1428,6 @@ uint32 WorldSession::DosProtection::GetMaxPacketCounterAllowed(uint16 opcode) co
case CMSG_DISMISS_CRITTER:
case CMSG_REPOP_REQUEST:
case CMSG_PETITION_BUY:
case CMSG_PETITION_SIGN:
case CMSG_TURN_IN_PETITION:
case CMSG_COMPLETE_CINEMATIC:
case CMSG_ITEM_REFUND: