mirror of
https://github.com/MirrorNetworking/Mirror.git
synced 2024-11-18 02:50:32 +00:00
fix(NetworkServer): Don't disconnect on OnEntityStateMessage for object without authority (#3439)
This commit is contained in:
parent
b377d765ec
commit
40361f62bf
@ -334,12 +334,12 @@ static void OnEntityStateMessage(NetworkConnectionToClient connection, EntitySta
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// an attacker may attempt to modify another connection's entity
|
// An attacker may attempt to modify another connection's entity
|
||||||
|
// This could also be a race condition of message in flight when
|
||||||
|
// RemoveClientAuthority is called, so not malicious.
|
||||||
|
// Don't disconnect, just log the warning.
|
||||||
else
|
else
|
||||||
{
|
Debug.LogWarning($"EntityStateMessage from {connection} for {identity} without authority.");
|
||||||
Debug.LogWarning($"Connection {connection.connectionId} attempted to modify {identity} which is not owned by the connection. Disconnecting the connection.");
|
|
||||||
connection.Disconnect();
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
// no warning. don't spam server logs.
|
// no warning. don't spam server logs.
|
||||||
// else Debug.LogWarning($"Did not find target for sync message for {message.netId} . Note: this can be completely normal because UDP messages may arrive out of order, so this message might have arrived after a Destroy message.");
|
// else Debug.LogWarning($"Did not find target for sync message for {message.netId} . Note: this can be completely normal because UDP messages may arrive out of order, so this message might have arrived after a Destroy message.");
|
||||||
|
Loading…
Reference in New Issue
Block a user