Skip to content

User session system#588

Merged
hirmerpl merged 9 commits intomasterfrom
user_sessions
Jun 23, 2021
Merged

User session system#588
hirmerpl merged 9 commits intomasterfrom
user_sessions

Conversation

@schneijan
Copy link
Member

@schneijan schneijan commented May 31, 2021

Removes the previous http-auth-based login system in favor of a session-based system. Core features:

  • On login, user sessions with unique session IDs are generated and stored in the MongoDB
  • No session state is kept on the server, instead everything is stored in the MongoDB ("stateless")
  • For performance reasons, a local cache on server remembers session IDs and associated users for a TTL of one minute
  • MongoDB repository and local cache are updated accordingly on logout of a user
  • Sessions expire automatically seven days after creation
  • Users with missing or invalid sessions are redirected to the login page
  • Username and password do not need to be sent with every server request anymore

Closes #571

@schneijan schneijan requested a review from hirmerpl May 31, 2021 23:43
@schneijan
Copy link
Member Author

Fixed issue with non-https cookies.

@schneijan
Copy link
Member Author

The API wiki page now describes how authentication works when using the REST API directly.

@hirmerpl hirmerpl merged commit aab55d6 into master Jun 23, 2021
@hirmerpl hirmerpl deleted the user_sessions branch June 23, 2021 07:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Transform user system to sessions

2 participants