aboutsummaryrefslogtreecommitdiff
path: root/juick-ws
diff options
context:
space:
mode:
authorGravatar Vitaly Takmazov2017-04-27 11:17:59 +0300
committerGravatar Vitaly Takmazov2017-04-27 11:17:59 +0300
commit0af02a8047f88216e7d43c63c9e8ce27107b40f9 (patch)
tree0a51f9a36c20916ff7874fa61a07411602e1bd77 /juick-ws
parent653f23300d5baa92b650cde55f67fed7bac32cad (diff)
juick-ws: treat visitors with wrong hash as anonymous
Diffstat (limited to 'juick-ws')
-rw-r--r--juick-ws/src/main/java/com/juick/ws/WebsocketComponent.java7
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;
}