From 25a11f57618728a44f8fa30bdb6071bc87fc3b47 Mon Sep 17 00:00:00 2001 From: Tobias Berger Date: Sat, 8 Jan 2022 20:22:43 +0100 Subject: [PATCH] Use a fixed salt length --- server.node.ts | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/server.node.ts b/server.node.ts index b3d494c..1bac80f 100644 --- a/server.node.ts +++ b/server.node.ts @@ -12,9 +12,7 @@ import { MessageType, } from "./lib/ServerMessage"; -const SALT = crypto - .randomBytes(Math.round(Math.random() * 1024)) - .toString("hex"); +const SALT = crypto.randomBytes(2048).toString("hex"); const port = 8085; const timeout = 15000;