Random thoughts about software, hardware and electronics. And other things too...
perjantai 1. heinäkuuta 2016
Login failed
Some time ago I had one customer to inform me that he couldn't log in to his account. We tried to reset his password - several times I think - with no success. So after some cursing I added temporary logging to login page handling to see what is going on.
It turned out that user was logging in from iPad, and for some reason the tablet always inserted single space character before his user name when entering login details. Why this happened still escapes me, and customer swore that when he entered the information there were no space anywhere, but whatever - I added two lines of code to remove any whitespace characters before and after user name and password (before other usual sanitization) and no more problem.
Yes, maybe the string trimming should have been there already, but once again sometimes unexpected things happen, causing unexpected things to happen. Always expect the unexpected, really...
Tilaa:
Lähetä kommentteja (Atom)
Ei kommentteja:
Lähetä kommentti