mirror of
https://github.com/SWG-Source/src.git
synced 2026-01-17 00:04:25 -05:00
kick assholes who try to send unauthorized controller messages; log them
to a special HackAttempts channel (note: add to logservertargets and we'll get a nice log with ip addys we can autoban with fail2ban)
This commit is contained in:
@@ -947,7 +947,11 @@ void Client::receiveClientMessage(const GameNetworkMessage &message) {
|
||||
}
|
||||
} else {
|
||||
// log as a likely hack
|
||||
LOG("CustomerService", ("UnauthorizedControllerMessage: Player %s sent an unauthorized controller message %d for object %s.", PlayerObject::getAccountDescription(getCharacterObjectId()).c_str(), o.getMessage(), o.getNetworkId().getValueString().c_str()));
|
||||
LOG("HackAttempts", ("Unauthorized Controller Message: Player %s at %s sent an unauthorized controller message %d for object %s", PlayerObject::getAccountDescription(getCharacterObjectId()).c_str(), getIpAddress().c_str(), o.getMessage(), o.getNetworkId().getValueString().c_str()));
|
||||
|
||||
KickPlayer const kickMessage(m_characterObjectId, "Hack Attempt");
|
||||
GameServer::getInstance().sendToConnectionServers(kickMessage);
|
||||
GameServer::getInstance().dropClient(m_characterObjectId);
|
||||
}
|
||||
|
||||
if (!appended) {
|
||||
|
||||
Reference in New Issue
Block a user