Skip to content

Conversation

adamspd
Copy link
Owner

@adamspd adamspd commented Feb 21, 2024

Improve security by letting users set their own passwords

This commit addresses a security concern where user accounts were automatically created with a predictable password. Instead of setting a password based on a predictable pattern (e.g., website name combined with the current year), we now generate a secure, random token for each new user. This token is used in a password reset or account activation link sent via email, allowing users to set or reset their passwords securely. This change ensures that user accounts remain secure and that users are fully aware of and in control of their account creation and password management processes.

This commit addresses a security concern where user accounts were automatically created with a predictable password. Instead of setting a password based on a predictable pattern (e.g., website name combined with the current year), we now generate a secure, random token for each new user. This token is used in a password reset or account activation link sent via email, allowing users to set or reset their passwords securely. This change ensures that user accounts remain secure and that users are fully aware of and in control of their account creation and password management processes.
@adamspd adamspd self-assigned this Feb 21, 2024
@adamspd adamspd linked an issue Feb 21, 2024 that may be closed by this pull request
Copy link

codecov bot commented Feb 21, 2024

Codecov Report

Attention: 7 lines in your changes are missing coverage. Please review.

Comparison is base (78889c7) 95.09% compared to head (7c5e6f7) 95.42%.

❗ Current head 7c5e6f7 differs from pull request most recent head ce08aef. Consider uploading reports for the commit ce08aef to get more accurate results

Files Patch % Lines
appointment/views.py 81.57% 7 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main     #114      +/-   ##
==========================================
+ Coverage   95.09%   95.42%   +0.32%     
==========================================
  Files          47       49       +2     
  Lines        5408     5721     +313     
==========================================
+ Hits         5143     5459     +316     
+ Misses        265      262       -3     
Flag Coverage Δ
unittests 95.42% <98.16%> (+0.32%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@adamspd adamspd enabled auto-merge February 21, 2024 17:39
@adamspd adamspd merged commit 5dd2bba into main Feb 21, 2024
@adamspd adamspd deleted the 51-user-creation-and-password-handling branch February 21, 2024 17:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

User creation and password handling
1 participant