Bugzilla – Attachment 79037 Details for
Bug 20023
Password recovery should be case insensitive
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 20023: Password recovery using email should be case insensitive
Bug-20023-Password-recovery-using-email-should-be-.patch (text/plain), 1.67 KB, created by
Blou
on 2018-09-17 20:38:57 UTC
(
hide
)
Description:
Bug 20023: Password recovery using email should be case insensitive
Filename:
MIME Type:
Creator:
Blou
Created:
2018-09-17 20:38:57 UTC
Size:
1.67 KB
patch
obsolete
>From 36b01f45756890d03b13fbd8f5f9c36ea8a4b71d Mon Sep 17 00:00:00 2001 >From: Blou <philippe.blouin@inlibro.com> >Date: Mon, 17 Sep 2018 16:34:19 -0400 >Subject: [PATCH] Bug 20023: Password recovery using email should be case > insensitive > >When entering an email to recover the password, a user should not have to know or remember the casing of the given email. > >Test >0) enable OpacResetPassword >1) On the OPAC, click "Forgot your password" >2) Enter your email address as in your user account BUT WITH A DIFFERENT CASING >3) Submit. This will fail. >4) Apply the patch, redo with success. >--- > opac/opac-password-recovery.pl | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > >diff --git a/opac/opac-password-recovery.pl b/opac/opac-password-recovery.pl >index e553744..8dba5b9 100755 >--- a/opac/opac-password-recovery.pl >+++ b/opac/opac-password-recovery.pl >@@ -73,7 +73,7 @@ if ( $query->param('sendEmail') || $query->param('resendEmail') ) { > $errMultipleAccountsForEmail = 1; > } > elsif ( $borrower = $search_results->next() ) { # One matching borrower >- my @emails = ( $borrower->email, $borrower->emailpro, $borrower->B_email ); >+ my @emails = ( $borrower->email || '', $borrower->emailpro || '', $borrower->B_email || ''); > > my $firstNonEmptyEmail = ''; > foreach my $address ( @emails ) { >@@ -82,7 +82,7 @@ if ( $query->param('sendEmail') || $query->param('resendEmail') ) { > } > > # Is the given email one of the borrower's ? >- if ( $email && !( grep { $_ eq $email } @emails ) ) { >+ if ( $email && !( grep /^$emails$/i, @emails ) ) { > $hasError = 1; > $errNoBorrowerFound = 1; > } >-- >2.7.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 20023
:
79037
|
79070
|
79086
|
79125
|
79201
|
79202
|
79203
|
79204
|
79270
|
79271
|
81985