Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(backend,shared,clerk-js): Support suffixed cookies [CORE-2086] #3506

Closed
wants to merge 39 commits into from

Conversation

dimkl
Copy link
Contributor

@dimkl dimkl commented Jun 3, 2024

Description

Generate suffixed and un-suffixed __client_uat (in dev instance), __session, __clerk_db_jwt (In dev instance) cookies from ClerkJS and support reading the either the suffixed or the un-suffixed cookies in the backend SDK using the
__client_uat & __session cookies.
New ClerkJS versions will generate both suffixed and un-suffixed cookies but the backend SDK will consume only 1 of those 2.

Checklist

  • npm test runs as expected.
  • npm run build runs as expected.
  • (If applicable) JSDoc comments have been added or updated for any package exports
  • (If applicable) Documentation has been updated

Type of change

  • 🐛 Bug fix
  • 🌟 New feature
  • 🔨 Breaking change
  • 📖 Refactoring / dependency upgrade / documentation
  • other:

@dimkl dimkl self-assigned this Jun 3, 2024
Copy link

changeset-bot bot commented Jun 3, 2024

🦋 Changeset detected

Latest commit: 4b3e2e1

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 15 packages
Name Type
@clerk/clerk-js Minor
@clerk/backend Minor
@clerk/shared Minor
@clerk/astro Patch
@clerk/chrome-extension Patch
@clerk/clerk-expo Patch
@clerk/express Patch
@clerk/fastify Patch
@clerk/nextjs Patch
@clerk/remix Patch
@clerk/clerk-sdk-node Patch
@clerk/tanstack-start Patch
@clerk/testing Patch
@clerk/elements Patch
@clerk/clerk-react Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@dimkl dimkl force-pushed the CORE-2086/suffixed-cookies-draft branch 2 times, most recently from f12aaa0 to 7dcea49 Compare June 5, 2024 13:47
@dimkl dimkl requested review from nikosdouvlis and brkalow and removed request for nikosdouvlis June 5, 2024 13:47
@dimkl dimkl changed the title Core 2086: suffixed cookies [WIP] feat(backend,shared,clerk-js): Support suffixed cookies [CORE-2086] Jun 5, 2024
@dimkl dimkl force-pushed the CORE-2086/suffixed-cookies-draft branch from 7dcea49 to 50ca6e3 Compare June 5, 2024 13:49
@dimkl dimkl marked this pull request as ready for review June 5, 2024 13:50
@dimkl dimkl force-pushed the CORE-2086/suffixed-cookies-draft branch from 50ca6e3 to 6a7c065 Compare June 5, 2024 13:55
@dimkl dimkl force-pushed the CORE-2086/suffixed-cookies-draft branch from 6a7c065 to 976ae21 Compare June 5, 2024 14:34
@dimkl dimkl requested a review from colinclerk June 5, 2024 14:34
@dimkl dimkl force-pushed the CORE-2086/suffixed-cookies-draft branch 5 times, most recently from 0655a51 to da8dd2b Compare June 12, 2024 12:36
@dimkl dimkl force-pushed the CORE-2086/suffixed-cookies-draft branch 4 times, most recently from e05b4b2 to c6335a2 Compare June 25, 2024 13:55
@nikosdouvlis nikosdouvlis force-pushed the CORE-2086/suffixed-cookies-draft branch from 548ebc5 to 2865b88 Compare July 10, 2024 22:12
@nikosdouvlis nikosdouvlis force-pushed the CORE-2086/suffixed-cookies-draft branch 2 times, most recently from 4c7d111 to d871f0f Compare July 12, 2024 09:31
@nikosdouvlis nikosdouvlis force-pushed the CORE-2086/suffixed-cookies-draft branch from d871f0f to 1192df8 Compare July 12, 2024 09:48
@nikosdouvlis nikosdouvlis force-pushed the CORE-2086/suffixed-cookies-draft branch from 5399d0a to 32b83ca Compare July 16, 2024 14:12
@nikosdouvlis nikosdouvlis force-pushed the CORE-2086/suffixed-cookies-draft branch from 006eaf8 to 6e91c3b Compare July 16, 2024 17:16
integration/models/application.ts Show resolved Hide resolved
integration/playwright.config.ts Show resolved Hide resolved
fakeUsers.push(fakeUser);
await u.services.users.createBapiUser(fakeUser);

await u.po.signIn.goTo({ timeout: 30000 });
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ℹ️ We expect that in this case a handshake flow should be triggered since un-suffixed __client_uat would have a a value > 0

@nikosdouvlis nikosdouvlis force-pushed the CORE-2086/suffixed-cookies-draft branch from 98619e3 to 04fd57d Compare July 17, 2024 15:21
@nikosdouvlis nikosdouvlis force-pushed the CORE-2086/suffixed-cookies-draft branch from 04fd57d to 4b3e2e1 Compare July 17, 2024 15:47
@nikosdouvlis
Copy link
Member

Closing this one manually as GH is partially down - the commit is already into main

nikosdouvlis added a commit that referenced this pull request Jul 18, 2024
@dimkl dimkl deleted the CORE-2086/suffixed-cookies-draft branch July 18, 2024 09:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants