RocketChat / RocketChat/Rocket.Chat

Custom_Script_Logged_Out & PAT expired after upgrade to 4.6.0

Open
#25,091 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
TypeScript
Stars
46.1k
Forks
13.9k
Avg merge
3d 3h
Merged PRs (30d)
130

Description

Description:

We just updated from the previous version to 4.6.0. We have RocketChat embedded via iframe and use an auth token to log users in. After the upgrade via Docker-Compose, we're seeing Custom_Script_Logged_Out being called and the authentication failing. The PATs we used to log in the user no longer worked.

After regenerating PATs for all of the users, things worked again.

Steps to reproduce:
  1. Set up chat in iframe, use PATs to log in
  2. Upgrade Rocketchat / Restart server
  3. Log events to see -> Custom_Script_Logged_Out
  4. PATs no longer work
Expected behavior:

I'd expect PATs to continue to work after a restart.

Actual behavior:

PATs no longer worked

Server Setup Information:

CleanShot 2022-04-07 at 14 11 29

Client Setup Information
  • Desktop App or Browser Version: Browser, Chrome 99
  • Embedding via iframe, logged in with token
Relevant logs:

CleanShot 2022-04-07 at 13 54 38

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reviewing the reported authentication logs and the upgrade/restart path from the previous version to 4.6.0. Reproduce the iframe login with an existing PAT, then verify whether the token remains usable after restart; done means existing PATs continue to authenticate without triggering Custom_Script_Logged_Out.

Written by the indexing model from the issue text.

Assessment

Tech stack
docker-compose
Domain
authentication, backend
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.