LemmyNet / lemmy-ui

The official web app for lemmy.
https://join-lemmy.org/
GNU Affero General Public License v3.0
885 stars 334 forks source link

Erroneous Password Strength Warning #1746

Open PC-Admin opened 1 year ago

PC-Admin commented 1 year ago

Requirements

Summary

I plug a 20 digit random alpha-numeric password into the registration form (Which is unbreakable and should be considered a strong password.) and it reports that this is a "Weak" password.

Screenshot from 2023-07-02 13-27-40

This is just a minor bug really and should be considered low priority.

Steps to Reproduce

  1. Attempt to register an account on Lemmy.
  2. Drop an unbreakable 20 digit alpha-numeric password (for example: "7D363rbBhGDbZNQccNhX").
  3. Witness the "Weak" warning.

Technical Details

Debian 12 Firefox

Lemmy Instance Version

0.17.3

Lemmy Instance URL

https://lemmy.perthchat.org

lionirdeadman commented 1 year ago

The example password appears to be treated as medium on beehaw.org

PC-Admin commented 1 year ago

Indeed, on a second attempt I get 'Medium' as well.

It's still inaccurate IMO, a 20 digit alpha-numeric like the example I gave would be a 'Very Strong' password technically.

willhansen commented 1 year ago

It looks like the strength is based on length and special characters

Selection_204 Selection_205

https://github.com/LemmyNet/lemmy-ui/blob/8b478e971244321048818c95df00198cb445dba9/src/shared/components/home/signup.tsx#L24

https://www.npmjs.com/package/check-password-strength