Bugzilla – Attachment 35320 Details for
Bug 10177
Koha Accepts Seven "Space" Characters as a Valid Password
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 10177 - Whitespace is accepted within the password but leading and trailing spaces are not.
Bug-10177---Whitespace-is-accepted-within-the-pass.patch (text/plain), 1.61 KB, created by
Brandon
on 2015-01-15 22:51:20 UTC
(
hide
)
Description:
Bug 10177 - Whitespace is accepted within the password but leading and trailing spaces are not.
Filename:
MIME Type:
Creator:
Brandon
Created:
2015-01-15 22:51:20 UTC
Size:
1.61 KB
patch
obsolete
>From 9ae33318b8b20c1925ef8f677dbc83b0038a6b44 Mon Sep 17 00:00:00 2001 >From: Brandon <brandon_h27@hotmail.com> >Date: Thu, 15 Jan 2015 22:42:52 +0000 >Subject: [PATCH] Bug 10177 - Whitespace is accepted within the password but > leading and trailing spaces are not. > >Test plan: >1: Go to your patron >2: Go to change username and/or password. >3: Change password to something with spaces in the middle. Notice it is invalid. >4: Apply this patch. >5: Change password again using spaces in the middle. Notice it is accepted. >6: Change password with leading and/or trailing spaces, notice they are not accepted. >--- > koha-tmpl/intranet-tmpl/prog/en/modules/members/member-password.tt | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > >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 c394389..857ce5c 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 >@@ -9,8 +9,8 @@ > alert(_("Passwords do not match")); > return false; > } else { >- if ($("input[name='newpassword']").val().match(/^\s*$/)) { >- alert(_("Password contains nothing except whitespace")); >+ if ($("input[name='newpassword']").val().match(/^\s/) || $("input[name='newpassword']").val().match(/\s$/)) { >+ alert(_("Password contains leading and/or trailing spaces.")); > return false; > } else { > return true; >-- >1.7.10.4
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 10177
:
35265
|
35320
|
35343
|
35344
|
35356
|
35357