huridocs / uwazi

Uwazi is a web-based, open-source solution for building and sharing document collections
http://www.uwazi.io
MIT License
241 stars 80 forks source link

The "create password" process for new user fails #6834

Closed aphilop closed 5 months ago

aphilop commented 5 months ago

Describe the bug When a new user tries to create a password, the process fails. As a consequence, the user cannot login to their account.

To Reproduce Steps to reproduce the behavior:

  1. Create a new user
  2. Open the link to create a password in the welcome email
  3. Use the form to provide a password and click save
  4. See error

Expected behavior The user must be able to create a password that can use to log in their account.

Screenshots

Error message

image

Device (please select all that apply)

Browser Safari 17.5 on MacOS 12.7.5

fnocetti commented 5 months ago

Thanks for the report @aphilop This must be related to the recent hotfix. I'm taking care immediately.

fnocetti commented 5 months ago

This not reproducible on the password recovery flow. That provides a workaround. The users can request a password recovery themselves to gain access to their account. I'm downgrading the severity.

As a side note, this is not reproducible in local/blank-state instances.

fnocetti commented 5 months ago

In fact, I'm not longer able to reproduce this. May have it been a result of a race condition during today's deploy? Doesn't seem to make sense but I find no explanation.

@aphilop are you still experiencing this? If not, let's monitor the problem.

aphilop commented 5 months ago

@fnocetti Thanks for looking at this. I can reproduce this also in the reset password process.

The error messages in the console: image

fnocetti commented 5 months ago

@aphilop I still can't reproduce this again. Maybe you are reusing the links for the second tests? Can you please try the whole flow? Generating a new password reset, or creating a new user? We tried in you instance, and I originally got the error, but after that I was able to successfully go through the flows. I strongly suspect that this is a one time thing on the first ever try after we changed the strategy.

aphilop commented 5 months ago

@fnocetti

I tried again the following:

I will ask the colleugues who first experienced the problem to check again and if they report also that is working, I will close the issue.

Thanks for the support!

aphilop commented 5 months ago

The colleagues reported that this is working again. I am closing this.

fnocetti commented 5 months ago

Closing as fixed. For the record, the problem was that the expiration timestamp for the restore record was being set in wrong way.