From 3ba4cbb524803fbf5f49df3b19fd5bf5775bc519 Mon Sep 17 00:00:00 2001 From: jorgtho Date: Tue, 14 Mar 2023 13:17:38 +0100 Subject: [PATCH] privatekey is empty string if not provided --- lib/maskinporten-auth.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/maskinporten-auth.js b/lib/maskinporten-auth.js index bdd90a7..8ee72f8 100644 --- a/lib/maskinporten-auth.js +++ b/lib/maskinporten-auth.js @@ -74,7 +74,7 @@ const generateMaskinportenGrant = options => { jti: nanoid() } - return sign(payload, { key: certificate.key, passphrase: options.privateKeyPassphrase }, jwtOptions) + return sign(payload, { key: certificate.key, passphrase: options.privateKeyPassphrase || '' }, jwtOptions) } /**