From 4ab79de6d30681893efc12ca064ce659f44197b7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Piotr=20Koz=C5=82owski?= Date: Sat, 31 May 2025 16:05:12 +0100 Subject: [PATCH] bugfix: call to /userinfo should use internal URL if defined --- src/runtime/server/lib/oauth/keycloak.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/runtime/server/lib/oauth/keycloak.ts b/src/runtime/server/lib/oauth/keycloak.ts index 790903a7..5b11c597 100644 --- a/src/runtime/server/lib/oauth/keycloak.ts +++ b/src/runtime/server/lib/oauth/keycloak.ts @@ -131,7 +131,7 @@ export function defineOAuthKeycloakEventHandler({ // TODO: improve typing // eslint-disable-next-line @typescript-eslint/no-explicit-any const user: any = await $fetch( - `${realmURL}/protocol/openid-connect/userinfo`, + `${realmURLInternal}/protocol/openid-connect/userinfo`, { headers: { Authorization: `Bearer ${accessToken}`,