From 065b9b856bdd7a0af9d1f93a9ade152a057545d4 Mon Sep 17 00:00:00 2001
From: Dominik Hebeler <dominik@suma-ev.de>
Date: Wed, 20 Nov 2024 11:07:14 +0100
Subject: [PATCH] keymanager now always working in development envs

---
 pass/app.js              | 5 +----
 pass/config/default.json | 5 +++++
 2 files changed, 6 insertions(+), 4 deletions(-)

diff --git a/pass/app.js b/pass/app.js
index 91c7adc..2d2806a 100644
--- a/pass/app.js
+++ b/pass/app.js
@@ -105,10 +105,7 @@ app.use((req, res, next) => {
 
   if (
     allowed_hosts.includes(req.hostname) ||
-    (process.env.NODE_ENV === "development" &&
-      req.hostname.match(
-        /^(localhost|.*\.ngrok-free\.app|.*\.review\.metager\.de)$/
-      ))
+    process.env.NODE_ENV === "development"
   ) {
     let proto = req.get("x-forwarded-proto") ?? req.protocol;
     let host = req.get("x-forwarded-host") ?? req.get("host");
diff --git a/pass/config/default.json b/pass/config/default.json
index 1f390d4..8f0e191 100644
--- a/pass/config/default.json
+++ b/pass/config/default.json
@@ -83,6 +83,11 @@
   },
   "crypto": {
     "hmac_integrity_seed": "<insert_secret_for_hmac_seed>",
+    "private_key": {
+      "seed": "<insert_secret_token_seed>",
+      "bit_length": 2048,
+      "date_format": "YYYY-MM"
+    },
     "tokens": {
       "private_key": {
         "seed": "<insert_secret_token_seed>",
-- 
GitLab