web client getting bouned
This commit is contained in:
@@ -159,8 +159,12 @@ public sealed partial class DungeonHandler : IClientMessageHandler
|
||||
return;
|
||||
}
|
||||
// All dungeon operations require authentication
|
||||
if (!_sessions.TryGet(connection.Id, out var accountId, out _) && opCode != DungeonOpCodes.ASSET_MANIFEST_REQUEST && opCode != OpCodes.PONG)
|
||||
if (!_sessions.TryGet(connection.Id, out var accountId, out _))
|
||||
{
|
||||
// Ignore stray input before auth to avoid booting the client during connect
|
||||
if (opCode is >= DungeonOpCodes.DUNGEON_INPUT_MOVE and <= DungeonOpCodes.DUNGEON_INPUT_FIRE_PROJECTILE)
|
||||
return;
|
||||
|
||||
await SendErrorAsync(connection, $"auth_required for packet: {opCode}", ct);
|
||||
return;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user