-
Notifications
You must be signed in to change notification settings - Fork 29.2k
feat(core): Logout should invalidate the auth token (no-changelog) #10335
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
Conversation
5e5c04b
to
defcc05
Compare
Test summaryRun details
This comment has been generated by cypress-bot as a result of this project's GitHub integration settings. You can manage this integration in this project's settings in the Cypress Cloud |
✅ All Cypress E2E specs passed |
defcc05
to
9db4425
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Functionality and approach seem decent 👌 Couple comments about implementation details
packages/cli/src/databases/migrations/common/1723627610222-CreateInvalidAuthTokenTable.ts
Outdated
Show resolved
Hide resolved
ownerAgent.jar.setCookie(`${AUTH_COOKIE_NAME}=${cookie!.value}`); | ||
await ownerAgent.get('/login').expect(401); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should this be its own test case? Also should we try some other endpoint than /login
as it's not normally used with the auth token?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
we should rename GET /login
to GET /me
instead. it keeps confusing people.
48208fc
to
b7c7ebc
Compare
Another thing I was thinking about but forgot to ask: Should we also clean up the |
That is the plan. That's why the table already has a |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚀
✅ All Cypress E2E specs passed |
* master: ci: Fix benchmark cli path (no-changelog) (#10506) refactor(core): Standardize filenames in `cli` (no-changelog) (#10484) fix(AI Agent Node): Allow AWS Bedrock Chat to be used with conversational agent (#10489) feat(AI Agent Node): Add tutorial link to agent node (#10493) feat: Add n8n-benchmark cli (no-changelog) (#10410) feat(core): Logout should invalidate the auth token (no-changelog) (#10335) refactor(editor): Add types to importCurlEventBus (no-changelog) (#10497) refactor(editor): Add types to htmlEditorEventBus (no-changelog) (#10498) refactor(editor): Add types for dataPinningEventBus (no-changelog) (#10499) refactor(editor): Add types to codeNodeEditorEventBus (no-changelog) (#10501)
Got released with |
Summary
When a user logs out, we should also invalidate the auth token to prevent it from being used again.
Related Linear tickets, Github issues, and Community forum posts
https://linear.app/n8n/issue/SEC-75
Review / Merge checklist