Bugzilla – Attachment 66625 Details for
Bug 18298
Allow enforcing password complexity
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 18298: minPasswordLength should not be used as the default password length
Bug-18298-minPasswordLength-should-not-be-used-as-.patch (text/plain), 1.49 KB, created by
Jonathan Druart
on 2017-08-30 15:29:34 UTC
(
hide
)
Description:
Bug 18298: minPasswordLength should not be used as the default password length
Filename:
MIME Type:
Creator:
Jonathan Druart
Created:
2017-08-30 15:29:34 UTC
Size:
1.49 KB
patch
obsolete
>From 83fc051c49b16de03c93bb48ec8849026d0ecfb9 Mon Sep 17 00:00:00 2001 >From: Jonathan Druart <jonathan.druart@bugs.koha-community.org> >Date: Thu, 16 Mar 2017 23:02:13 -0300 >Subject: [PATCH] Bug 18298: minPasswordLength should not be used as the > default password length >MIME-Version: 1.0 >Content-Type: text/plain; charset=UTF-8 >Content-Transfer-Encoding: 8bit > >The length of the passwords generated for a patron should not be as long >as the value of minPasswordLength. >It is the minimum required size of a password, not the maximum! >So let's fix it to 8 if the minPasswordLength if < 8, that sounds >reasonable and less risky for patrons. > >Signed-off-by: Marc Véron <veron@veron.ch> >--- > koha-tmpl/intranet-tmpl/prog/en/modules/members/member-password.tt | 1 + > 1 file changed, 1 insertion(+) > >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/members/member-password.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/members/member-password.tt >index 4e66075603..cf5e33d59e 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/members/member-password.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/members/member-password.tt >@@ -10,6 +10,7 @@ > // Always generate a strong password > var chars = '0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ'; > var length = [% minPasswordLength %]; >+ if ( length < 8 ) length = 8; > var password=''; > for ( var i = 0 ; i < length ; i++){ > password += chars.charAt(Math.floor(Math.random()*chars.length)); >-- >2.11.0
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 18298
:
61227
|
61228
|
61229
|
61230
|
61231
|
61232
|
61237
|
61331
|
61332
|
61333
|
61334
|
61335
|
61336
|
62976
|
62977
|
62978
|
62979
|
62980
|
62981
|
66621
|
66622
|
66623
|
66624
|
66625
|
66626
|
68096
|
68097
|
68098
|
68100
|
68101
|
68102
|
68103
|
68104
|
68105
|
68106
|
68220