From 34eecc8b41bda507a6f1fb15c812e3563e730e9d Mon Sep 17 00:00:00 2001 From: Patrik Oldsberg Date: Thu, 17 Dec 2020 10:53:31 +0100 Subject: [PATCH] core-api: unique storage of saml sessions as well --- .changeset/sour-badgers-cry.md | 2 +- .../core-api/src/apis/implementations/auth/saml/SamlAuth.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.changeset/sour-badgers-cry.md b/.changeset/sour-badgers-cry.md index cd5aaf7afb..901294bf03 100644 --- a/.changeset/sour-badgers-cry.md +++ b/.changeset/sour-badgers-cry.md @@ -2,4 +2,4 @@ '@backstage/core-api': patch --- -GitHub Auth Api uses provider.id to build storage key name. +Use auth provider ID to create unique session storage keys for GitHub and SAML Auth. diff --git a/packages/core-api/src/apis/implementations/auth/saml/SamlAuth.ts b/packages/core-api/src/apis/implementations/auth/saml/SamlAuth.ts index da5f082c9b..e05f6266d6 100644 --- a/packages/core-api/src/apis/implementations/auth/saml/SamlAuth.ts +++ b/packages/core-api/src/apis/implementations/auth/saml/SamlAuth.ts @@ -63,7 +63,7 @@ class SamlAuth implements ProfileInfoApi, BackstageIdentityApi, SessionApi { const authSessionStore = new AuthSessionStore({ manager: sessionManager, - storageKey: 'samlSession', + storageKey: `${provider.id}Session`, }); return new SamlAuth(authSessionStore);