diff --git a/src/api/ws.ts b/src/api/ws.ts index 3f04630..3d815da 100644 --- a/src/api/ws.ts +++ b/src/api/ws.ts @@ -12,7 +12,7 @@ export const activateWS = () => { activeWS = true; }; export const wsOnConnection = (socket: ws.WebSocket, req: http.IncomingMessage) => { let ip = req.socket.remoteAddress; - if (!activeWS || bruteforcecheck(ip ?? "")) { + if (!activeWS || !bruteforcecheck(ip ?? "")) { debug("WebSocket", "Rejected ip for bruteforce suspicion:", ip); socket.close(); return;