91 Commits

Author SHA1 Message Date
github-actions[bot] 68db890456 Version Packages (next) 2026-05-26 15:26:38 +00:00
github-actions[bot] b97fcb0a93 Version Packages 2026-05-19 18:28:24 +00:00
github-actions[bot] 1cc86bee1c Version Packages (next) 2026-04-21 15:07:43 +00:00
github-actions[bot] 93e643d142 Version Packages 2026-04-14 14:57:31 +00:00
Patrik Oldsberg 5b1ba4ee3e Merge pull request #33718 from UsainBloot/auth0-cache-profile
auth0: cache profile API responses during token refresh
2026-04-08 11:39:21 +02:00
github-actions[bot] 6c10d88c13 Version Packages (next) 2026-04-07 15:30:58 +00:00
Jack Palmer dfde6becee fix(auth0): skip profile cache when id_token has no sub claim
When the JWT id_token lacks a sub claim, the cache key would be
auth0-profile:undefined, causing all users without a sub to share
the same cached profile. Now skips caching entirely when sub is
missing and fetches the profile directly.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Signed-off-by: Jack Palmer <jackpalmer@spotify.com>
2026-04-07 14:07:09 +01:00
Jack Palmer 44a42bf8e7 fix(auth0): use jose to decode id_token sub claim for cache key
Replace manual base64 JWT decoding with jose's decodeJwt for
correctness and consistency with other auth modules. Add jose
as a dependency.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Signed-off-by: Jack Palmer <jackpalmer@spotify.com>
2026-04-07 14:06:59 +01:00
Jonathan Roebuck ca3ef847f5 fix(auth0): use stable sub claim as cache key instead of refresh token
Auth0 rotates refresh tokens on each use, causing cache misses every
time. Use the user's sub claim from the ID token as the cache key
instead, which is stable per user.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Signed-off-by: Jonathan Roebuck <jroebuck@spotify.com>
2026-04-07 14:05:41 +01:00
Jack Palmer b3bbd42f91 auth0: cache profile API responses during token refresh
Every page refresh triggers the auth0 authenticator to fetch the user
profile from Auth0's /userinfo API. Auth0 enforces strict rate limits on
this endpoint, causing failures at scale.

Add a createAuth0Authenticator factory that accepts an optional
CacheService to cache profile responses with a 1-minute TTL. The module
now uses the cached variant by default. The existing auth0Authenticator
export remains available for use without caching.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Signed-off-by: Jack Palmer <jackpalmer@spotify.com>
2026-04-07 14:05:41 +01:00
Patrik Oldsberg 7bc057e8b6 Merge pull request #33703 from backstage/feat/auth0-federated-logout
feat(auth): support provider logout redirects, implement Auth0 federated logout
2026-04-01 15:27:27 +02:00
Jonathan Roebuck 3bddf23896 refactor(auth0): use URL/URLSearchParams for logout URL construction
Replace manual string concatenation with URL and URLSearchParams for
safer encoding and better readability.

Signed-off-by: Jonathan Roebuck <jroebuck@spotify.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-01 13:43:34 +01:00
Jonathan Roebuck 25e8a65b46 refactor(auth0): rename config key federated to federatedLogout
The `federated` config key was ambiguous. Rename to `federatedLogout`
for clarity since it specifically controls federated logout behavior.

Signed-off-by: Jonathan Roebuck <jroebuck@spotify.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-01 13:41:06 +01:00
Jonathan Roebuck 7d002e83a5 fix(auth0): remove untestable app.baseUrl fallback test
The origin header is always present in browser POST requests, making
the fallback scenario unreachable in practice.

Signed-off-by: Jonathan Roebuck <jroebuck@spotify.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-01 13:28:32 +01:00
Jack Palmer 208cf5f922 fix(auth): add security hardening and federated config for Auth0 logout
Add server-side URL validation for logoutUrl (HTTPS + localhost only),
origin validation on the logout endpoint, and a configurable `federated`
option (default false) for Auth0 provider logout. Includes comprehensive
test coverage for all security controls.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Signed-off-by: Jack Palmer <jackpalmer@spotify.com>
2026-04-01 13:06:43 +01:00
Jonathan Roebuck a07f0196e2 chore: update auth0 provider API report with domain and clientID fields
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Signed-off-by: Jonathan Roebuck <jroebuck@spotify.com>
2026-04-01 13:06:40 +01:00
github-actions[bot] a2cb332e25 Version Packages (next) 2026-03-31 15:30:51 +00:00
Jonathan Roebuck 97850d0ef1 feat(auth0): implement federated logout to clear Auth0 and IdP sessions
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Signed-off-by: Jonathan Roebuck <jroebuck@spotify.com>
2026-03-31 16:20:23 +01:00
github-actions[bot] c1b510cabb Version Packages (next) 2026-03-24 14:54:00 +00:00
github-actions[bot] 5725b5fcfa Version Packages 2026-03-17 21:39:07 +00:00
github-actions[bot] ed7c4e3bef Version Packages (next) 2026-03-10 17:34:12 +00:00
github-actions[bot] 4bd6a3a1af Version Packages (next) 2026-02-24 19:24:06 +00:00
github-actions[bot] e6df5d52ce Version Packages 2026-02-17 16:06:18 +00:00
github-actions[bot] 7c41134684 Version Packages (next) 2026-02-10 16:14:59 +00:00
Jack Palmer 035a808d5e chore: address pr comments
Signed-off-by: Jack Palmer <jackpalmer@spotify.com>
2026-02-06 09:02:24 +00:00
Jack Palmer bf3861fdb6 chore: Throw error when organization declared in strategy does not match organization in request
Signed-off-by: Jack Palmer <jackpalmer@spotify.com>
2026-02-05 15:21:06 +00:00
Jack Palmer 3458f3a731 tests: organization and invitation params
Signed-off-by: Jack Palmer <jackpalmer@spotify.com>
2026-02-05 14:01:04 +00:00
Jack Palmer 867c905da5 feat: auth0 strategy - add additional organization query params to authorizationParams
Signed-off-by: Jack Palmer <jackpalmer@spotify.com>
2026-02-05 13:44:15 +00:00
Jack Palmer 8949803609 feat: auth0 strategy - set invitation query parameter as authorizationParam when present
Signed-off-by: Jack Palmer <jackpalmer@spotify.com>
2026-02-05 13:23:57 +00:00
github-actions[bot] d4b85dddee Version Packages (next) 2026-01-27 15:51:11 +00:00
Jack Palmer 29ddd3cf43 chore: fix types
Signed-off-by: Jack Palmer <jackpalmer@spotify.com>
2026-01-23 11:33:26 +00:00
Jack Palmer 6539d9a15c feat: Add organization option to auth0 auth provider
Signed-off-by: Jack Palmer <jackpalmer@spotify.com>
2026-01-23 10:55:37 +00:00
github-actions[bot] c24788d5bb Version Packages 2025-12-16 14:08:20 +00:00
github-actions[bot] e08f48a9b5 Version Packages (next) 2025-12-09 15:00:09 +00:00
dependabot[bot] de96a60f7a chore(deps): bump express from 4.21.2 to 4.22.0
Bumps [express](https://github.com/expressjs/express) from 4.21.2 to 4.22.0.
- [Release notes](https://github.com/expressjs/express/releases)
- [Changelog](https://github.com/expressjs/express/blob/4.22.0/History.md)
- [Commits](https://github.com/expressjs/express/compare/4.21.2...4.22.0)

---
updated-dependencies:
- dependency-name: express
  dependency-version: 4.22.0
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-12-02 20:33:46 +01:00
github-actions[bot] 756986e5e7 Version Packages (next) 2025-11-25 16:21:32 +00:00
github-actions[bot] 792f4d7e3d Version Packages 2025-11-18 12:23:09 +00:00
github-actions[bot] 3738293d26 Version Packages (next) 2025-11-04 15:00:26 +00:00
github-actions[bot] 807af8ce0e Version Packages (next) 2025-10-21 16:14:43 +00:00
github-actions[bot] d6ce2db9ca Version Packages 2025-10-14 15:29:54 +00:00
github-actions[bot] c2c60546d2 Version Packages (next) 2025-09-24 12:57:42 +00:00
github-actions[bot] b799a2d07f Version Packages 2025-09-16 13:22:58 +00:00
github-actions[bot] ac48eeb3ba Version Packages (next) 2025-09-02 12:17:03 +00:00
Jessica He 3aff9e1213 remove domain attribute to set OAuth cookies as host-only
Signed-off-by: Jessica He <jhe@redhat.com>
2025-08-19 15:24:18 -04:00
github-actions[bot] b93a3471c2 Version Packages 2025-08-19 13:01:39 +00:00
github-actions[bot] 531a48848c Version Packages (next) 2025-07-29 14:40:44 +00:00
github-actions[bot] 9a7cae26c9 Version Packages 2025-07-15 14:26:41 +00:00
github-actions[bot] 952cefedd8 Version Packages (next) 2025-07-01 11:50:02 +00:00
github-actions[bot] 58558ef2c1 Version Packages 2025-06-17 12:45:56 +00:00
github-actions[bot] d57a6f7828 Version Packages (next) 2025-06-03 13:12:47 +00:00