fix(Core/MailHandler): Security check (#2889)
This commit is contained in:
@@ -24,8 +24,11 @@ bool WorldSession::CanOpenMailBox(uint64 guid)
|
|||||||
{
|
{
|
||||||
if (guid == _player->GetGUID())
|
if (guid == _player->GetGUID())
|
||||||
{
|
{
|
||||||
sLog->outError("%s attempt open mailbox in cheating way.", _player->GetName().c_str());
|
if (_player->GetSession()->GetSecurity() < SEC_MODERATOR)
|
||||||
return false;
|
{
|
||||||
|
sLog->outError("%s attempt open mailbox in cheating way.", _player->GetName().c_str());
|
||||||
|
return false;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
else if (IS_GAMEOBJECT_GUID(guid))
|
else if (IS_GAMEOBJECT_GUID(guid))
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user