Cédric Krier pushed to branch branch/default at Tryton / Tryton


Commits:
8b9907ff by Cédric Krier at 2023-04-11T00:08:28+02:00
Ensure reset password has at least the minimal length for password

Closes #12028
- - - - -


1 changed file:

- trytond/trytond/res/user.py


Changes:

=====================================
trytond/trytond/res/user.py
=====================================
@@ -306,6 +306,7 @@
     @classmethod
     @ModelView.button
     def reset_password(cls, users, length=8, from_=None):
+        length = max(length, config.getint('password', 'length', default=0))
         for user in users:
             user.password_reset = gen_password(length=length)
             user.password_reset_expire = (



View it on Heptapod: 
https://foss.heptapod.net/tryton/tryton/-/commit/8b9907ffca676b4ce6a12822af32ad0f59d62cc2

-- 
View it on Heptapod: 
https://foss.heptapod.net/tryton/tryton/-/commit/8b9907ffca676b4ce6a12822af32ad0f59d62cc2
You're receiving this email because of your account on foss.heptapod.net.


Reply via email to