Page 1 of 1

Need help with password length [Solved]

Posted: Thu Jan 23, 2020 5:02 am
by nobodyinteresting
Hey all!

I am in need for some quick help. I have OC 3.0.3.2 and I need to have the default password length changed to 8 symbols minimum, for all customers that register an account, as well as future password changes.
I do need this done ASAP as well. Please quote me a price and approximate time frame on when this can be completed.

Thank you very much!

Re: Need help with password length

Posted: Thu Jan 23, 2020 5:26 am
by thekrotek
I can create a modification for you, but all quotes and discussions are not for this forum. Send me an email or message in Skype and we'll discuss everything.

Re: Need help with password length

Posted: Thu Jan 23, 2020 5:32 am
by nobodyinteresting
thekrotek wrote:
Thu Jan 23, 2020 5:26 am
I can create a modification for you, but all quotes and discussions are not for this forum. Send me an email or message in Skype and we'll discuss everything.
Emailed you,

Thanks!

Re: Need help with password length

Posted: Thu Jan 23, 2020 7:15 am
by xxvirusxx
catalog/controller/account/register.php
catalog/controller/account/password.php
catalog/controller/account/reset.php
catalog/controller/checkout/register.php
catalog/controller/affiliate/register.php


Change this line

Code: Select all

if ((utf8_strlen(html_entity_decode($this->request->post['password'], ENT_QUOTES, 'UTF-8')) < 4) || (utf8_strlen(html_entity_decode($this->request->post['password'], ENT_QUOTES, 'UTF-8')) > 40)) {
to this

Code: Select all

if ((utf8_strlen(html_entity_decode($this->request->post['password'], ENT_QUOTES, 'UTF-8')) < 8) || (utf8_strlen(html_entity_decode($this->request->post['password'], ENT_QUOTES, 'UTF-8')) > 40)) {
And should work

Re: Need help with password length

Posted: Thu Jan 23, 2020 7:18 am
by nobodyinteresting
xxvirusxx wrote:
Thu Jan 23, 2020 7:15 am
catalog/controller/account/register.php

Change this line

Code: Select all

if ((utf8_strlen(html_entity_decode($this->request->post['password'], ENT_QUOTES, 'UTF-8')) < 4) || (utf8_strlen(html_entity_decode($this->request->post['password'], ENT_QUOTES, 'UTF-8')) > 40)) {
to this

Code: Select all

if ((utf8_strlen(html_entity_decode($this->request->post['password'], ENT_QUOTES, 'UTF-8')) < 8) || (utf8_strlen(html_entity_decode($this->request->post['password'], ENT_QUOTES, 'UTF-8')) > 40)) {
And should work
So basically change the 4 to 8? I already did that, unfortunately it would still let me register with a password like 12345 (which is obviously shorter than 8 ). Unless there is a cache somewhere that needs to be deleted.

Thanks!

Re: Need help with password length

Posted: Thu Jan 23, 2020 7:22 am
by xxvirusxx
Refresh ocmod, then from Dashboard, gears from right top (under Logout), clear Theme cache, Sass cache.

Re: Need help with password length

Posted: Thu Jan 23, 2020 7:57 am
by nobodyinteresting
xxvirusxx wrote:
Thu Jan 23, 2020 7:22 am
Refresh ocmod, then from Dashboard, gears from right top (under Logout), clear Theme cache, Sass cache.
You, sir, are a rockstar and a life saver! :-) That worked, completely forgot to clear cache.

Thank you so very much!

Re: Need help with password length

Posted: Thu Jan 23, 2020 11:44 am
by frank 123
Hi nobodyinteresting

I am interested in your requirement and will be glad to assist you as an opencart expert

please reach me out my details are in signature

Re: Need help with password length

Posted: Thu Jan 23, 2020 11:45 am
by nobodyinteresting
frank 123 wrote:
Thu Jan 23, 2020 11:44 am
Hi nobodyinteresting

I am interested in your requirement and will be glad to assist you as an opencart expert

please reach me out my details are in signature
Thank you, got it figured out already though.