- Feature Articles
- CodeSOD
- Error'd
- Forums
-
Other Articles
- Random Article
- Other Series
- Alex's Soapbox
- Announcements
- Best of…
- Best of Email
- Best of the Sidebar
- Bring Your Own Code
- Coded Smorgasbord
- Mandatory Fun Day
- Off Topic
- Representative Line
- News Roundup
- Editor's Soapbox
- Software on the Rocks
- Souvenir Potpourri
- Sponsor Post
- Tales from the Interview
- The Daily WTF: Live
- Virtudyne
Admin
Why would any given character not be "supported" in a particular position? That condition makes no sense at all.
Admin
Admin
I was assuming that the methodology made some business sense, even if the code is a WTF. Perhaps I should not have assumed that...
Admin
Yes, it's me:
Admin
Admin
Admin
Admin
I think it is called "being passive-aggressive".
Admin
The worst part is that this completely sucks at being a facade. All it does is complain about invalid characters at random points in the string. I could make a better one.
Behold: Password-validation, BOFH-style.
The best part about this is that as user tenacity increases, the probability of them keeping their account long enough to be a nuisance to you approaches zero.
Admin
What, you mean like most Liberals these days?
Admin
I'm going to go against the grain here and posit that it was just a case of good intentions gone bad.
Remember that this is validation code for password change residing on the client-side. Ideally, to verify that the proposed password is indeed different from the password on the back-end, you would have to contact the back-end somehow. Short of doing that (perhaps for reasons of security or efficiency), the author of this code decided to just throw in random errors to pre-empt users who are inclined to just enter new passwords that are mostly the same as the old ones. The intention, I believe, was to get users to introduce a little more randomness into their passwords.
But how does this explain
var error = Math.floor(Math.random() * 1)
I think this is just a typo where the guy meant "10" or "100" in place of "1", so that some fraction of users would encounter the random error.
Don't get me wrong, I still think the scheme is hare-brained, but I don't think it was meant to be as malicious or unreasonable as some of you make it out to be.
Admin
Fix'd?
var error=1; //Doesn't throw errors!
Admin
The problem did exist between the keyboard and chair. What they got wrong was that it was between the programmer's keyboard and chair, not the user's.
Admin
This is why some organisations (call them crazy) have QA/testing.
Admin
Thanks for sharing this article. I am very happy to see it. If you like please visit my link, If you want to make real money. Thank You. https://cutt.ly/o37sLTg https://cutt.ly/2366xF7 https://cutt.ly/38ymCM0
Admin
I am inspired by this article. Hopefully in the future I can find other articles from you. Thank You. https://cutt.ly/j8E9X22 https://cutt.ly/s8Ru2MG https://cutt.ly/A8YAES6 https://cutt.ly/N8YAYzI
Admin
hello my friend, I really enjoy reading the articles or blogs that you make. Can you help me with something like that because I also really want to make articles or blogs like you. Thank You https://www.waysnet.org https://heylink.me/slotdeposit30jadi60/ https://allufa.ru/online/situs-slot-dana-mudah-menang-2023/ https://allufa.ru/captcha/login/slot-deposit-pulsa-5000/ http://ta.fst.unair.ac.id/biologi/public/halo/situs-judi-slot-terbaik-dan-terpercaya-no-1/
Admin
Наша команда профессиональных мастеров готова предоставить вам передовые методы, которые не только подарят долговечную покров от прохлады, но и преподнесут вашему жилью элегантный вид. Мы деятельны с последовательными компонентами, обеспечивая постоянный продолжительность работы и отличные результаты. Утепление внешней обшивки –