chinwagsocial/app
Claire 3251b8eead Fix reviving revoked sessions and invalidating login (#16943)
Up until now, we have used Devise's Rememberable mechanism to re-log users
after the end of their browser sessions. This mechanism relies on a signed
cookie containing a token. That token was stored on the user's record,
meaning it was shared across all logged in browsers, meaning truly revoking
a browser's ability to auto-log-in involves revoking the token itself, and
revoking access from *all* logged-in browsers.

We had a session mechanism that dynamically checks whether a user's session
has been disabled, and would log out the user if so. However, this would only
clear a session being actively used, and a new one could be respawned with
the `remember_user_token` cookie.

In practice, this caused two issues:
- sessions could be revived after being closed from /auth/edit (security issue)
- auto-log-in would be disabled for *all* browsers after logging out from one
  of them

This PR removes the `remember_token` mechanism and treats the `_session_id`
cookie/token as a browser-specific `remember_token`, fixing both issues.
2021-11-06 00:17:05 +01:00
..
chewy Change tootctl search deploy algorithm (#14300) 2020-07-14 18:10:35 +02:00
controllers Fix reviving revoked sessions and invalidating login (#16943) 2021-11-06 00:17:05 +01:00
helpers Change number_to_human calls to always use 3-digits precision (#16469) 2021-11-05 23:46:24 +01:00
javascript Improve modal flow and back button handling (#16499) 2021-11-05 23:46:24 +01:00
lib Fix inefficiencies in auto-linking code (#16506) 2021-11-05 23:46:24 +01:00
mailers Prepare Mastodon for Rails 6 (#15911) 2021-03-17 10:09:55 +01:00
models Fix reviving revoked sessions and invalidating login (#16943) 2021-11-06 00:17:05 +01:00
policies Add management of delivery availability in Federation settings (#15771) 2021-05-05 23:39:02 +02:00
presenters Add server rules (#15769) 2021-02-21 19:50:12 +01:00
serializers Add configuration attribute to GET /api/v1/instance (#16485) 2021-11-05 20:30:02 +01:00
services Fix some link previews being incorrectly generated from other prior links (#16885) 2021-11-05 20:28:59 +01:00
validators Add configuration attribute to GET /api/v1/instance (#16485) 2021-11-05 20:30:02 +01:00
views Change number_to_human calls to always use 3-digits precision (#16469) 2021-11-05 23:46:24 +01:00
workers Fix when MoveWorker cannot get locale from remote account (#16576) 2021-11-05 20:26:36 +01:00