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

Double submit and race condition in account registration #6687

Open
martinmo opened this issue Jun 8, 2023 · 0 comments
Open

Double submit and race condition in account registration #6687

martinmo opened this issue Jun 8, 2023 · 0 comments
Labels

Comments

@martinmo
Copy link

martinmo commented Jun 8, 2023

Describe the bug

In the account registration, it's possible to submit the registration form multiple times because the submit button remains clickable until the API request returns. However, this request sometimes can take a few seconds (e.g., because accounts in external systems such as GitLab are created, network latency, and so on).

There is no indication for the user that a request is ongoing – because of this, users sometimes submit the same form a second or even a third time.

The server side doesn't handle these quick successive requests well and there are different possible outcomes we have observed:

To Reproduce

  1. Go to /account/register.
  2. Fill the form with valid data.
  3. Click the "Register" multiple times (this might be difficult on a local setup).
  4. Check your mailbox and see multiple registration mails.

Expected behavior

  • On the UI side, the "Register" button should be immediately disabled after clicking to prevent multiple submits. This also acts as an indicator for the user that some operation is ongoing.
  • On the server side, the /api/register endpoint should reject parallel registration requests with the same user data (e.g., login name).

Screenshots

c4aaee17-ce73-48e4-89f4-3612a19a08f3

Which version of Artemis are you seeing the problem on?

6.2.1

What browsers are you seeing the problem on?

Firefox

Additional context

We use GitLab and Jenkins.

Relevant log output

No response

@martinmo martinmo added the bug label Jun 8, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant