fix: remove waku sync broken dos mechanism (#3472)

This commit is contained in:
Simon-Pierre Vivier 2025-06-26 11:40:10 -04:00 committed by GitHub
parent b4374a5ada
commit ea2da0942b
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -143,9 +143,10 @@ proc needsReceiverLoop(self: SyncTransfer) {.async.} =
proc initProtocolHandler(self: SyncTransfer) =
proc handler(conn: Connection, proto: string) {.async: (raises: [CancelledError]).} =
while true:
if not self.inSessions.contains(conn.peerId):
## removed DOS prototection until we can design something better
#[ if not self.inSessions.contains(conn.peerId):
error "unwanted peer, disconnecting", remote = conn.peerId
break
break ]#
let readRes = catch:
await conn.readLp(int64(DefaultMaxWakuMessageSize))