diff options
author | Vitaly Takmazov | 2017-04-27 11:17:59 +0300 |
---|---|---|
committer | Vitaly Takmazov | 2017-04-27 11:17:59 +0300 |
commit | 0af02a8047f88216e7d43c63c9e8ce27107b40f9 (patch) | |
tree | 0a51f9a36c20916ff7874fa61a07411602e1bd77 | |
parent | 653f23300d5baa92b650cde55f67fed7bac32cad (diff) |
juick-ws: treat visitors with wrong hash as anonymous
-rw-r--r-- | juick-ws/src/main/java/com/juick/ws/WebsocketComponent.java | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/juick-ws/src/main/java/com/juick/ws/WebsocketComponent.java b/juick-ws/src/main/java/com/juick/ws/WebsocketComponent.java index bca1b27a..bca5c804 100644 --- a/juick-ws/src/main/java/com/juick/ws/WebsocketComponent.java +++ b/juick-ws/src/main/java/com/juick/ws/WebsocketComponent.java @@ -72,12 +72,7 @@ public class WebsocketComponent extends TextWebSocketHandler implements Protocol if (hash.length() == 16) { visitor = userService.getUserByHash(hash); } else { - try { - logger.info("wrong hash for {} from {}", visitor.getUid(), hXRealIP); - session.close(new CloseStatus(403, "Forbidden")); - } catch (IOException e) { - logger.warn("ws error", e); - } + logger.info("wrong hash for {} from {}", visitor.getUid(), hXRealIP); } break; } |