From 3aa250e3ad22be21986d702c653536a11ef00f52 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?G=C3=B6ran=20Sander?= Date: Wed, 3 Jul 2024 09:42:51 +0000 Subject: [PATCH] fix(host-info): Correctly handle cases where there is no MAC addr available Fixes #1183 --- src/globals.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/globals.js b/src/globals.js index 1151f194..40310d60 100644 --- a/src/globals.js +++ b/src/globals.js @@ -563,7 +563,8 @@ class Settings { } else { idSrc = this.config.get('Butler.configQRS.host') + siSystem.uuid; } - const salt = siMem.total; + // Add underscore to salt to make sure it's a string + const salt = `${siMem.total}_`; const hash = crypto.createHmac('sha256', salt); hash.update(idSrc); id = hash.digest('hex');