From 9c4e5cdee9d343e6f660a86d6978a29362e10fd6 Mon Sep 17 00:00:00 2001 From: Fabio Torchetti Date: Thu, 23 Jun 2022 13:08:05 -0500 Subject: [PATCH] Allow specifying JWT token key algorithm Signed-off-by: Fabio Torchetti --- plugins/auth-backend/src/service/router.ts | 3 +++ 1 file changed, 3 insertions(+) diff --git a/plugins/auth-backend/src/service/router.ts b/plugins/auth-backend/src/service/router.ts index 50577ece53..ecd7f725a6 100644 --- a/plugins/auth-backend/src/service/router.ts +++ b/plugins/auth-backend/src/service/router.ts @@ -44,6 +44,7 @@ export interface RouterOptions { config: Config; discovery: PluginEndpointDiscovery; tokenManager: TokenManager; + tokenKeyAlgorithm?: string; providerFactories?: ProviderFactories; } @@ -56,6 +57,7 @@ export async function createRouter( discovery, database, tokenManager, + tokenKeyAlgorithm, providerFactories, } = options; const router = Router(); @@ -71,6 +73,7 @@ export async function createRouter( keyStore, keyDurationSeconds, logger: logger.child({ component: 'token-factory' }), + algorithm: tokenKeyAlgorithm, }); const catalogApi = new CatalogClient({ discoveryApi: discovery });